Freigeben über


You Are Here

Inside of a service method, how do I know where the message was delivered?

Without defining what distinguishes a location it's hard to explain where 'here' is. I've got a few guesses though based on the most common variations of this question:

- OperationContext.Current.IncomingMessageHeaders.To

OperationContext.Current.IncomingMessageProperties.Via  
  • HostingEnvironment.ApplicationVirtualPath
  • Assembly.GetExecutingAssembly().Location
  • HostingEnvironment.ApplicationPhysicalPath

Next time: Serialization Temporary Assemblies

Comments

  • Anonymous
    June 12, 2008
    Many common networking problems can be diagnosed by tracing System.Net events. This is often much easier