Publishing WCF.NET 3.5 in IIS 6 (Windows Server 2003)

I am developing a WCF web service using .NET 3.5 with IIS7 and it works fine on my local machine. I tried publishing it on a server with IIS 6, and although I can view the WSDL in my browser, the client application does not seem to connect to it correctly. I started the application for sniffing packages (Charles Proxy), and the response to the first message is returned to the client empty (0 bytes). Each message expires after the first time.

The WCF service is part of a larger application that uses ASP.NET 3.5. This application works fine on IIS 6, so I think it is something specific for WCF. I also tried to make an exception in the SVC file to make sure it made it this far, and the exception was never thrown, so I feel that it is something lower that doesn't work.

Any thoughts? Do I need to install on an IIS5 server? If so, how can I still view WSDL in my browser?

The service is consumed through an SVC file using basicHttpBinding

Here's the meat of Web.Config (let me know if you need another part of it):

<system.net>
  <defaultProxy>
    <proxy usesystemdefault="False" proxyaddress="http://127.0.0.1:80" bypassonlocal="True"/>
  </defaultProxy>
</system.net>

...

<system.serviceModel>
  <services>
    <service name="Nexternal.Service.XMLTools.VNService" behaviorConfiguration="VNServiceBehavior">
      <!--The first endpoint would be picked up from the confirg
      this shows how the config can be overriden with the service host-->
      <endpoint address="" binding="basicHttpBinding" contract="Nexternal.Service.XMLTools.IVNService" />
      <endpoint address="mex" binding="mexHttpBinding" contract="IMetadataExchange" name="mexHttpBinding" />
    </service>
  </services>
  <behaviors>
    <serviceBehaviors>
      <behavior name="VNServiceBehavior">
        <serviceMetadata httpGetEnabled="true" />
        <serviceDebug includeExceptionDetailInFaults="true" />
      </behavior>
    </serviceBehaviors>
  </behaviors>
  <serviceHostingEnvironment aspNetCompatibilityEnabled="true" />
</system.serviceModel>
+3
source share
3 answers

WCF IIS 5.1 6. , , .Net 3.0+, , , ASP.NET 3.5.

.svc? , , . WCF? / ? ? , HTTP- IIS 6 . IIS 7 WAS, -http .

, wsdl, , MEX , - .

+2

. .net 4.0, IIS 6 Windows Server 2003. :

  • .svc exntension IIS. , , C:\WINDOWS\Microsoft.NET\Framework\v2.0.50727\aspnet_isapi.dll svc.
  • KB976769v2 KB980773 Windows Server 2003.
  • targetFramework = "4.0" web.Config.
  • serviceHostingEnvironment multipleSiteBindingsEnabled = "true" system.ServiceModel system.ServiceModel.
  • , ASP.Net 4.0.30319 - .

, NT AUTHORITY/NETWORK SERVICE , .

+2

WCF is heavily dependent on the Windows Activation Service, and I remember that it is difficult (better to say, rather painful) to run it and run in IIS6, so we ended up switching to IIS7.

0
source

Source: https://habr.com/ru/post/1749050/


All Articles