JSON DATA FORMATTING SHOULD BE DONE IN WHICH LAYER IN SPRING MVC FRAMEWORK

Chintoo Semi

Total Post:135

Points:947
Posted by  Chintoo Semi
JSON 
 1461  View(s)
Ratings:
Rate this:
Hi Expert,

In MVC framework which layer is suppose to format/covert data to JSON. Should it be done in Web layer or in Service layer? In my opinion it should be done in Web layer (Spring Controllers) but some peole suggest to do that in Service layer. What are other people think about it?
  1. AVADHESH PATEL

    Post:604

    Points:4228
    Re: JSON Data formatting should be done in which layer in Spring MVC framework

    Yes you are right.

    I also think that JSON manipulation should be done on Web layer, doing this will make your code more manageable.

Answer

NEWSLETTER

Enter your email address here always to be updated. We promise not to spam!