REST Resource: projects.locations.workflows

Resource: MigrationWorkflow

A migration workflow which specifies what needs to be done for an EDW migration.

JSON representation
{
  "name": string,
  "displayName": string,
  "tasks": {
    string: {
      object (MigrationTask)
    },
    ...
  },
  "state": enum (State),
  "createTime": string,
  "lastUpdateTime": string
}
Fields
name

string

Output only. Immutable. The unique identifier for the migration workflow. The ID is server-generated.

Example: projects/123/locations/us/workflows/345

displayName

string

The display name of the workflow. This can be set to give a workflow a descriptive name. There is no guarantee or enforcement of uniqueness.

tasks

map (key: string, value: object (MigrationTask))

The tasks in a workflow in a named map. The name (i.e. key) has no meaning and is merely a convenient way to address a specific task in a workflow.

state

enum (State)

Output only. That status of the workflow.

createTime

string (Timestamp format)

Time when the workflow was created.

lastUpdateTime

string (Timestamp format)

Time when the workflow was last updated.

MigrationTask

A single task for a migration which has details about the configuration of the task.

JSON representation
{
  "id": string,
  "type": string,
  "state": enum (State),
  "processingError": {
    object (ErrorInfo)
  },
  "createTime": string,
  "lastUpdateTime": string,
  "translationConfigDetails": {
    object (TranslationConfigDetails)
  }
}
Fields
id

string

Output only. Immutable. The unique identifier for the migration task. The ID is server-generated.

type

string

The type of the task. This must be one of the supported task types: Translation_Teradata2BQ, Translation_Redshift2BQ, Translation_Bteq2BQ, Translation_Oracle2BQ, Translation_HiveQL2BQ, Translation_SparkSQL2BQ, Translation_Snowflake2BQ, Translation_Netezza2BQ, Translation_AzureSynapse2BQ, Translation_Vertica2BQ, Translation_SQLServer2BQ.

state

enum (State)

Output only. The current state of the task.

processingError

object (ErrorInfo)

Output only. An explanation that may be populated when the task is in FAILED state.

createTime

string (Timestamp format)

Time when the task was created.

lastUpdateTime

string (Timestamp format)

Time when the task was last updated.

translationConfigDetails

object (TranslationConfigDetails)

Task configuration for CW Batch/Offline SQL Translation.

TranslationConfigDetails

The translation config to capture necessary settings for a translation task and subtask.

JSON representation
{
  "sourceDialect": {
    object (Dialect)
  },
  "targetDialect": {
    object (Dialect)
  },
  "sourceEnv": {
    object (SourceEnv)
  },
  "gcsSourcePath": string,
  "gcsTargetPath": string,
  "nameMappingList": {
    object (ObjectNameMappingList)
  }
}
Fields
sourceDialect

object (Dialect)

The dialect of the input files.

targetDialect

object (Dialect)

The target dialect for the engine to translate the input to.

sourceEnv

object (SourceEnv)

The default source environment values for the translation.

gcsSourcePath

string

The Cloud Storage path for a directory of files to translate in a task.

gcsTargetPath

string

The Cloud Storage path to write back the corresponding input files to.

nameMappingList

object (ObjectNameMappingList)

The mapping of objects to their desired output names in list form.

ObjectNameMappingList

Represents a map of name mappings using a list of key:value proto messages of existing name to desired output name.

JSON representation
{
  "nameMap": [
    {
      object (ObjectNameMapping)
    }
  ]
}
Fields
nameMap[]

object (ObjectNameMapping)

The elements of the object name map.

ObjectNameMapping

Represents a key-value pair of NameMappingKey to NameMappingValue to represent the mapping of SQL names from the input value to desired output.

JSON representation
{
  "source": {
    object (NameMappingKey)
  },
  "target": {
    object (NameMappingValue)
  }
}
Fields
source

object (NameMappingKey)

The name of the object in source that is being mapped.

target

object (NameMappingValue)

The desired target name of the object that is being mapped.

NameMappingKey

The potential components of a full name mapping that will be mapped during translation in the source data warehouse.

JSON representation
{
  "type": enum (Type),
  "database": string,
  "schema": string,
  "relation": string,
  "attribute": string
}
Fields
type

enum (Type)

The type of object that is being mapped.

database

string

The database name (BigQuery project ID equivalent in the source data warehouse).

schema

string

The schema name (BigQuery dataset equivalent in the source data warehouse).

relation

string

The relation name (BigQuery table or view equivalent in the source data warehouse).

attribute

string

The attribute name (BigQuery column equivalent in the source data warehouse).

Type

The type of the object that is being mapped.

Enums
TYPE_UNSPECIFIED Unspecified name mapping type.
DATABASE The object being mapped is a database.
SCHEMA The object being mapped is a schema.
RELATION The object being mapped is a relation.
ATTRIBUTE The object being mapped is an attribute.
RELATION_ALIAS The object being mapped is a relation alias.
ATTRIBUTE_ALIAS The object being mapped is a an attribute alias.
FUNCTION The object being mapped is a function.

NameMappingValue

