Oracle Query Post-run Action

Runs an Oracle query at the end of the pipeline run. Can be configured to run only on success, only on failure, or always at the end of the run.

For example, you might have a pipeline that imports data from a database table to HDFS files. At the end of the run, you might want to run a query that deletes the data that was read from the table.

Configuration

Property

Macro Enabled?

Version Introduced

Description

Property

Macro Enabled?

Version Introduced

Description

Run Condition

Yes

 

Optional. When to run the action. Must be 'completion', 'success', or 'failure'. Defaults to 'success'. If set to 'completion', the action will be executed regardless of whether the pipeline run succeeded or failed. If set to 'success', the action will only be executed if the pipeline run succeeded. If set to 'failure', the action will only be executed if the pipeline run failed.

Default is success.

Driver Name

No

 

Required. Name of the JDBC driver to use.

Default is oracle.

Host

Yes

 

Required. Host that Oracle is running on.

Default is localhost.

Port

Yes

 

Required. Port that Oracle is running on.

Default is 1521.

Connection Type

No

 

Required. Whether to use an SID, Service Name, or TNS Connect Descriptor when connecting to the database.

SID/Service Name/TNS Connect Descriptor

Yes

 

Required. Oracle connection point (Database name, Service name, or a TNS Connect Descriptor). When using TNS, place the full TNS Connect Descriptor in the text field. For example: (DESCRIPTION =(ADDRESS = (PROTOCOL = TCP)(HOST = 123.123.123.123)(PORT = 1521))(CONNECT_DATA =(SERVER = DEDICATED) (SERVICE_NAME = XE)))

Query

Yes

 

Required. Query to run.

Username

Yes

 

Optional. User identity for connecting to the specified database.

Password

Yes

 

Optional. Password to use to connect to the specified database.

Connection Arguments

Yes

 

Optional. A list of arbitrary string key/value pairs as connection arguments. These arguments will be passed to the JDBC driver as connection arguments for JDBC drivers that may need additional configurations.

Default Batch Value

No

 

Optional. The default batch value that triggers an execution request.

Default is 10.

Example

You want to delete all records from Oracle table "userEvents" of database "XE" running on localhost, port 3306, without authentication using driver "oracle" if the pipeline completes successfully. Ensure that the driver for Oracle is installed. You can also driver name for some specific driver, otherwise "oracle" will be used , and then configure the plugin with:

Property

Value

Property

Value

Run Condition

success

Driver Name

oracle

Host

localhost

Port

1251

SID/Service Name

XE

Query

delete * from userEvents

Username

system

Password

oracle

Default Batch Value

10