Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

  • Ephemeral database feature works ONLY for PDB databases

  • Ephemeral database feature works ONLY for Oracle 19c and 21c

  • Ephemeral database feature does not work for Oracle RDS

  • You cannot place the temporary copied database in a pipeline or run a status on it because technically it does not exist in the pipeline.

Usage

<graphics and info regarding:

During packager operation it will create a pluggable PDB copy, package all the changes on it and drop the PDB copy after it, if final deploy is not skipped - it will deploy newly packaged changes on desired db def (which is DEV in most of the examples)>

Backup and Restore Package Methods

...

BackupRestoreOracleEphemeralExternalPdb

BackupRestoreOracleEphemeralExternalPdb differs from BackupRestoreOracleEphemeralInternalPdb, that it makes a copy between two different DB instances, so in all info below we are going to have database A and B, so we would like to make an ephemeral copy of the A’s database PDB to database B. To be able to use BackupRestoreOracleEphemeralExternalPdb as databaseBackupRestoreMethod our customer would need to prepare an additional set up for us.

Create ORCLCDB SYSOPER User

...

Code Block
SELECT * FROM dual@liquibase_db_link;

Info

If you would like to use another name for database link - please use oracleEphemeralDatabaseLinkName packager property.

Associated deployPackager.properties

...

Property Name

Description

oracleEphemeralSourceName

[Optional]

  1. defines a name for an Oracle source PDB

  2. if not provided we will try to get it ourselves from a DB

  3. validation - it should up to 30 characters long, contain no spaces [ ], slashes [/] and semicolons [;], also it can’t start from a number

oracleEphemeralCopyName

[Optional]

  1. defines a name for an Oracle copy PDB

  2. if not provided we will try to get a source PDB name from a DB and add _eph postfix to it, so if original bucket name was bucket_01, copied bucket name will be bucket_01_eph

  3. validation - it should up to 30 characters long, contain no spaces [ ], slashes [/] and semicolons [;], also it can’t start from a number

oracleEphemeralDatabaseLinkName

[Optional]

  1. defines a name for a database link which is used in BackupRestoreOracleEphemeralExternalPdb

  2. if not provided a default name is used which is liquibase_db_link

  3. validation - it should up to 128 characters long, contain no spaces [ ], slashes [/] and semicolons [;], also it can’t start from a number

oracleEphemeralCopyWithData

[Optional] By default we do not copy databases with data. If you would like to copy both the structure and data, you will use this property.

  1. a boolean flag to turn on making a copy with data

  2. by default it is false and we make a copy of the PDB without data (in other words we copy tables, but do not copy their content, the only table for which we copy content is our tracking DATABASECHANGELOG table)

oracleEphemeralSkipFinalDeploy

[Optional] This property allows you to:

  • package

  • run SQL rules

  • create the ephemeral database copy

  • package changes onto the ephemeral database

  • drop the ephemeral database

  • And then SKIP the final deploy of the ephemeral database changes to the dev database.

  • a boolean flag to turn off final deploy during packager to be able to skip final deployment after packaging, so our customer can package files and skip deployment to any DB

  • by default is false and we make a final deploy, which is a default packager behaviour

See: Use the Required deployPackager.properties File

...

  1. If the password is present in the file, please note this value is Base64 encoded. If modifying this value, the new value will also need to be Base64 encoded.

  2. Clear out the dbDefsId for the new _EPHEMERAL dbDef.

  3. Do a Test Connection to the DMC Database (under Settings → Configure DMC DB → Test Connection) or perform a Status operation on the project in order to populate the dbDefsId for the new ephemeral dbDef.

    image-20240311-171728.png

Info
  • Important note: If source dbDef does NOT use TNS, then ..._EPHEMERAL dbDef should also NOT use TNS, because when we create PDB copy in another DB we need to get host and port to connect to it and if ..._EPHEMERAL uses TNS, then we don’t know where to connect to. If source dbDef uses TNS, then ..._EPHEMERAL dbDef can use anything, as customer anyway need to create TNS entry with _eph postfix to be able to connect to it.

Using TNSNAMES/LDAP with Oracle Ephemeral Database

...