Post on 16-Apr-2017
Sponsored & Brought to you by
BizTalk ALMToon Vanhoutte
https://twitter.com/ToonVanhoutte
https://be.linkedin.com/pub/toon-vanhoutte/6/276/84b
Integration MondayBizTalk ALM by Toon Vanhoutte
Nice to meet youToon VANHOUTTEIntegration Architect
toon.vanhoutte@codit.eu+32 479 905 115@ToonVanhoutte
+9 years Microsoft IntegrationMicrosoft Certified TrainerSpecific interest in ALM & B2BAS4 OASIS Committee Member
Agenda
Scope Unit Test Build Deploy
Continuous Integration
Integration Test
Scope➔ Focused on Continuous Integration➔ Technical side of BizTalk ALM➔ Based on community software➔ On premise, although cloud is very similar➔ Not covered in this session:
➔ TFS details, branching, versioning strategy, automatic release notes, load testing, test coverage, check-in policies, NuGet, SCRUM,…
5
I’m uncertain to change a setting of this complex
flat file schema.
I’ll make a copy of this pipeline component. It’s used in too many flows.
When regenerating schemas, I often forget
to update property promotion.
Deployment is too complex for operation
team, so I spend a lot of time on that.
Old bugs are returning in new releases. This
regression is unacceptable.
We can’t afford a long downtime on production
for deployments.
We need faster release cycles to fulfill the fast
changing business needs.
Existing pain points from the field
7
Application Lifecycle Management
Analyze
Requirements
Analysis Template
Functional
Technical
Develop
Team
Dependencies
Source Control
Release
Versioning
Build
Deploy
Upgrade
Maintain
Support
Hotfixes
Monitor
Continuous Integration
8
Methodology
Code Repository
Daily Check-In
Build Automation
Test Automation
Deploy Automation
Adva
ntag
es Early bug detection
Quality of delivery
Increased release cadence
Disa
dvan
tag
es
Initial setup
Extra cost: hard- & software
Continuous maintenance
Return on Investment?
Bringing it all together
9
BTS
CIALM
No out-of-the-box BTS support in TFS
No out-of-the-box BTS deployment tool
Integration testing instead of unit testing
Customize build workflow
Buy, DIY or use community tools
Auto testing on deployed BizTalk environment
Granularity of deploymentFine grained solution structure
Scenario
10
ERPSystem
Receive Portrl_Invoices.SQL
GenericXmlReceive
SQLDebatch
OrchestrationRouter
Routing
Set Destination + Destination Type
Send Portsp_Invoice_Codit.FILE
spl_CoditInvoice
FILE
Send Portsp_Invoice_Microsoft.FILE
spl_MicrosoftInvoice
FILE
Transform CreateFlat File
SetFileName
OrchestrationCurrency Converter
Transform
Create Convert Request
Transform
Merge Convert Response
Send Portsp_CurrencyConverter.WCF
PassThruTransmit
XMLReceive
WCF
WCF
Send Portsp_Invoice_Northwind.FILE
PassTrhuTransmit
FILE
CurrencyConverter
BizTalk.Demo.ALM.Core BizTalk.Demo.ALM.Invoicing
11
Unit TestingTests running on the codebase (without a deployed BizTalk
application)➔ Use Unit Tests also to increase productivity (developer tools)➔ Create data-driven Unit Tests➔ Create a least one Unit Test per bug➔ Focus also on negative testing➔ Unit Tests are valuable for:
➔ .NET libraries➔ Schemas➔ Maps➔ Pipelines➔ Pipeline Components
12
Unit TestingUnit Testing of a Flat File Schema
➔ Create a data-driven test
➔ Use Winterdom SchemaTester
13
Unit TestingUnit Testing of a Map➔ Use BizTalk Map Test Framework
➔ Create on base test (only 1 template file to maintain)➔ Support for generated dates and GUIDs➔ Define multiple test cases / variations within Unit Tests
• Custom libraries called from the map• Decision logic• Looping logic• Grouping logic• Sorting logic• Calculation logic• …
14
Unit TestingUnit Testing of pipelines and pipeline components ➔ Use Winterdom PipelineTester➔ Generate pipelines on the flow➔ Test on message content and context:
➔ Debatching➔ Property promotion via schemas + disassembler➔ Property promotion via custom components➔ Transforms or content modifications within pipelines
Automated Build
15
Continuous build for Unit Testing
Source Control Check-In Branching Labeling
1
Build Workflow Get Code Base Build Unit Testing
2
16
Automatic DeploymentSeveral options available➔ Standard BizTalk MSI + pre/post processing scripts➔ PowerShell + Microsoft deployment libraries➔ BizTalk Deployment Framework (here)➔ MSBuild Extension Pack for BizTalk (here)➔ BtsMsiTask (here)➔ Codit DeployFx + ALM Suite (here)
17
BizTalk Deployment FrameworkFeatures➔ Create BTDF MSI during build (without deploy)➔ Binding File Management via Excel➔ Automatic deployment with PowerShell➔ Versioning of MSI➔ Deployment on BizTalk application level➔ Fully extensible
Automated Build
18
Deployment build with versioning and deployment
Source Control Check-In Branching Labeling
1
Build Workflow Get Code Base Build Unit Testing
2
Build Workflow Get Code Base Versioning Build Unit Testing Deployment
Auto Deploy Import MSI (*) Install MSI (*) D/T/A/P
3 ACCPROD
PowerShell Scripts➔ BTDF-UpdateVersion.ps1
19
Based on BizTalk ALM Codeplex
➔ Updates AssemblyFileVersion for each assembly
➔ Updates BTDF MSI Version
PowerShell Scripts➔ TFS-CopyFilesToDropFolder.ps1
20
Based on BizTalk ALM Codeplex
➔ Copies files from build agent folder to Build Output➔ Copies all required files into a deployable package
Build Agent Folder Build Output
PowerShell Scripts➔ BTDF-Deploy.ps1
21
Based on BizTalk ALM Codeplex
➔ Deploys all MSI’s in the package, taking into account application references and archive location
Deploy Package
Archive
BizTalk
Core-3.0.0.msiInvoicing-1.0.0.msiInvoicing-2.0.0.msi
Core-4.0.0.msi
Core Invoicing
➔ Undeploy Invoicing➔ Undeploy Core➔ Deploy Core-4.0.0.msi➔ Deploy Invoicing-
2.0.0.msi➔ Archive Core-4.0.0.msi
Integration Testing using Transmock
22
ERPSystem
Receive Portrl_Invoices.SQL
GenericXmlReceive
SQLDebatch
OrchestrationRouter
Routing
Set Destination + Destination Type
Send Portsp_Invoice_Codit.FILE
spl_CoditInvoice
FILE
Send Portsp_Invoice_Microsoft.FILE
spl_MicrosoftInvoice
FILE
Transform CreateFlat File
SetFileName
OrchestrationCurrency Converter
Transform
Create Convert Request
Transform
Merge Convert Response
Send Portsp_CurrencyConverter.WCF
PassThruTransmit
XMLReceive
WCF
WCF
Send Portsp_Invoice_Northwind.FILE
PassTrhuTransmit
FILE
CurrencyConverter
BizUnit Test Case
Mock
Mock
MockSendStep MockReceiveStep
Mockifier
Automated Build
23
Deployment build with versioning, deployment and integration testing
Source Control Check-In Branching Labeling
1
2
Build Workflow Get Code Base Versioning Build Unit Testing Deployment
Auto Deploy Import MSI (*) Install MSI (*) D/T/A/P
3 ACCPROD
Build Workflow Get Code Base Versioning Build Unit Testing Deployment Integration Test
Winterdom Pipeline &
Schema Testing
...
BizTalk Map Test
Framework
BizTalk Deployment Framework
BizTalk ALM Guidance
Transmock Integration
Testing
Powered by the community
Questions?