简体   繁体   中英

Service Oriented Application in Windows Form client?

What could be the best way to create a server sided program on windows? The client will be a windows form application. Is there any problem with speeds on the client because of the load time. And also for heavy requested method, is it possible for async?

You'll probably want to take a look at WCF (Windows Communication Foundation). You can use it to create services and expose them as SOAP or using a few other standards, all being highly configurable. When your clients are all running on Windows you might want to expose the services using the net.tcp protocol.

WCF supports asynchronous methods.

"Is there any problem with speeds on the client because of the load time" is too vague to answer. Obviously there are a myriad of performance issues you'll need to consider and many parameters that matter (eg will you cluster? is the client data intensive? etc).

Try this proof of concept code http://www.ienablemuch.com/2011/01/nhibernate-saves-your-whole-object.html I must admit that my code doesn't faithfully adhere to SOA design; anyhow, you can use some of the principles how to retrieve POCOs(which is bandwidth-friendly) from WCF

Others has a strong view about what constitutes a real service -oriented application, ie the domain entities are internal to a business and need not be exposed to business's clients(or for public consumption). If you adhere faithfully to that tenet, you should use DTO (google this) and automapper (not related to fluent nhibernate's automapper) combo

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM