Can WCF hosted in Windows Service accessible over internet?

2k views Asked by At

I need some understanding about WCF.

I am working on a client server application. Project plan is something like this.

We have one server running a SQL Server 2008 over Windows 7 (I know windows 7 is not best choice for server but it has windows 7 right now). I am planning build cluster of WCF services which will be hosted on Windows Services with net tcp binding on server side. These WCF Services cluster handles all the business logic of the application and database transaction.

At this moment there will be 25 windows clients (it could increase in future) running the client application. All clients are in same LAN so i guess above architecture work and all client can access the WCF Services running on server using net TCP binding. Please correct me if I am wrong ...

What I want to do in future is I want to create a mobile client application or Silverlight client application to access the same WCF Service ... is this possible if I have hosted WCF services in Windows Services and if Mobile Client Application / Silverlight Client Application is on same network (same LAN)?? (I guess no see the comment)

What if I want to access it over the internet?? Can above WCF Services hosted on Windows Services be access over the internet ?? (It can if it is nettcp binding but only by other WCF application - see comments)

If not, can I create http basic endpoint for WCF Service while hosting it in windows service and be accessible over the internet ??

If not, can I host the same WCF Service in windows services as well as IIS ??

What is the best options if you want WCF to be accessible over the LAN as well as Internet ??

1

There are 1 answers

0
chandmk On

One nice benefit about WCF is, you can post pone decisions about hosting, protocols, bindings as far as you can. If you need a prive WCF service just use the nettcp binding. If you want to extend this to internet, you can always add other bindings.

You can always change hosting decisions from windows service to IIS. It is relatively trivial.