Introduction
In this article, we will explore how to connect your git repository with Azure Data Factory. This will allow us to track changes and manage our code throughout the development lifecycle.
Challenges
In our earlier article, we have successfully deployed our Azure Data Factory pipelines. All the source codes are stored inside Data Factory and any saved changes will be live. The engineering team needs a development area which allows them to save partial developed code and a testing area separate from the live system.
We can achieve this by enabling git integration in Azure Data Factory. Another added advantage is to have a code repository to store our source code to track and review any code changes.
Let's go over some concepts first:
- Live mode: All saved changes are 'live'. All the source code is stored in Data Factory and it does not have a source control repository. This mode does not allow saving of partial code because all changes are live. For development environment, this mode is not recommended.
- Feature branch: A git branch created for development. The pipelines in this branch can only be executed through debug and not triggers. After development is completed, the code needs to be merged into the Collaboration branch.
- Collaboration branch: A git branch that stored the JSON code. All the files in this branch is ready for testing.
- Publish branch: The ARM templates of the live code in the Collaboration branch. By default, this is adf_publish.
Creating git repo and branches
Before we can dive into the git integration in ADF, let's create our git repo. This can be done in Azure DevOps or GitHub. I have created the following:
- Repo name: adf-repo.
- Create the collaboration branch: dev.
- Create the publish branch: adf_publish_dev.
By creating a 'dev' specific collaboration and publish branches, it gives us the flexibility to add an uat and production environments in the future.
Integrating git with ADF
In this example, I will be using Azure DevOps. If you are using GitHub, the steps will be similar.







Join the conversation! Your thoughts help the community grow.