Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Abstraction...how much is too much?
Message
De
01/08/2002 01:17:40
 
 
À
31/07/2002 23:54:15
Information générale
Forum:
ASP.NET
Catégorie:
Autre
Divers
Thread ID:
00684846
Message ID:
00684858
Vues:
18
Kevin,

I agree with your methods of doing things to a certain degree. I think it's a good idea to keep your Web Services light-weight. But, I'm thinking that having just one "ChannelRequest" method is taking it to the extreme. (This is just my opinion, keep in mind ... we're all trying to figure out the best way to do some of this stuff).

Our Web Services consist mainly of wrappers that call the appropriate Business layers, that call the appropriate data access layers (that actually make the SP calls to SQL Server). So, it seems to me that having only one Web Service, as you do, that passes info to a main application manager, which passes it on to a module manager, which then determines which method to call in which module ... seems a bit too abstract to me.

Here's what we do (just some food for thought) ... say we have the need to get Customer information. So, we'll have a Customer Business object. It will contain classes for getting Customer info in various ways (GetCustomerByCustomerKey(), GetCustomerListByState(), etc.) by making calls to various classes in the Customer DataAccess object (which will call SP's and is the only way access to the database is allowed). The DataAccess object passes the resulting DataSet back to the Business object. The Business object passes the DataSet back to the Web Service which returns XML back to the WinForm, which turns it back into a DataSet and then proceeds on it's merry way.


~~Bonnie

>I'm not sure if this is the right forum for this, but...
>
>We're building .NET App using WinForms, Web Services, a middle-tier, and SQL Server. We have four primary moodules, each consisting of about 15 screens, and about 30 sets of functions per module.
>
>There's some debate within our development group regarding levels of abstraction in the middle-tier. In a nutshell, here is what we have:
>
>Any time the WinForm needs something (basically, to retrieve data or to push data back to SQL), it calls a general method in the Web Service called 'ChannelRequest'. The WinForm passes to 'ChannelRequest' the name of the module being used, and the name of the function being requested. It may also pass user selections, user entries, etc.
>
>ChannelRequest is the lone method in the Web Service. It passes the information sent from the WinForm to a main application manager.
>
>The application manager takes the request, and determines which module is being called. It passes the information originally sent from the WinForm to the module manager.
>
>The module manager takes the request, and determines which method within that module is being requested. It passes any local selections from the Winform to that function (that function is usually where the bulk of the method code/business logic resides).
>
>And when that method actually communicates with SQL, it does so by way of a data 'broker' which handles all the talking with the database server.
>
>While I realize this is the 'right' way to do things, I have a concern that we're talking about 4-5 function calls just to get to the actual logic. That 'seems' to me to be excessive overhead. And we're talking about thousands upon thousands of hits a day. Is this a good design, or do the levels of abstraction need to be reduced?
>
>(And by the way, all parameters passed back and forth to different methods is done by way of populating a dataset. We seldom pass any strings as parameters.)
>
>Thanks,
>Kevin
Bonnie Berent DeWitt
NET/C# MVP since 2003

http://geek-goddess-bonnie.blogspot.com
Précédent
Répondre
Fil
Voir

Click here to load this message in the networking platform