UtiliZing VSTS for dynamics AX

Slides:



Advertisements
Similar presentations
Testing Relational Database
Advertisements

New Release Announcements and Product Roadmap Chris DiPierro, Director of Software Development April 9-11, 2014
Designing, Deploying and Managing Workflow in SharePoint Sites Steve Heaney Product Development Manager OBS
AXC01 DIXF: The Microsoft Dynamics AX Data Import and Export Framework
HP Quality Center Overview.
Randy Williams, MOSS MVP Senior Consultant Synergy Corporate Technologies.
Building Enterprise Applications Using Visual Studio ®.NET Enterprise Architect.
Microsoft Dynamics AX Technical Conference 2013
Using Microsoft SharePoint to Develop Workflow and Business Process Automation Ted Perrotte National Practice Manager, Quilogy, Microsoft Office SharePoint.
Note: If the local version of the file is already up to date, “get latest” does not load the file into Microsoft Dynamics AX.
Introduction to SharePoint Development with VS2010 Paul Yuknewicz Lead Program Manager
Sage CRM Developers Course
Planning and Tracking Projects with VSTS 2010 By Ahmed Nasr 1.
Basic Developer Knowledge That Every SharePoint Admin Must Have Randy Williams, MVP MOSS Synergy Corporate Technologies
Microsoft SharePoint Server 2010 for the Microsoft ASP.NET Developer Yaroslav Pentsarskyy
Learningcomputer.com SQL Server 2008 – Administration, Maintenance and Job Automation.
Module 13 Implementing Business Continuity. Module Overview Protecting and Recovering Content Working with Backup and Restore for Disaster Recovery Implementing.
Microsoft Management Seminar Series SMS 2003 Change Management.
Presented by Vishy Grandhi.  Architecture (Week 1) ◦ Development Environments ◦ Model driven architecture ◦ Licensing and configuration  AOT (Week 2)
Isolated Database Environments Kevin Howell February 2014.
TEAM FOUNDATION VERSION CONTROL AN OVERVIEW AND WALKTHROUGH By: Michael Mallar.
GO BUILD, YOUNG DEV! AUTOMATING AX BUILDS WITH TFS BRIAN HOF, MARSHALLTOWN.
Release Management for Visual Studio 2013 Ana Roje Ivančić Ognjen Bajić Ekobit.
Can you do this in SmarTeam?
YOUR LOGO Phase 2 International Providing critical business software solutions at affordable prices.
Continuous Delivery and Team Foundation Server 2013 Ognjen Bajić Ana Roje Ivančić Ekobit.
Overview of Basic 3D Experience (Enovia V6) Concepts
Developing SQL/Server database in Visual Studio Introducing SQL /Server Data Tools Peter Lu.Net Practices Director Principle Architect Nexient March 19.
Rome 31 January -1 February Team Development in CRM Shan McArthur CEO / CTO Adxstudio, CRM MVP.
John Lloyd, Edgewater Fullscope
Dynamics AX Henrik Hasselblad Business Unit Manager.
Others Talk, We Listen. Managing Database Projects in Visual Studio 2013.
SQL Database Management
Introduction ITEC 420.
SharePoint 101 – An Overview of SharePoint 2010, 2013 and Office 365
Building Enterprise Applications Using Visual Studio®
Stress Free Deployments with Octopus Deploy
Visual Studio Database Tools (aka SQL Server Data Tools)
SQL Server deployments
Modern Application Lifecycle Management
AX 2012 Code Management & Promotion Best Practices
Beyond the BDC\BCS Model
Development Changes in Dynamics 365 for Finance and Operations
CVS revisions UML diagram
Introduction to Team Foundation Server 2010
Test Upgrade Name Title Company 9/18/2018 Microsoft SharePoint
Application Lifecycle Management – Best Practices for SharePoint and Office App development November 2015.
Scrum Experience Group Team Foundation Server (TFS)
Build /21/2018 © 2015 Microsoft Corporation. All rights reserved. MICROSOFT MAKES NO WARRANTIES, EXPRESS, IMPLIED OR STATUTORY, AS TO THE INFORMATION.
SQL Server Data Tools Gert Drapers
Continuous Integration For Databases
HP Quality Center 10 Hottest Features and Project Harmonization
Microsoft Ignite NZ October 2016 SKYCITY, Auckland.
SharePoint Foundation 2010
持續的產出Windows Azure 雲端服務
Simplified Development Toolkit
Visual Studio Database Tools (aka SQL Server Data Tools)
Quality Assurance in an Agile Development Team Michelle Wu 2018 PNSQC
APPLICATION LIFECYCLE MANAGEMENT(ALM) QUALITY CENTER(QC)
Enterprise Program Management Office
DAT381 Team Development with SQL Server 2005
Presented by : Chirag Dani & Dhaval Shah
SSDT and Database Project Basics
APPLICATION LIFECYCLE MANAGEMENT(ALM) QUALITY CENTER(QC)
Dynamics AX Upgrades Microsoft Dynamics AX 2009
Introduction to VSTS Database Professional
HCL’s Viewpoint – DevOps on MS Cloud
TechEd /23/2019 9:23 AM © 2013 Microsoft Corporation. All rights reserved. Microsoft, Windows, and other product names are or may be registered trademarks.
Office 365 Development July 2014.
Jamie Cool Program Manager Microsoft
Presentation transcript:

