WCF with netTCPBinding


Hi

I have written wcf service
everything works fine when i deploy it on IIS7 with http binding.
 
I want to deploy the same on Windows Process Activation Services (WAS) using netcp binding.
when i try to create proxy for the service using svcutil
i am getting below error message:
Error: Cannot obtain Metadata from net.tcp://localhost/myservice/servi
ce.svc
If this is a Windows (R) Communication Foundation service to which you have acce
ss, please check that you have enabled metadata publishing at the specified addr
ess.  For help enabling metadata publishing, please refer to the MSDN documentat
ion at http://go.microsoft.com/fwlink/?LinkId=65455.

WS-Metadata Exchange Error
    URI: net.tcp://localhost/servicemodelsamples/service.svc
    Metadata contains a reference that cannot be resolved: 'net.tcp://localhost/
servicemodelsamples/service.svc'.
 
here is web.config:
 
<

system.serviceModel>
<

services>
<

service name="MyProj.Myservice"
behaviorConfiguration="CalculatorServiceBehavior">
<!--

This endpoint is exposed at the base address provided by host: net.tcp://localhost/servicemodelsamples/service.svc -->
<

endpoint binding="netTcpBinding" bindingConfiguration="PortSharingBinding"
contract="MyProj.ICalculator" />
<!--

the mex endpoint is explosed at net.tcp://localhost/servicemodelsamples/service.svc/mex -->
<

endpoint address="mex"
binding="mexTcpBinding"
contract="IMetadataExchange" />
</

service>
</

services>
<

bindings>
<

netTcpBinding>
<

binding name="PortSharingBinding" portSharingEnabled="true">
<

security mode="None" />
</

binding>
</

netTcpBinding>
</

bindings>
<!--

For debugging purposes set the includeExceptionDetailInFaults attribute to true-->
<

behaviors>
<

serviceBehaviors>
<

behavior name="CalculatorServiceBehavior">
<

serviceMetadata />
<

serviceDebug includeExceptionDetailInFaults="False" />
</

behavior>
</

serviceBehaviors>
</

behaviors>

Thanks,
ram27Asked:
Who is Participating?

[Product update] Infrastructure Analysis Tool is now available with Business Accounts.Learn More

x
I wear a lot of hats...

"The solutions and answers provided on Experts Exchange have been extremely helpful to me over the last few years. I wear a lot of hats - Developer, Database Administrator, Help Desk, etc., so I know a lot of things but not a lot about one thing. Experts Exchange gives me answers from people who do know a lot about one thing, in a easy to use platform." -Todd S.

Aaron JabamaniTechnical ArchitectCommented:
0

Experts Exchange Solution brought to you by

Your issues matter to us.

Facing a tech roadblock? Get the help and guidance you need from experienced professionals who care. Ask your question anytime, anywhere, with no hassle.

Start your 7-day free trial
It's more than this solution.Get answers and train to solve all your tech problems - anytime, anywhere.Try it for free Edge Out The Competitionfor your dream job with proven skills and certifications.Get started today Stand Outas the employee with proven skills.Start learning today for free Move Your Career Forwardwith certification training in the latest technologies.Start your trial today
WCF

From novice to tech pro — start learning today.