Is there a way to add WCF svc-less activation with multiple service Activations?

♀尐吖头ヾ 提交于 2019-12-12 03:35:24

问题


Given the following configuration:

<serviceHostingEnvironment multipleSiteBindingsEnabled="true" >
    <serviceActivations>
        <add relativeAddress="./UserService.svc" service="Mercato.KnowledgeKube.WebSvc.Service.KnowledgeuserManagerService" factory="Mercato.KnowledgeKube.WebSvc.WCF.KnowledgeServiceHostFactory" />
        <add relativeAddress="./ProductService.svc" service="Mercato.KnowledgeKube.WebSvc.Service.ProductManagerWebServices" factory="Mercato.KnowledgeKube.WebSvc.WCF.KnowledgeServiceHostFactory" />
   </serviceActivations>
</serviceHostingEnvironment>

The first of the two ./UserService is reachable and I can create a Service Reference to it, but the ProductServce is not reconcilable. What am I doing wrong here?

EDIT

here is the Exception:

 There was no endpoint listening at http://localhost/KnowledgeWebService/ProductService.svc that could accept the message. This is often caused by an incorrect address or SOAP action. See InnerException, if present, for more details.
The remote server returned an error: (404) Not Found.
If the service is defined in the current solution, try building the solution   
and adding the service reference again.

回答1:


There wasn't an endpoint listening because......I hadn't decorared the product service with the relevant attributes. I was looking for more complex problems first.



来源:https://stackoverflow.com/questions/14343364/is-there-a-way-to-add-wcf-svc-less-activation-with-multiple-service-activations

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!