0

I have to pass the request ID to it's outgoing WCF service call and take the request ID inside the WCF operation. How can i achieve this.?

To an outgoing Httprequest, I use the CookieContainer and store the ID in a new Cookie and take the ID from the HttpRequest.Cookies from the other application.

Likewise I need to assign value from a web request and call a WCF service operation. And Inside the WCF operation i need to take the assigned value.

How this can be achieved ?

Sel_va
  • 588
  • 5
  • 25

1 Answers1

1

Either

OperationContext.Current.OutgoingMessageHeaders 
OperationContext.Current.IncomingMessageHeaders

within a method or custom class deriving IClientMessageInspector/IDispatchMessageInspector for client and service respectively.

Maximus
  • 3,458
  • 3
  • 16
  • 27