So I've been looking around at promoted properties and distinguished fields and I'm not sure how to approach my problem.... Basically all I need is for a 'MessageIdentifier' property to be set to the current message's MessageId within my orchestration.
Here is my code for constructing the message. The FtpTransactionMessage is of XmlDocument type so that I can use custom maps and pipelines at runtime, without defining a construct for every specific type of message I could encounter.
FtpResult = "0"; FtpMapType = System.Type.GetType(ConfigurationClientConfig.FtpConfiguration.Map); FtpToEmsPort(Microsoft.XLANGs.BaseTypes.Address) = "ftp://" + ConfigurationClientConfig.FtpConfiguration.RemoteFQDN + "/" + ConfigurationClientConfig.FtpConfiguration.Filename; construct FtpTransactionMessage { transform (FtpTransactionMessage) = FtpMapType(MessageIn); FtpTransactionMessage(FTP.UserName) = ConfigurationClientConfig.FtpConfiguration.Username; FtpTransactionMessage(FTP.Password) = ConfigurationClientConfig.FtpConfiguration.Password; FtpTransactionMessage(FTP.RepresentationType) = "ASCII"; FtpSendPipeline = new Microsoft.XLANGs.Pipeline.SendPipelineInputMessages(); FtpSendPipeline.Add(FtpTransactionMessage); Microsoft.XLANGs.Pipeline.XLANGPipelineManager.ExecuteSendPipeline(System.Type.GetType(ConfigurationClientConfig.FtpConfiguration.Pipeline),FtpSendPipeline,FtpTransactionMessage); }
The input message, 'MessageIn', as well as 'FtpTransactionMessage' are both XmlDocument types in the orchestration. MessageIn gets converted to FtpTransactionMessage (using XLANG) which is a colon delimited flat-file which gets FTP'd over to some server for processing.
At some point in this transformation I would like to include the orchestration MessageId as the first line in the flat-file. I would like to stay away from a custom pipeline component, if possible.
Any help would be appreciated,
Chris