# How to Migrate an Integration

When developing integrations, Sandbox Banking Solution Engineers utilize separate `DEV` and `PROD` environments to write code and test changes before deploying that code to a production environment.&#x20;

When changes to an integration are ready to be deployed to the `PROD` environment, Integration Gateway provides two methods for performing a migration:

* [Migrating a whole integration](#migrating-a-whole-integration)
* [Migrating part of an integration](#migrating-part-of-an-integration)

### Migrating a Whole Integration

The *Migrate* page (pictured below) allows a user to select integrations from a source environment (often, the `DEV` environment) to be migrated into the destination system (the current logged-in environment, often `PROD`).&#x20;

<figure><img src="https://688288018-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F1flQ2To8tQpCQWl2Ty9U%2Fuploads%2FJFurcZZbaAustlrjbyvy%2FScreenshot%202024-10-09%20at%202.38.50%E2%80%AFPM.png?alt=media&#x26;token=5b0f0d09-cd24-41b4-903f-51d6b5426804" alt=""><figcaption></figcaption></figure>

To migrate an integration in its entirety:

1. Navigate to the *Migrate* page using the navigation sidebar.
2. Select the *Source* environment in the left-hand pane. Often, this is the corresponding `DEV` environment.
3. Select the integration(s) to be migrated in the right-hand pane.
4. Verify that the *Standard Migration* option is selected, then click *Perform Migration.*
5. Verify that the correct integration(s) were migrated by reviewing the migration summary (pictured below).

<figure><img src="https://688288018-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F1flQ2To8tQpCQWl2Ty9U%2Fuploads%2FybbYD5plVm05Zhp442Oa%2FScreenshot%202024-10-09%20at%202.40.51%E2%80%AFPM.png?alt=media&#x26;token=2f575532-4d6d-4829-a5ab-a5e5a950eb98" alt=""><figcaption><p>A successful migration summary</p></figcaption></figure>

In the example above, we see that 1 integration, which contained 3 Service Requests, was migrated.&#x20;

{% hint style="info" %}
Migrating a whole integration will replace the copy of the integration that's currently in the environment.&#x20;
{% endhint %}

### Migrating Part of an Integration

Integration Gateway also supports migrating selected portions of an integration, while leaving the rest of the integration as-is. The selected changes are called a c*hangeset,* and this type of migration is called a *Changeset Migration.*

Changeset migrations are useful in situations such as:

* There is parallel development on different parts of an integration
* The `DEV` version of an integration contains development-specific logic that should not be migrated to a production environment

To perform a changeset migration:

1. Navigate to the *Migrate* page using the navigation sidebar.
2. Select the *Source* environment in the left-hand pane. Often, this is the corresponding `DEV` environment.
3. Click *View Incoming Changes.* This will open the *View Changes* page, which resembles the *Build* page, but includes two additional columns.\
   \
   \&#xNAN;*Migrate* indicates whether a change should be included in the migration.\
   \&#xNAN;*Change* describes the type of change (add / edit / delete).\
   ![](https://688288018-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F1flQ2To8tQpCQWl2Ty9U%2Fuploads%2FhXce83ilLq0pDNsN0Kaq%2Fimage.png?alt=media\&token=ebfc62f7-2b1c-43e2-b0f1-0d7f079742f8)
4. Using the *View Changes* page, select the changes you wish to include in the migration changeset by setting the *Migrate* column to `true` for the selected rows.
5. When you're finished selecting specific changes, click *Save Change Set* on the toolbar along the bottom right. This will show a summary of the selected changes, along with a text field to optionally name your change set. Enter a descriptive name for the changes.

<figure><img src="https://688288018-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F1flQ2To8tQpCQWl2Ty9U%2Fuploads%2Fh6LRlAofjz5aNLOl6IJM%2Fimage.png?alt=media&#x26;token=25b27747-2760-45fd-998f-7b6ec17d9b81" alt="" width="510"><figcaption><p>The interface reviewing the specific rows selected for a migration.</p></figcaption></figure>

6. Click *Migrate Change Set* on the toolbar along the bottom right. This will take you back to the *Migrate* page.
7. On the *Migrate* page, reselect the source system and integration. Then select the *Change Set Migration* mod&#x65;*,* select the changeset you created in step 5, then click *Migrate Change Set.*

<figure><img src="https://688288018-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F1flQ2To8tQpCQWl2Ty9U%2Fuploads%2FiijTMEzNoKpBcsgOMYe4%2FScreenshot%202024-10-09%20at%203.55.22%E2%80%AFPM.png?alt=media&#x26;token=7b8122ca-3fd1-40c7-ba82-a18507e99d25" alt=""><figcaption><p>Selecting a change set to migrate</p></figcaption></figure>

8. Verify that the correct changes were migrated by reviewing the migration summary.