The potential components of a full name mapping that will be mapped during translation in the target data warehouse.

JSON representation
{
  "database": string,
  "schema": string,
  "relation": string,
  "attribute": string
}
Fields
database

string

The database name (BigQuery project ID equivalent in the target data warehouse).

schema

string

The schema name (BigQuery dataset equivalent in the target data warehouse).

relation

string

The relation name (BigQuery table or view equivalent in the target data warehouse).

attribute

string

The attribute name (BigQuery column equivalent in the target data warehouse).

Dialect

The possible dialect options for translation.

JSON representation
{

  // Union field dialect_value can be only one of the following:
  "bigqueryDialect": {
    object (BigQueryDialect)
  },
  "hiveqlDialect": {
    object (HiveQLDialect)
  },
  "redshiftDialect": {
    object (RedshiftDialect)
  },
  "teradataDialect": {
    object (TeradataDialect)
  },
  "oracleDialect": {
    object (OracleDialect)
  },
  "sparksqlDialect": {
    object (SparkSQLDialect)
  },
  "snowflakeDialect": {
    object (SnowflakeDialect)
  },
  "netezzaDialect": {
    object (NetezzaDialect)
  },
  "azureSynapseDialect": {
    object (AzureSynapseDialect)
  },
  "verticaDialect": {
    object (VerticaDialect)
  },
  "sqlServerDialect": {
    object (SQLServerDialect)
    },
  "prestoDialect": {
    object (PrestoDialect)
  }
  // End of list of possible types for union field dialect_value.
}
Fields
Union field dialect_value. The possible dialect options that this message represents. dialect_value can be only one of the following:
bigqueryDialect

object (BigQueryDialect)

The BigQuery dialect

hiveqlDialect

object (HiveQLDialect)

The HiveQL dialect

redshiftDialect

object (RedshiftDialect)

The Redshift dialect

teradataDialect

object (TeradataDialect)

The Teradata dialect

oracleDialect

object (OracleDialect)

The Oracle dialect

sparksqlDialect

object (SparkSQLDialect)

The SparkSQL dialect

snowflakeDialect

object (SnowflakeDialect)

The Snowflake dialect

netezzaDialect

object (NetezzaDialect)

The Netezza dialect

azureSynapseDialect

object (AzureSynapseDialect)

The Azure Synapse dialect

verticaDialect

object (VerticaDialect)

The Vertica dialect

sqlServerDialect

object (SQLServerDialect)

The SQL Server dialect

prestoDialect

object (PrestoDialect)

The Presto dialect

BigQueryDialect

The dialect definition for BigQuery.

HiveQLDialect

The dialect definition for HiveQL.

RedshiftDialect

The dialect definition for Redshift.

TeradataDialect

The dialect definition for Teradata.

JSON representation
{
  "mode": enum (Mode)
}
Fields
mode

enum (Mode)

Which Teradata sub-dialect mode the user specifies.

Mode

The sub-dialect options for Teradata.

Enums
MODE_UNSPECIFIED Unspecified mode.
SQL Teradata SQL mode.
BTEQ BTEQ mode (which includes SQL).

OracleDialect

The dialect definition for Oracle.

SparkSQLDialect

The dialect definition for SparkSQL.

SnowflakeDialect

The dialect definition for Snowflake.

NetezzaDialect

The dialect definition for Netezza.

AzureSynapseDialect

The dialect definition for Azure Synapse.

VerticaDialect

The dialect definition for Vertica.

SQLServerDialect

The dialect definition for SQL Server.

PrestoDialect

The dialect definition for Presto.

SourceEnv

Represents the default source environment values for the translation.

JSON representation
{
  "defaultDatabase": string,
  "schemaSearchPath": [
    string
  ]
}
Fields
defaultDatabase

string

The default database name to fully qualify SQL objects when their database name is missing.

schemaSearchPath[]

string

The schema search path. When SQL objects are missing schema name, translation engine will search through this list to find the value.

State

Possible states of a migration task.

Enums
STATE_UNSPECIFIED The state is unspecified.
PENDING The task is waiting for orchestration.
ORCHESTRATING The task is assigned to an orchestrator.
RUNNING The task is running, i.e. its subtasks are ready for execution.
PAUSED Tha task is paused. Assigned subtasks can continue, but no new subtasks will be scheduled.
SUCCEEDED The task finished successfully.
FAILED The task finished unsuccessfully.

State

Possible migration workflow states.

Enums
STATE_UNSPECIFIED Workflow state is unspecified.
DRAFT Workflow is in draft status, i.e. tasks are not yet eligible for execution.
RUNNING Workflow is running (i.e. tasks are eligible for execution).
PAUSED Workflow is paused. Tasks currently in progress may continue, but no further tasks will be scheduled.
COMPLETED Workflow is complete. There should not be any task in a non-terminal state, but if they are (e.g. forced termination), they will not be scheduled.

Methods

create

Creates a migration workflow.

delete

Deletes a migration workflow by name.

get

Gets a previously created migration workflow.

list

Lists previously created migration workflow.

start

Starts a previously created migration workflow.