-
Notifications
You must be signed in to change notification settings - Fork 572
Closed
Description
I'm providing a WCF service in my .net core project via SoapCore. In one of the methods, I want to access the SOAP envelope header info. To test that, I've added the following code:
[ServiceContract]
public interface IDataService {
[OperationContract]
string TransmitObject(XElement node);
}
// -------------------------------------------------------------------------
public string TransmitObject(XElement node) {
foreach(var header in OperationContext.Current.IncomingMessageHeaders) {
Console.WriteLine(header.ToString());
}
return JsonConvert.SerializeXNode(node, Formatting.None);
}However, in this case, the OperationContext.Current attribute is always null. What do I need to change in order to make that work?
Metadata
Metadata
Assignees
Labels
No labels