Last post Apr 03, 2010 08:07 AM by spek
Apr 01, 2010 07:52 AM|spek|LINK
No question too simple sais the forum index... Well here it goes then
I'm planning to make an ASP.NET webserver that provides all kinds of functions, like an API. There will be quite alot functions that can easily be grouped (datasystem, userAccount, fileSystem, and so on). I can make multiple services (asmx files) into a
single webserver, and let the clients connect to whatever service(s) they need. However, I'm not sure if it's a wise thing to do... Pack everything into 1 big service(1 asmx file), or split up into many smaller services? How about:
- performance/memory on the server (a client that connets with 1 or 6 services)
- Maximum connections (we will use a Windows XP Server edition computer)
There will be about ~30 computers using it. In a worst case scenario, they each computer could make use of 6 services at the same time, if I decide to split it up. A single client could make use of the fileSystem, account, dataSystem and several other things
at the same time.
Hope this question makes a little bit sense :)
Apr 02, 2010 02:56 AM|DigiMortal|LINK
Don't build one large god-service that does everything. Separate the operations that your service provides to meaningful groups by their functionality. If you tell me more about your service then I am able to give you better advice.
Apr 02, 2010 03:04 AM|spek|LINK
Well my plan was to split up into the following groups:
- Account (login, users, workstations, user rights, available tools per user)
- DataSystem (database stuff)
- FileSystem (download / upload files to server)
- MachineServer (hardware & plant control functions)
- Planner (Planning & scheduler module)
- OrderSystem (order status, info & control)
- BatchSystem (barcodes, locations, items with batch numbers, states, stock)
- Document Generator (automated documentation, scripts)
Thus about 8 modules. Programmically wise and logically, I think this would be a pretty good split for our sitation. However, I was worrying about perfromance / memory / max connections issues. Instead of connecting to 1 service, a client ussually connects
to 4 or even more services...
Apr 02, 2010 08:30 AM|DigiMortal|LINK
That's fine if you have your first plan. You can be sur ethat you change this plan at least couple of times as you get smarter and smarter when writing your services. Don't write all services as far as you can. Write them at first to the point where they
should share functionalities. This is the first point where you see if you need to reorganize services are not. Take small steps, test and analyze next steps. This way you don't do something awfully large that is hard to handle and you are able to move very
Apr 02, 2010 03:00 PM|spek|LINK
Allright. Design is still in a concept stadium, and the webservice itself doesn't really execute the commands anyway. DLL's behind do the real work, the webserver is just an access point that passes the data between the clients and DLL's.
But if you understand you right, performance shouldn't be a real issue wether I use 1,2 or 10 services?
Thanks for helping
Apr 03, 2010 12:17 AM|DigiMortal|LINK
For web server it does not matter much if you have one or ten services. The question is - what these services do? If you have services organized well enough then you can scale and optimize them separately and achieve better results than having one large
service that may be very hard to optimize because very different functionalities it provides.
Apr 03, 2010 08:07 AM|spek|LINK
That's good news then. I was afraid that more services would mean more connections and possibly slower performance or more memory consumption. But if it isn't really noticeable, I'll stick with the plan and make small specialized services instead, like you
Thanks for guiding me!