Design: Website calling a webservice on the same machine

Posted by Chris L on Stack Overflow See other posts from Stack Overflow or by Chris L
Published on 2010-03-22T19:02:13Z Indexed on 2010/03/22 19:21 UTC
Read the original article Hit count: 378

Filed under:
|
|
|

More of a design/conceptual question.

At work the decision was made to have our data access layer be called through webservices. So our website would call the webservices for any/all data to and from the database. Both the website & the webservices will be on the same machine(so no trip across the wire), but the database is on a separate machine(so that would require a trip across the wire regardless). This is all in-house, the website, webservice, and database are all within the same company(AFAIK, the webservices won't be reused by another other party).

To the best of my knowledge: the website will open a port to the webservices, and the webservices will in turn open another port and go across the wire to the database server to get/submit the data. The trip across the wire can't be avoided, but I'm concerned about the webservices standing in the middle.

I do agree there needs to be distinct layers between the functionality(such as business layer, data access layer, etc...), but this seems overly complex to me. I'm also sensing there will be some performance problems down the line.

Seems to me it would be better to have the (DAL)assemblies referenced directly within the solution, thus negating the first port to port connection.

Any thoughts(or links) both for and against this idea would be appreciated

P.S. We're a .NET shop(migrating from vb to C# 3.5)

© Stack Overflow or respective owner

Related posts about c#

Related posts about website