问题
I've got 2 situations in which I need to read in configuration data into BizTalk:
- Within expression shape of orchestration. Compare a part of a message response to a predefined string which is different between environments
- Connection string of a Database lookup in a map
I don't want to have to recompile in order to move between a test and live environment and I will have multiple applications potentially needing their own version of the same configuration element.
I've seen this question but this is server level and seems risky.
My other idea was to use a custom table with an SP to read values back. This means that every time I want to read a setting I have to construct, send and receive a message in the orchestration. It also doesn't help me in the map.
Are there any other options which are less intrusive to the process flow or involve less work/maintenance?
回答1:
The most frequently chosen method to store config data for BizTalk is SSO though there are certainly other options.
You can use the SSO Config Data Storage Tool, http://seroter.wordpress.com/2007/09/21/biztalk-sso-configuration-data-storage-tool/, to maintain the information.
Microsoft has published a sample helper class to read the data, http://go.microsoft.com/fwlink/?linkid=99741.
The BRE might also be an option to consider for the Orchestration.
来源:https://stackoverflow.com/questions/23060889/reading-configuration-in-biztalk-maps-and-orchestrations