Back to Flyway

Redgate Clone Resolver

documentation/Reference/Configuration/Environments Namespace/Environment Resolvers Namespace/Redgate Clone Resolver.md

latest4.4 KB
Original Source
  • Status: Preview

{% include enterprise.html %}

{% include deprecation.html %}

Note: Redgate Clone has been removed from Flyway Desktop and is deprecated in Flyway Engine. This feature will be removed in a future version.

This property resolver allows for connecting to databases generated using Redgate Clone. This is usually used as a provisioner, as detailed [here](Configuration/Environments Namespace/Environment Provisioner Setting/Redgate Clone Provisioner).

Prerequisites:

  • A Redgate Clone server needs to be set up
  • The image used for generating the clone needs to already exist on the clone server
  • (When not setting the provisioner setting) The data container to connect to needs to have already been created

To use this, configure the relevant settings and set the value of the environment JDBC URL parameter to ${clone.url}. This will derive the JDBC URL from Redgate Clone. Note that currently for SQL Server the database name needs to be set explicitly after this within the URL parameter as shown in the example below (the JDBC URL returned by Redgate Clone always ends with a ; so additional properties can be appended)

Settings

SettingRequiredTypeDescription
urlYesStringThe Redgate Clone server URL.
dataImageYesStringThe data image to use for creating the container.
dataContainerYesStringThe data container to use for the database clone.
dataContainerLifetimeYesStringThe lifetime of the data container.
authenticationTokenYesStringThe token required for authenticating with the Redgate Clone Server.
operationTimeoutNoStringThe amount of time to wait for Redgate Clone operations to complete.

Usage

Command-line

bash
./flyway info \
-environment='development' \
-environments.development.url='${clone.url}databaseName=my-database' \
-environments.development.resolvers.clone.url='https://clone.red-gate.com:1234/cloning-api' \
-environments.development.resolvers.clone.dataImage='mssql-empty' \
-environments.development.resolvers.clone.dataContainer='MyContainer' \
-environments.development.resolvers.clone.dataContainerLifetime='1h' \
-environments.development.resolvers.clone.authenticationToken='${localSecret.RedgateCloneToken}'

TOML Configuration File

toml
[environments.development]
url = "${clone.url}databaseName=my-database"

[environments.development.resolvers.clone]
url = "https://clone.red-gate.com:1234/cloning-api"
dataImage = "mssql-empty"
dataContainer = "MyContainer"
dataContainerLifetime = "1h"
authenticationToken = "${localSecret.RedgateCloneToken}"