本文介绍了找不到服务的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
大家好,
这是WCF项目中的webconfig文件,每当我尝试发现它总是告诉
http://localhost/CRSRoutingService/找不到404错误.
这里缺少什么,请有人给我开灯
Hello all,
This is the webconfig file from WCF project, whenever i try to discover it always tell
http://localhost/CRSRoutingService/ couldn''t found 404 error.
what am missing here ,please someone throw me a light please
<configuration>
<system.web>
<compilation debug="true" targetframework="4.0" />
</system.web>
<system.servicemodel>
<!--The clients,i.e the services to route to-->
<client>
<endpoint>
name ="M2P_Adapter"
address="net.msmq://localhost/private/M2PAdapterQueue"
binding="netMsmqBinding"
bindingConfiguration ="MSMQPrivateQueueConfig"
contract="*" />
<endpoint>
name ="MPM_Adapter"
address="net.msmq://localhost/private/MPMAdapterQueue"
binding="netMsmqBinding"
bindingConfiguration ="MSMQPrivateQueueConfig"
contract="*"/>
</endpoint></endpoint></client>
<!--The end point the client points to-->
<services>
<service behaviorconfiguration="RoutingServiceBehavior">
name="System.ServiceModel.Routing.RoutingService">
<host>
<baseAddresses>
<add baseaddress="http://localhost/CRSRoutingService/" />
</baseAddresses>
</host>
<endpoint address="net.msmq://localhost/private/crsroutingqueue">
binding="netMsmqBinding"
bindingConfiguration ="MSMQPrivateQueueConfig"
contract="System.ServiceModel.Routing.ISimplexDatagramRouter"
name="RoutingServiceEndpoint" />
<endpoint address="mex" binding="mexHttpBinding" contract="IMetadataExchange" />
</endpoint></service>
</services>
<!--Binding configurations-->
<bindings>
<netmsmqbinding>
<binding name="MSMQPrivateQueueConfig">
<security mode="None" />
</binding>
</netmsmqbinding>
</bindings>
<!--Service behaviours-->
<behaviors>
<servicebehaviors>
<behavior name="RoutingServiceBehavior">
<!-- To avoid disclosing metadata information, set the value below
to false and remove the metadata endpoint above before deployment -->
<servicemetadata httpgetenabled="true" />
<!-- To receive exception details in faults for debugging purposes,
set the value below to true. Set to false before deployment
to avoid disclosing exception information -->
<servicedebug includeexceptiondetailinfaults="true" />
<routing filtertablename="routingRules" routeonheadersonly="False" />
</behavior>
<behavior name="">
<servicemetadata httpgetenabled="true" />
<servicedebug includeexceptiondetailinfaults="false" />
</behavior>
</servicebehaviors>
</behaviors>
<!--Routing configuration-->
<routing>
<filters>
<filter name="MPMFilter" filtertype="XPath">
filterData="/CRSTransform"/>
<filter name="M2PFilter" filtertype="XPath">
filterData="/CRSTransform1"/>
</filter></filter></filters>
<filtertables>
<filtertable name="routingRules">
<add filtername="MPMFilter">
endpointName="MPM_Adapter"
priority="0"/>
<add filtername="M2PFilter">
endpointName="M2P_Adapter"
priority="0"/>
</add></add></filtertable>
</filtertables>
</routing>
<!-- Independent configuration-->
<servicehostingenvironment multiplesitebindingsenabled="true" />
</system.servicemodel>
<system.webserver>
<modules runallmanagedmodulesforallrequests="true" />
</system.webserver>
</configuration>
推荐答案
这篇关于找不到服务的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持!