Setting the Message Via
Can I write a point-to-point router service by setting the Via property for outgoing messages?
Like most things, this is going to depend on the specific behavior of the transport channel you're using, but in general the answer is no. The transport channel owns the Via property and it will stomp over whatever you write into the message headers. You do have one opportunity to set the channel's Via, which is during the creation of the channel from the channel factory. After that, the matter is out of your hands.
This would imply creating a channel per message or keeping a pool of these channels around to farm out messages if you keep using the same destinations over and over. There is a different story if what you want to route to is the ultimate receiver To address instead of the Via address. You can set the To address on a per-message basis, assuming that the transport channel has implemented the ManualAddressing setting.
Next time: Enabling Kerberos in IIS
Comments
- Anonymous
March 30, 2007
Once you've obtained a channel manager from the binding element, you have the first object that is usable