Select to view content in your preferred language

Help with WCF

848
5
01-04-2012 06:47 AM
RobertPincus
Regular Contributor
I have embeded a WCF service in a VS2010 project. The service simply gets the distinct city names from a table in our Sql Server 2008 SDE database. The project runs fine when running in the VS debugger. When I publish the application to our webserver, the services fail. What do I need to do to troubleshoot this? Should I create WCF services on the webserver independent of the project?

Thanks,
Robert
0 Kudos
5 Replies
JenniferNery
Esri Regular Contributor
You might have better luck finding answers from Silverlight forum. This seems related: http://forums.silverlight.net/t/222292.aspx/1.
0 Kudos
HugoCardenas
Emerging Contributor
Robert,
Create your WCF as separated or independent Web Site of type "WCF Service".

Deploy your WCF on your IIS server:

  1. Configure the Web.config file properly on the WCF side (set proper array sizes and bindings)

  2. Test the WCF with a Windows or Asp.net application (Silverlight is not good for testing or debug)


After the WCF runs properly (it does what you want it to do), reference it within your Silverlight / Esri application.

If you have not done it before, you really need my help.  I can help you - walk you through.  The most difficult part is the settings in the Web.Config file of the WCF and the client's Web.config as well.

In my particular case, I created a standard .NET library (dll) which does all the work.  Then, I created an empty Web site of type "WCF Service" which exposes (serves) the dll (I get more .NET power this way); my WCF interfase and the "Service" itself reside inside the dll, rather than on the web site.  When I update the dll, I do not need to re-deploy the web site that exposes the WCF - I just copy the dll inside the "bin" folder of the Web site.  The applications just refresh or update their service instances to get the updates.

Let me know...
Hugo.
0 Kudos
RobertPincus
Regular Contributor
I saw your post this problem and I will follow your suggestions.

Thanks,
Robert
0 Kudos
dotMorten_esri
Esri Notable Contributor
This sample might also help you with some ideas how to create a service (slightly different approach than WCF but more flexible): http://www.arcgis.com/home/item.html?id=6d28a606369c43fd9a6f929541ae7c93
0 Kudos
RobertPincus
Regular Contributor
Still having problems getting the WCF service working on the remote server. I have been following some tutorials, but none of them seem to work. Any thoughts?

Robert
0 Kudos