UtiliZing VSTS for dynamics AX Brian Hof, Marshalltown Company | Bernd Loske, Edgewater Fullscope

Agenda Development Challenges Source Control Build and Deployment Application Lifecycle Management

Development Challenges

Development Challenges Artifact Id Conflicts Development Conflicts Development Best Practices Compile Errors Code Delivery Revisioning Housekeeping Task Management Inadequate Information

Development Challenges \Classes\FSCustom1 method1() method2() \Classes\FSCustom2 method1() method2() \Classes\SalesFormLetter standard1() \Classes\FSCustom1 method1() method2() \Classes\FSCustom3 method1() method2() \Classes\SalesFormLetter standard1() \Classes\SalesFormLetter standard1() \Classes\FSCustom3 method1() method2() \Classes\SalesFormLetter standard1() \Classes\FSCustom2 method1() method2()

Source Control with VSTS

Source Control General Configure DAX for VSTS Using VSTS Multiple Developer Machines

Source Control - General VSTS is file based Each artifact is exported to .xpo Synchronizations and reverts imports .xpo VSTS Code Repository Archive & Tracing

Source Control - Configuration Developer Configures Developer Machine Create workspace / repository Configure Version Control Parameters Configure TFS Parameters Synchronize Check In

Source Control – Using VSTS Developer Synchronizes with VSTS Synchronize Add to version control Check out Validates against other developers Once we are done – Check in will update the repository. History Rollback

Source Control – Multiple Developers Multiple developer boxes Developers can not modify artifacts that are not checked out. Developers can check out artifacts that are already checked out. Last developer to Check-in has to do the merge.

Source Control USR VSTS worries only about the layer you are in. CUS VAR ISV SYS /SYP

Source Control DEMO

Build & Deployment

Build & Deployment Why automate? Consistency Reliability Collaboration Limit build environment Same steps, same hardware, same software every time Reliability Limit time between builds Frequent build enables frequent verification Collaboration Limit changes between builds Why did it break? Who can fix it? Result: Agility I build (and verify), therefore I release

Build & Deployment How? PowerShell scripts Team Foundation Build Change Management and TFS Integration for Multi-Developer Projects Team Foundation Build Pioneered by Joris de Gruyter Open-source libraries and templates for AX builds CodeCrib.AX.TFS Caveat: TFS 2015 has been released Requires AX 2012 R2/R3 CU9 TFBuild has been overhauled (legacy XAML builds still supported)

Build & Deployment – TFBuild Windows Workflow Foundation (WF) Workflow resembles a flowchart Accepts input parameters Declares (scoped) variables Steps are Activity objects System.Activities.CodeActivity Accepts input arguments System.Activities.InArgument<T> Performs logic Execute() override Returns output arguments System.Activities.OutArgument<T> Visual Studio WYSIWYG editor Stored as .XAML

BUILD & DEPLOYMENT – TFBUILD Concepts: Build process template WF workflow implementing a build process Build definition Configures a specific build in a TFS team project Triggers, workspace, process template, parameters, retention policy, etc Build controller Initiates and monitors builds Build agent Executes builds (selected by controller using tags)

Build & Deployment AX + VSTS ecosystem: Isolated developer systems AOS instance AX client Visual Studio SQL Server (may be shared) Shared version control (TFS) Model code (XPO/ALD files) Team Foundation Build Controller(s) Agent(s) Staging environment(s) Test, Sandbox, Production…

Build & Deployment Goals: Manage complexity (K.I.S.S.) Automate! Single layer customizations Single model customizations TFS issues with AOT elements customized across multiple models Test and develop against actual business data Refreshed often from production My goals, as defined by my work requirements/environment, which will inform the remaining slides. Our production DB ~150 GB

Deep Dive Build & Deployment Suit up, and let’s descend into madness! This will set the stage for how to achieve a solution that meets the goals.

Build & Deployment – Deep Dive AX 2012 Database: Two SQL databases Business data Model data Element IDs Every AOT element has an ID Class, method, table, field, etc Generated when first added Manual creation XPO import Model file import Tie model & business data together Data cannot be haphazardly interchanged! Security objects are one type of element likely to cause noticeable issues if databases become mismatched!

Build & Deployment – Deep Dive Scenario: Alice and Xander begin with same data… Both modify the model (AOT)… Both synchronize the data dictionary… They can no longer swap business databases! OK…but how can they exchange model data? Adds: A1 [ID:1] A2 [ID:2] Deletes: D1 X1 [ID:1] X2 [ID:2] X3 [ID:3]

