BizTalk maps – problem solving scenarios
If we consider the BizTalk architecture;
from the 'BizTalk Server: Presentations Gallery' We can see that there are 3 possible places where your maps are executed (in classic BizTalk);
- Inbound (on the receive port)
- Outbound (on the send port)
- Business Process (within an orchestration)
- We have an issue, we know it is in the map (analysis of the exception, output)
- We let the team from ‘fixoursystem-land’ solve the issue in their dev, they test it before usage
- We deploy it to the test environment, they test it before usage (deployed by a dev/admin)
- We deploy it to the critical/live environment….(deployed by an admin)
- We need to ensure that the correct version is deployed….how?
Let’s consider the options that we have in this scenario, can we do a test without visual studio?
DEV | ACC | PROD | |
Visual Studio allowed | Yes | No | No |
Risk of corrupting a system when running tests | Low | High | Unacceptable |
Testing maps possible without live environment | Yes | No | No |
So basically no way, without possibly changing the connected systems! Considering each environment, we typically have the following options are available…
DEV
· Testing maps using inbound/outbound/within an orchestration
o Visual Studio
o Live on the BizTalk environment by submitting messages
o Single part, supported by ‘Test map’
· Requirements
o Visual Studio
o Live environment (low risk of corrupting a system)
· Drawbacks
o Multi part are only supported by manually creating a message using ‘Test map’, ‘Generate instance’ per schema, copy paste required structures
TEST
· Testing maps using inbound/outbound/within an orchestration
o Visual Studio (not recommended having this on this environment, but possible)
o Live on the BizTalk environment by submitting messages (low risk of corrupting a system)
· Requirements
o Visual Studio
o Live environment (medium risk of mutating external systems, backup is probably available, data can be removed)
o Alternative: Retrieve dll from the GAC and run it on the DEV environment (risk of version conflicts)
· Drawbacks
o Timeconsuming
o Risk of errors
ACC/PROD:
· Single part message
o Visual Studio (not recommended having this on this environment, but possible)
o Live on the BizTalk environment by submitting messages (low risk of corrupting a system)
· Multi part message
o Manually, by creating messages on a DEV environment (low risk of corrupting a system as TEST is)
· Requirements
o Visual Studio
o Live environment (high risk of mutating external systems, backup is probably not available, data cannot be removed)
o Alternative: Retrieve dll from the GAC and run it on the DEV environment (risk of version conflicts)
· Drawbacks
o Timeconsuming
o Risk of manual errors
Just for these situations, where you need more than the standard offering provides, go where no man has gone before, there is a tool (without any warranty), which enables you to do a lot more. This tool is called the ‘Map Test tool’ developed by Tomasso Groenendijk. This enables the following scenarios:
· Test maps which are not yet deployed (so basically, only test the dll)
· Test maps which are deployed
· Test Multipart maps (using a wizard)
So not saying you should, but now you could ensure that a fix has been applied correctly, even on an environment without Visual Studio installed.
Using the tool
Follow the next steps to test a map with real data from multiple input messages:
Click in the File menu on the menu item “Create envelope with multiple input messages”.
|
In the Wizard pop-up click on the “Add File” button to select a XML file to add to the envelope. You can select multiple input messages. Click on “Finish” to create the envelope.
|
Enter the filename of the envelope in the “Save As” pop-up and click on the “Save” button.
|
Enter the fully qualified name of the map and click on the “Test Map” button to test the map.
|
In the Result tab is the transformed message shown. In the Info screen is the execution time shown and the name of the transformed file.
|
Even though this tool was already very sophisticated, I couldn’t stand having to manually go ahead and look up the Fully qualified name, so I made a minor contribution ‘AssemblyPicker’ which lets you select the map from the GAC.
You can select all the maps residing inside an assembly and pick the map you need;
Note: As I also use the ESB Rule tester quite often, I also added a ‘Policy Picker’, which should be included in the new version as well :)
HTH,
Sander
Comments