Page tree

Versions Compared

Key

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

...

ParameterDescriptionApplicable CLI Commands
command_type
The type of CLI command to execute. Accepted values:

  • run_job - Execute a specified job on the specified running environment.
  • get_job_status - Get job status information.
  • get_publications - Acquire publication information for a specified job.
  • publish - Publish a completed job to the specified database table, which has not been created yet. If the table exists, the data is appended to the existing table.

  • load_data  - Load data into the database table. If the table exists, to which a schema has already been applied. Use to append to existing tablethe data is appended to the existing table. If the table does not exist, the job fails.
  • truncate_and_load - Overwrite data in specified table.

See Examples below.

For more information on the following commands, see CLI for Connections.

  • create_connection - Create a new connection object.
  • edit_connection - Edit an existing connection object.
  • list_connections - List all connection objects for the specified user.
  • delete_connection - Delete a connection object.
All
user_name

(Required) 

D s item
username
username
of the user to execute the job. Please specify the full username.

Info

NOTE: In the response, this value is listed as  user .

All
password

D s item
password
password
for the username
If no password is specified, you are prompted to enter one.

Info

NOTE: If you have enabled Kerberos-based access to the

D s platform
, you do not need to provide a password. To enable, additional configuration is required. See Set up for a Kerberos-enabled Hadoop cluster.

Info

NOTE: You can store username and password information in an external file so that they don't need to be included in each command. For more information, see CLI Config File.

All
cli_output_path

Defines the client-side path where the JSON output is stored for all commands. Default value iscli_results.out

Info

NOTE: The user issuing the command must also have execute permissions on all parent folders in the specified cli_output_path.

All
disable_ssl_certification

(Optional) When communicating over HTTPS, this setting can be used to override the default behavior of validating the server certificate before executing the command.

Info

NOTE: If you have stored a self-signed certificate on the

D s item
itemnode
, please set the REQUESTS_CA_BUNDLE environment variable to point to the directory that contains the trusted server's certificate(s). The CLI will verify against these certs. In this case, the disable_ssl_certificate parameter is not needed.

All commands
conn_ssl

(Optional) Connect to the datastore over SSL.

Info

NOTE: You must modify the host parameter value to include the appropriate port number for the SSL connection.

Info

NOTE: SSL connections are not supported for Hive, Redshift, or SQL Server.


All commands 

...

You execute one publish command for each output you wish to write to a supported database table. A new database table is created every run.

Command

Example (All one command):

Code Block
./trifacta_cli.py publish --user_name <trifacta_user> --password <trifacta_password> --job_id 42 
--database dev --table table_job_42 --conn_name 1 --publish_format avro 
--cli_output_path ./publish_info.out

 

Output

Code Block
PublishCreate new table every run has been successfully launched:
You may monitor the progress of your publish job here: http://localhost:3005/jobs
Upon success, you may view the results of your publish job here: http://localhost:3005/jobs/42

...

You can load data into pre-existing Redshift tables.

  • Data is appended after any existing rows.
  • If the table does not exist, the job fails.

Info

NOTE: When appending data into a Redshift table, the columns displayed in the Transformer page must match the order and data type of the columns in the target table.

...

Code Block
./trifacta_cli.py load_data --user_name <trifacta_user> --password <trifacta_password> --job_id 42 
--database dev --table table_42 --conn_name aSQLServerConnection --publish_format avro 
--cli_output_path ./load_info.out

Output

Code Block
Load data/AppendAppend to this table every run has been successfully launched:
You may monitor the progress of your publish job here: http://localhost:3005/jobs
Upon success, you may view the results of your Load data/Append job here: http://localhost:3005/jobs/42

...

Truncate and load

For existing Hive tables, you can clear them and load them with results from a job. You cannot truncate and load into Redshift tables.

Command

Example (All one command):

...