In addition to Weibo, there is also WeChat
Please pay attention
WeChat public account
Shulou
2025-04-07 Update From: SLTechnology News&Howtos shulou NAV: SLTechnology News&Howtos > Servers >
Share
Shulou(Shulou.com)06/01 Report--
This article mainly introduces how to do WCF mistakes, has a certain reference value, interested friends can refer to, I hope you can learn a lot after reading this article, the following let the editor take you to understand it.
1. An error is reported after running self-hosting:
System.ServiceModel.AddressAccessDeniedException' occurred in System.Servic
System.ServiceModel.AddressAccessDeniedException:... Http://+:9999/calculatorService/...
Run cmd with administrator privileges to solve the problem of HTTP namespace protection. After you open cmd, run
"netsh http add urlacl http://+:9999/calculatorService/ user=everyone"
two。
System.ServiceModel.CommunicationObjectFaultedException
The communication object, System.ServiceModel.ServiceHost, cannot be used for communication
And check the timeout displayed in stack, guess that the permissions are not enough, restart vs, and right-click to select Properties-> compatibility-> run as an administrator.
Success
3.
'System.ServiceModel.Security.SecurityNegotiationException' occurred in mscorlib.dll
Additional information: SOAP security negotiation with 'http://xlt1159-cn1:9999/messageService' for target' http://xlt1159-cn1:9999/messageService' failed. See inner exception for more details.
Problem: WCF security issues, if you do not need to consider security, the easiest way to set security.mode to Node.
For example, add code to service:
WSHttpBinding wsb = new WSHttpBinding ()
Wsb.Name = "TestBinding"
Wsb.Security.Mode = SecurityMode.None
Add code to client:
WSHttpBinding wsb = new WSHttpBinding ()
Wsb.Name = "TestBinding"
Wsb.Security.Mode = SecurityMode.None
Wsb.Security.Message.ClientCredentialType = MessageCredentialType.None
(https://msdn.microsoft.com/en-us/library/ms731925.aspx)
4. If the WCF server is remote, you need to enter the start number on the server and add a rule in the firewall.
Thank you for reading this article carefully. I hope the article "what to do with WCF mistakes" shared by the editor will be helpful to everyone. At the same time, I also hope that you will support us and pay attention to the industry information channel. More related knowledge is waiting for you to learn!
Welcome to subscribe "Shulou Technology Information " to get latest news, interesting things and hot topics in the IT industry, and controls the hottest and latest Internet news, technology news and IT industry trends.
Views: 0
*The comments in the above article only represent the author's personal views and do not represent the views and positions of this website. If you have more insights, please feel free to contribute and share.
Continue with the installation of the previous hadoop.First, install zookooper1. Decompress zookoope
"Every 5-10 years, there's a rare product, a really special, very unusual product that's the most un
© 2024 shulou.com SLNews company. All rights reserved.