Build & Deployment – Deep Dive Exchange XPOs? Va′ = A1 [1], A2 [2], X1 [4], X2 [5], X3 [3] Vx′ = A1 [4], A2 [5], X1 [1], X2 [2], X3 [3], D1 Exchange model files? Va′ = X1 [?], X2 [?], X3 [?], D1 Vx′ = A1 [?], A2 [?] Added: A1 [ID:1] A2 [ID:2] Deleted: D1 X1 [ID:1] X2 [ID:2] X3 [ID:3] Synchronize with TFS? Va′ = A1 [1], A2 [2], X1 [4], X2 [5], X3 [3] Vx′ = A1 [4], A2 [5], X1 [1], X2 [2], X3 [3] TFS, then exchange model store file? Alice creates model store file, Xander imports  Same model & IDs  Xander’s model & business data are mismatched XPO – Xander retains D1 (not deleted by XPO import); mismatched IDs Model file – Alice and Xander effectively swap models (element IDs unknown) TFS – Same models; mismatched IDs

Build & Deployment – Deep Dive Solution: Developers synchronize to TFS Element IDs won’t match Doesn’t matter, if they don’t need to share business data Ensure builds remain compatible with deployment targets: 1) Maintain common business data origin between systems 3) Deploy model data exclusively from build system 2) Maintain element ID integrity between builds Build against Temporary DB and Primary DB (next slide)

Build & Deployment – Deep Dive Temporary DB: AOT is reset for each build Uninstall all models before importing XPOs Ensures deleted elements are removed Export temporary model file Element IDs not important Primary DB: AOT must never be reset Code changes must be accumulative Install temporary model file over existing AOT Deleted elements are removed Pre-existing elements & their IDs are preserved New elements are added with new auto-gen IDs Compile updated AOT Export model store file Deploy to any matched target (same data origin) Referring back to my goals: When refreshing a staging environment from production, the build environment’s Primary DB must also be refreshed (and vice versa). When refreshing a developer system from production, simply sync from TFS afterward.

Build & Deployment – Deep Dive Compile via AX client: Slower (single-threaded) Easy to detect success Reliable Compile via AXBuild.exe: Faster (multi-threaded) Difficult to detect success Log: AxCompileAll.html Part actual errors, part false alarms Complicated retry loop Errors in log? Import log into AX client Recompile problem objects Repeat N times Refer to: Blog Post #1 Blog Post #2 Provides code to automate retry process Unreliable Users have observed successful builds which do not actually work* Comparison of the two methods for compiling the AOT. My choice: AX client. *The number of worker threads used by AXBuild.exe may be important to ensure success. General practice: let it decide how many to use.

Build & Deployment Resurface (Example) Now we must learn to swim!

Build & Deployment – Example Build phase: Generate model file Uncompiled AOT .axmodel Generate model store file Compiled AOT .axmodelstore Deployment phase: Restore database (optional) Import model store file Post-deployment tasks Model file only used internally.

Build Phase – Example Model: Model store: Combine XPOs from TFS Using Temporary DB Scrub files* Uninstall all models Synchronize data dictionary Import labels (ALDs from TFS) Import combined XPO Export temporary model file Model store: Using Primary DB Install temporary model file Scrub files* Deploy .NET references Import labels (ALDs from TFS) Import VS projects (from TFS) Compile Full CIL generation Synchronize data dictionary Export model store file *Scrub files – Delete XppIL, cache, VSAssemblies, etc Repeatedly scrub files to avoid various problems! When exporting the model store, you may also export the primary model as an additional build artifact.

Deployment Phase – Example Target system(s): Restore database (optional) Restore SQL backup Business database Model database Post-restore SQL script Scrub files Import model store file Temporary schema Initialize Import model store Apply* Drop Synchronize data dictionary Post-deployment tasks e.g. class MT_PostDeployTasks Notes: *AOS down while applying temporary schema Multiple targets may be specified Supports independent execution (without build) Deploys last successful build Enables progressive deployment pending QA

DEMO Build & Deployment Show & tell: build definition, process template, activity library, build results (VS here; web later during ALM?)

Build & Deployment - References Environment considerations and Microsoft-recommended practices: Models, Layers, and the Model Store [AX 2012] Change Management and TFS Integration for Multi-Developer Projects (white paper) Build and deploy scripts for Microsoft Dynamics AX 2012 (PowerShell) Deploying customizations across Microsoft Dynamics AX 2012 environments (white paper) Building with TFBuild (materials by Joris de Gruyter): How We Manage Development - Automated Builds Easy Automated Builds: Part 1 Part 2 Part 3 Sample build templates CodeCrib.AX.TFS (custom activity library) Class documentation CodePlex open source repository

Application Lifecycle Management

Application Lifecycle Management Requirements Management Task Management Planning Metrics Reporting According to repeatable proven practices

Application Lifecycle Management Centered around Work Items Requirement Risk Issue Task Bug Any entity defined by process template. Attachments, Links

Application Lifecycle Management Accessing VSTS ALM Visual Studio (Team Explorer) TFS Web Access MS Excel MS Project Power BI

Application Lifecycle Management Alerts Dashboards Backlogs Queries API

Source Control DEMO

Final reminders Complete Surveys USE VSTS !

Speaker contact info Brian Hof MARSHALLTOWN brianh@marshalltown.com

Speaker contact info Bernd Loske Edgewater Fullscope FOCUS2016@fullscope.com