none
Convert from MVC to SOA RRS feed

  • Question

  • Hi,

    Currently we are following mvc pattern in our project.

    We are going to make our application mobile so we are going to the SOA architecture.

    PFB the old pattern and new pattern which is going to be followed. We are creating wcf service for this purpose where should it actually come after which layer..Please help me out.


    Krishna kumar

    Saturday, December 22, 2012 5:08 PM

All replies

  • WCF service should have its own models. There will be a layer called Domain Service Layer (DSL) which translates the models from WCF service model into the view models.

    Benefit of this architecture is if WCF changes its model, you have to change only the DSL, since view models are not tightly coupled with WCF service models. DSL is referenced inside MVC application.

    You will see something like 

    Sunday, December 23, 2012 3:44 PM
  • WCF service should have its own models. There will be a layer called Domain Service Layer (DSL) which translates the models from WCF service model into the view models.

    Benefit of this architecture is if WCF changes its model, you have to change only the DSL, since view models are not tightly coupled with WCF service models. DSL is referenced inside MVC application.

    You will see something like 

    Sunday, December 23, 2012 3:44 PM
  • Hi There

    Yes I agree with this proposal.

    You should still have a model in your web web application (ViewModel) which is used by the controller to send information to the UI.

    However your WCF service should also consist of its own model which could comprise several data contracts. If you are using entity framework then you do not have to hand-code the data contracts and rather create an .edmx model which is also used like a data contract when clients communicate with your WCF service.

    Regards,

    Ian


    I.W Coetzer


    • Edited by I.W Coetzer Monday, December 24, 2012 7:31 AM
    Monday, December 24, 2012 7:28 AM
  • Whilst I'm not disagreeing with what has being said I would like to highlight that it might just be overkill. Simply placing a WCF layer into an architecture does not make it SOA. I'm not sure if the question is; how to design for SOA or how to abstract the data service because of...<insert reason here>. The reason I mentioned overkill, is that if you simply want to abstract the db then would you really need to involve WCF let alone extra service layers or even view models? I'm being pendantic but hopefully to help illustrate that we don't know enough of the background to provide a specific answer.

    http://pauliom.wordpress.com

    Monday, January 7, 2013 4:11 PM
  • Hello there,'

    Your block diagram is good , the technical guidance is not good enough. This kind of blunder will cost you dear in terms of money and in terms of cost of manpower .

    You cannot such technical gudiance for free, please consult with microsoft regarding  this matter.

    I hardly know you in the first place , any common sense left , please go through the link which is given by microsoft in the first place.

    ASP.NET Web Sites for Mobile Devices

    http://msdn.microsoft.com/en-us/library/ms178619%28v=vs.100%29.aspx

    do you want end user satisfaction in the first or meet the customer demands in the first , if you are wise enough , please contact microsoft in the first place.

    Cheers,

    Phijo Mathew Philip.


    PHIJO MP

    Saturday, January 26, 2013 12:44 PM