开发者

WCF CallbackContract requires generated Interface instead of the one I specified in ServiceContract?

I have a Service that does a typical implementation of a CallbackContract like the following: [ServiceContract(SessionMode = SessionMode.Required, CallbackContract = typeof(INerveCenterCallBack))]

When I Add a ServiceReference to my WCF Service all works fine. Except when I open the Reference.cs that is generated (ie the auto-generated proxy) I notice that it does this:

CallbackContract=typeof(Synapse.NerveCenter.NerveCenterRef.INerveCenterServiceCallback)

It basically injects both the word "Service" and whatever the namespace I gave the ServiceReference itself at the time of creation "ie NerveCenterRef"

The problem now is when I attempt to connect to my Web Service it Requires that my InstanceContext use a concrete class that inherits from the Generated "NerveCenterRef.INerveCenterServiceCallback" instead of INerveCenterCallBack which I have shared in both a project used by both Client and S开发者_运维知识库erver?

Anyone experience the same or know of hints/why's this is occuring?

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