wcf-client


Client timeout when using WCF through Spring.net

守給你的承諾、 提交于 2020-01-25 09:22:05
问题 I'm using WCF through Spring.net WCF integration link text This works relatively fine, however it seems that WCF and Spring get in each other's way when instantiating client channels. This means that only a single client channel is created for a service and therefore the clients get a timeout after the configured timeout is expired since the same client channel has been open since it was instantiated by Spring. To make the matters worst, once a channel goes to a fault state, it affect all

How do I use WCF reference with MVC3 (razor) model?

微笑、不失礼 提交于 2020-01-23 12:06:28
问题 I have a WCF Service and a MVC3 (razor) web site. All my data comes from the WCF Service . I have my controllers and views but, how do I use the model with this structure ? for now, I call my method from the service with a DataController and I called them in the Controllers.. Better solution ? 回答1: Do you want to access a WCF service from your Model? Ouch... Stick to the Controller. Controllers interact with services, models don't. 回答2: 1.You created web reference to your service - and

How do I use WCF reference with MVC3 (razor) model?

依然范特西╮ 提交于 2020-01-23 12:05:47
问题 I have a WCF Service and a MVC3 (razor) web site. All my data comes from the WCF Service . I have my controllers and views but, how do I use the model with this structure ? for now, I call my method from the service with a DataController and I called them in the Controllers.. Better solution ? 回答1: Do you want to access a WCF service from your Model? Ouch... Stick to the Controller. Controllers interact with services, models don't. 回答2: 1.You created web reference to your service - and

WCF Timeout issue?

狂风中的少年 提交于 2020-01-21 03:32:08
问题 I have a somewhat long-taking WCF-based process. WCF service runs in Azure if its of any help. The issue I believe has to do with timeouts: 1) Winforms client has the following .config setting in the binding section: <wsHttpBinding> <binding name="XXX" closeTimeout="00:05:00" openTimeout="00:05:00" receiveTimeout="00:10:00" sendTimeout="00:10:00" bypassProxyOnLocal="false" transactionFlow="false" hostNameComparisonMode="StrongWildcard" maxBufferPoolSize="10000000" maxReceivedMessageSize=

Can I differentiate a timeout from a message size issue using only CommunicationException?

若如初见. 提交于 2020-01-17 11:11:11
问题 Folks, I hit the following exception and I know for a fact that its not a timeout issue and that its a message size issue. Using ONLY the CommunicationException, is there a way to tell that this issue was a message size issue and not a timeout issue? Perhaps one of the properties on CommunicationException? or maybe it can be cast in a certain way? I'm willing to explore any proposals. System.ServiceModel.CommunicationException: The socket connection was aborted. This could be caused by an

Adding an outgoing message headers in WCF can't be retrieved in incoming message headers

孤街醉人 提交于 2020-01-16 16:58:45
问题 I am using WCF Services for my application. I've got three functions - Add, GetList, GetSingle. To create the service on the client-side, I am using this code: Public Shared Function GetService(ByRef oScope As OperationContextScope) As XService.XServiceClient Dim oService As New XService.XServiceClient oScope = New OperationContextScope(oService.InnerChannel) oService.Open() Dim oMessageHeader As System.ServiceModel.Channels.MessageHeader = MessageHeader.CreateHeader("SecurityContext", String

Adding an outgoing message headers in WCF can't be retrieved in incoming message headers

放肆的年华 提交于 2020-01-16 16:58:36
问题 I am using WCF Services for my application. I've got three functions - Add, GetList, GetSingle. To create the service on the client-side, I am using this code: Public Shared Function GetService(ByRef oScope As OperationContextScope) As XService.XServiceClient Dim oService As New XService.XServiceClient oScope = New OperationContextScope(oService.InnerChannel) oService.Open() Dim oMessageHeader As System.ServiceModel.Channels.MessageHeader = MessageHeader.CreateHeader("SecurityContext", String

Setting MessageHeaders.To field gets overwritten

♀尐吖头ヾ 提交于 2020-01-15 11:54:29
问题 Here's the scenario: I'm trying to send a SOAP message to an intermediary router service. That service only cares about my SOAP message headers, and uses the WS-Addressing To header to forward along my message. I need to basically POST a request like the following to the router service: POST http://gatewayRouter/routingService HTTP/1.1 Content-Type: application/soap+xml; charset=utf-8 Host: gatewayRouter Content-Length: 8786 Expect: 100-continue Connection: Keep-Alive <s:Envelope xmlns:s=

Setting MessageHeaders.To field gets overwritten

假装没事ソ 提交于 2020-01-15 11:53:06
问题 Here's the scenario: I'm trying to send a SOAP message to an intermediary router service. That service only cares about my SOAP message headers, and uses the WS-Addressing To header to forward along my message. I need to basically POST a request like the following to the router service: POST http://gatewayRouter/routingService HTTP/1.1 Content-Type: application/soap+xml; charset=utf-8 Host: gatewayRouter Content-Length: 8786 Expect: 100-continue Connection: Keep-Alive <s:Envelope xmlns:s=

Strange exception when connecting to a WCF service via a proxy server

爷,独闯天下 提交于 2020-01-14 09:17:07
问题 The exception " This operation is not supported for a relative URI. " occurs in the following situation: I have a WCF service: [ServiceContract(ProtectionLevel=ProtectionLevel.None)] public interface IMyService { [OperationContract] [FaultContract(typeof(MyFault))] List<MyDto> MyOperation(int param); // other operations } public class MyService : IMyService { public List<MyDto> MyOperation(int param) { // Do the business stuff and return a list of MyDto } // other implementations } MyFault

工具导航Map