Multiple Endpoints vs. Single Endpoint

Topics: Web Client Software Factory, Project Management Forum, UIP Application Block discussion, User Forum
Nov 16, 2007 at 11:32 AM
Hi

I have a Web Client (WCSF) with an Foundational module where I have references and proxies for my Web Services that is both ASMX and WCF services. Im wondering if I should split my WCF service into multiple endpoints, say one endpoint for each Business Module in WCSF. My WCF service is beginning to be very big (proxy-code about 4000 lines of code) and in my Web Client I have modules like Customers, Suppliers etc. And they only use a few of all the methods in my WCF service.

The reason for me making one big service contract (and one very big implementation class, which I want to reduce) was that I have to log on the service before I can call any subsequent calls.
Before you can call any methods on the service you have to call the "LogIn" method that is marked with IsInitiating = true. Can I still keep this when I go for splitting up the service interface into multiple endpoints? How can the other endpoins know that the LogIn have been called first? I guess they can't?

My idea is to split my single-endpoint into mulitple endpoins like this:
http://localhost/MyService/Customers/
http://localhost/MyService/Suppliers/
Etc.

Then in my WCSF-project I can each Module have access to only those service-endpoints that they actually need/use.... Sounds like a good idea to me but is it possible if I want to keep the IsInitiating=true on the LogIn-method?

I guess this will make it easier to maintain too, you can update only the service-endpoints and the respective client-modules when doing changes, right?

Any comments is appreciated

- RightCoder
Nov 25, 2007 at 9:32 PM
Was this post stupid or what? Can't belive no one has given any thoughts.... Is it unclear what I mean?

-RightCoder
Nov 25, 2007 at 9:45 PM
Well, sounds like a good idea to split this up! Can you call another service (not necessarily a web service) from each of the split services just for your logging/login needs...?
Nov 26, 2007 at 1:34 PM
Thank you for your reply, Claus.

You mean to have a Login-method on every endpoint / split service with IsInitiating = true set?
Yes I think I could do that, but I'm not sure how the WCF-runtime handle this "IsInitiating = true"-thing so I have to take a closer look at that. I know this is not the right discussion-group to discuss this kind of questions so I have posted the same question in the Web Service Software Factory discussions. But I guess more and more people are using both WCSF and WSSF so this kind of questions should be more and more relevant....

Nov 26, 2007 at 4:23 PM
I have also read the answer on the other thread. As you wrote above "...And they only use a few of all the methods in my WCF service...." one could expect that the total number of logins per time wouldn't even grow significantly. So why not plainly splitting it....