Mixing RIA Services and Standard WCF Services

Is it possible to have a mix of RIA WCF services and custom WCF services hosted on the same project?

At the moment I have a server project that hosts 2 classes of RIA service, both of which work fine, and 1 WCF svc file, which loads in the browser in order (for example, http: //localhost/services/service.svc ) but when I access it through code in the Silverlight client, I get a Not Found error.

I am glad that I am debugging until I resolve it, but I just thought that I would check that I did something stupid at first ...

+3
source share
2 answers

Yes, you should be able to host RIA and regular WCF services in the same project. So far, I have not heard anyone report difficulties with their placement.

Kyle

+1
source

Answer: yes, you just need to be careful how you configure your web.config. New .NET 4.0 multipleSiteBindingsEnabled = "true" caught me. I have specified a relative address in the endpoint address, for example

/services/myservice.svc

but in the metadata it ended up being allowed:

http://localhost/services/myservice.svc/services/myservice.svc

What confused everything. Clearing the endpoint address attribute and updating the links made everything work.

+2
source

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


All Articles