🔄 Real-Time Example: Code Migration Using Azure DevOps
Project: Data Pipeline for Sales Analytics
Use Case: Load and transform daily sales data from on-prem SQL Server to Azure Data
Lake using ADF and PySpark notebooks.
Environments
Development (Dev)
Test/QA
Production (Prod)
Step-by-Step Migration Flow
✅ 1. Development Phase
Developer builds ADF pipeline and PySpark notebook in Dev environment.
Version controlled using Git Repo (Azure Repos).
Code reviewed and committed to develop branch.
Artifacts:
ADF pipeline JSON
Linked services
Datasets
PySpark notebooks
📦 2. Create a Pull Request
Create pull request from develop to release/qa in Azure DevOps.
PR is reviewed and approved by team lead.
🔁 3. CI/CD Pipeline Triggers
On merge to release/qa:
Build pipeline packages the ADF JSON, PySpark scripts.
Release pipeline deploys to QA environment using ARM templates and Databricks
CLI/API.
✅ 4. QA Testing
QA team tests pipeline with sample data.
Validate:
Data accuracy
Notebook execution
Pipeline schedule
🚀 5. Promotion to Production
After sign-off, pull request created from release/qa to main.
Merge triggers final release pipeline, deploying code to Production.
Visual Map of Flow
sql
Copy
Edit
Azure Repos (Dev Branch)
↓
Pull Request → release/qa
↓
Azure Pipelines:
- Build: Validate ADF JSON, PySpark
- Release: Deploy to QA
↓
Testing in QA
↓
Pull Request → main (Production)
↓
Final Release Pipeline: Deploy to PROD
🔧 Tools & Features Used
Azure Repos – version control
Azure Pipelines – CI/CD automation
ARM templates – infrastructure as code for ADF
Databricks CLI – for notebook deployment
Release Gates – for approval workflows