Join Dan Probert as we take you on a deep dive of Microsoft’s BizTalk Migrator tool. Learn what all the moving parts do, how to modify the configuration, how to improve performance, how to create your scenarios, how to debug the tool when it runs, and how to view the model built behind the scenes. If you have questions, then this is the place to be, as we’ll also have a Q&A session towards the end. In fact, there is so much content, we probably won’t cover everything in one session!
2. ABOUT ME
• Working with BizTalk since 2002
• Wrote a tool called DanSharp XmlViewer (some of you may have used it)
• Working with Azure since 2008
• Developed solutions using WABS/MABS (Azure BizTalk Services)
• Working with Logic Apps since private preview in 2014
• Worked on early Migration Tooling in 2015
• Have been involved in testing and using BizTalk Migrator since
before the private preview
3. AGENDA
• Overview of tool (short!)
• What it does and doesn’t do
• Basic Concepts
• Understanding the output
• Things you may not know
• Performance
• Advanced Features
4. BIZTALK MIGRATOR OVERVIEW
• Microsoft’s open-source tool for automating the migration of
BizTalk to Azure Integration Services
• Source code available here: github.com/azure/aimtool
• Install via Chocolatey: choco install biztalkmigrator --pre
• The tool takes in BizTalk MSIs and generates:
• A report outlining what’s in the MSIs, and what can be converted
• Azure ARM templates and Azure CLI scripts for converted resources
• A set of scripts that will deploy or teardown all resources
6. WHAT IT DOES AND DOESN’T DO
• Handles:
• FTP/File/Http Adapters
• Receive Ports/Send Ports, including Transforms
• XmlReceive/XmlTransmit Pipelines
• JsonDecoder, JsonEncoder, FlatFileDecoder pipeline components
• Simple Orchestrations
• Doesn’t Handle (yet):
• BAM, BRE, SSO
• WCF Adapters, SQL, SFTP, SOAP
• Complex Orchestrations (e.g. expressions, correlation sets)
• Batching/Debatching, Envelopes
7. BASIC CONCEPTS
Message Bus Core components used for any integration solution.
System
Application
BizTalk specific common components e.g. MessageBox, Pipeline
Components.
Scenario A unique path through an application i.e. adaptermsgbox,
msgboxadapter, msgbox msgbox. Every Receive Location, Send Port, or
Orchestration ends up as a scenario.
Intermediary A module that acts on a message as it flows through the bus, for an
example, a JSON Encoder Logic App.
Configuration
Entry
The values specific to a scenario, broken down by intermediary/endpoint.
Routing Slip The path that a message takes through the system for a scenario.
Routing Properties The properties to be promoted into or out of context.
Subscription Used to subscribe to messages from the MessageBox – either to start a
scenario, or to handle a request-response situation.
Checkpoint A pattern used in designing fault-tolerant systems, which allows for
rollback recovery. Used in all Logic Apps to simplify decision branching
and allow for resumption after failure.
8. UNDERSTANDING THE OUTPUT
• What Gets Deployed
• How much does it cost??
• Common Logic Apps
• Logic App Structure
• Envelope Structure
• Receive Adapter
• Send Adapter
9. UNDERSTANDING THE OUTPUT
WHAT GETS DEPLOYED
Message Bus
Config
Store
Routin
g Store
Artifac
t Store
APIM
Config
Mgr
Routin
g
Mgr
Messagi
ng
Mgr
Key
Vault
Storag
e
RSR
Function
s
System
Application
Service
Bus
JSON
Decod
e
JSON
Encode
Flat
File
Decod
e
Topic
Publish
er
Conten
t
Promot
e
Conten
t
Demot
e
Xml
Process
or
Xml
Translat
e
Xml
Validate
etc.
Your ApplicationReceiv
e
Adapte
r
Send
Adapte
r
Topic
Subscrib
er
Process
Manager
API
Connectio
ns
10. UNDERSTANDING THE OUTPUT
HOW MUCH DOES IT COST??
• All chargeable resources use a Free or Lowest-Cost SKU
• Integration Account: Free
• Azure App Configuration: Free
• Azure API Management: Basic
• Service Bus: Standard
• This does mean you may have a conflict where you can only
have a single Free SKU per subscription/region
• Polling defaults to 30s – trade-off between latency and cost
11. UNDERSTANDING THE OUTPUT
COMMON LOGIC APPS
Logic App Description
Message Constructor Creates a new envelope from the supplied content, encoding the content if
necessary. Envelope is equivalent to an XLANGMessage e.g. can have
multiple parts.
Routing Slip Router Looks up the next route in the Routing Slip, gets the address to the route
(usually a Logic App) and makes a call to this address, passing in the
envelope.
XML Message
Processor
Part of a logical “XmlDisassembler”, handles setting MessageType.
Content Promoter Part of a logical “XmlDisassembler”, looks up Routing Properties and
promotes them into context.
Topic Publisher Publishes an envelope to the MessageBox, along with any context
properties.
Topic Subscriber Subscribes to an envelope from the MessageBox, and creates a new
envelope.
This Logic App is specific to a scenario.
<X> Receive Adapter Receives content via a given protocol (e.g. File, FTP, HTTP), calls Message
Constructor, handles receipt of ACK/NACK.
This Logic App is specific to a scenario.
13. Step 2
Step 3
Step 1
UNDERSTANDING THE OUTPUT
LOGIC APP STRUCTURE
Trigger
Action 1
Succes
s?
Connector
1
Action 2
Connector
2
Succes
s?
Action 3
Action 3
14. Step 2
Step 3
Step 1
UNDERSTANDING THE OUTPUT
LOGIC APP STRUCTURE
Trigger
Action 1
Correct
Checkpoi
nt?
Connector
1
Action 2
Connector
2
Succes
s?
Action 3 Action 3
Correct
Checkpoi
nt?
Correct
Checkpoi
nt?
Succes
s?
Set
Checkpoint
Set
Checkpoint
Set
Checkpoint
15. UNDERSTANDING THE OUTPUT
ENVELOPE STRUCTURE
envelope
header
properties
state
routing
routingSlip
body
$part
$partType
$contentType
$contentTransferEncoding
$content
16. UNDERSTANDING THE OUTPUT
RECEIVE ADAPTER
Adapter
Message
Construct
or
APIM
Azure App
Config
Cach
e
Routing
Slip Router
Azure
Functions
API
Conn
Xml
Message
Processor
Content
Promoter
Xml
Translator
Topic
Publisher
Message
Box
ACK/NAC
K
17. UNDERSTANDING THE OUTPUT
SEND ADAPTER
Topic
Subscriber
APIM
Azure App
Config
Cach
e
Routing
Slip Router
Azure
Functions
API
Conn
Xml
Translator
Content
Demoter
JSON
Encoder
Adapter Endpoint
ACK/NAC
K
Message
Box
18. THINGS YOU MAY NOT KNOW
• You don’t need to use this tool with BizTalk
• The MessageBus and System Application resources can be used to build
an integration application which didn’t come from BizTalk
• The generated resources give you a good base for creating you own
application
• You can automate the refresh of the APIM cache
• APIM Caching is used to cache config, routing slips, schema names etc.
• Using Event Grid, we can clear the cache after config is updated
• You can change the route (e.g. add Flat File Decoder) via config
• The Routing Slip describes the path that a message takes – you can add
references in to other supplied intermediaries, or to your own
intermediaries
19. PERFORMANCE
• Performance is relative to your expectations
• Cold Start performance is not great – why?
• Inline Code start-up
• Azure Functions start-up
• Azure App Config start-up
• Integration Account Transform/Validate start-up
• Warm Start is better, but not as good as BizTalk – why?
• Polling Model – cost vs latency
• Latency involved with Logic Apps, APIM, Functions
• Unlike with BizTalk, your latency won’t increase as your throughput does
• You need to ask yourself: what latency can I live with, and what am I willing
to pay to get better latency?
20. PERFORMANCE
HOW TO GET BETTER LATENCY
• Decrease Polling Time for Receive Adapters and Topic
Subscriber
• Vote for Microsoft to produce an Event Grid version of the Service Bus
Trigger
• Use simpler routes e.g. XmlReceivePipeline
• Write a scheduler to “kick” each scenario to prevent Cold Start
• Move to Stateless Logic Apps
21. ADVANCED FEATURES
• Using your own APIM/Integration Account/Azure App Config
etc.
• Changing Configuration
• Changing the Routing Slip
• Adding the Flat File Decoder
• Converting an Orchestration
22. ADVANCED FEATURES
HOW DO I USE MY OWN APIM/INT ACCOUNTS/ETC.
• 2 ways of doing this:
• Search and replace in the deployment files
• Edit the generated target model file:
• Run the tool in Assess mode and use the option to output a model file (-o
<path>)
• Edit the model file
• Run the tool in Convert mode and use the option to import a model file (-m
<path>)
23. ADVANCED FEATURES
CHANGING CONFIGURATION
• Find your scenario in Azure App Config, look for the
ConfigurationEntry label:
• Edit the value (will be in a text box and hard to read)
• Paste into Notepad++ and format as
JSON (enable JSON Viewer plugin)
• Modify, and update it back into
App Config
24. ADVANCED FEATURES
CHANGING CONFIGURATION
• A Configuration File contains a section for each Intermediary called in
the route for this scenario
• Properties are a combination of BizTalk-specific properties, and other
properties specific to that Intermediary
• Note that some config values are actually specified as parameters in a Logic
App
• After you change configuration, you have to refresh the cache
• Can do this by making a call to get your config via APIM, and setting
the option to clearCache
• OR… write your own Event Grid triggered Logic App that does this for
you
• DEMO: Showing the Config Cache Updater
25. ADVANCED FEATURES
CHANGING THE ROUTING SLIP
• Follow same steps as for Config Entry, but use the RoutingSlip
label
• Add or remove values from the route
• Update the entry in Azure App Config
• Remember: update your config to match
• DEMO: Adding the FlatFileEncoder