Import Scheduled Jobs

   Journey Manager (JM) The transaction engine for the platform.  |    System Manager / DevOps  |  24.04This feature was updated in 24.04

Manager allows you to import scheduled jobs, which were previously exported.

Note

You can only import scheduled jobs, which execute services of the Scheduled Service Job type. You can't import scheduled jobs, which execute Core Services.

Use this functionality to:

  • Roll back one or scheduled jobs.
  • Re-create one or scheduled jobs in another Manager.
  • Promote scheduled jobs to another environment.

You can import a scheduled job using one of following options:

Import Using UI

To import a scheduled job:

  1. Select System > Scheduled Jobs.
  2. Click Import Job.
  3. Click Choose File and choose a scheduled job archive ZIP file.
  4. Click Proceed To import.
  5. Review the Import Action as shown below:
    Note

    There are no import options to select, so every import will override the existing scheduled job.

  6. Click Import to complete the process.
  7. Click Close and check the list of services to verify the imported services have been added.
  8. Note

    You can check the Audit Log and Error Log for successful and failed import operations respectively, whilst the Import Log shows all import operations.

Import Using SDK

The Journey Manager SDK Maven plugin provides the tm-sdk:archive-deploy goal to import a scheduled job. For example, set archive.file=my-scheduled-job.zip in the build.properties file and run mvn initialize tm-sdk:archive-deploy to import a scheduled job.

Import Using API

The Journey Manager REST API provides the endpoint URL to import a scheduled job.

To call this REST API, you need:

HTTP Request
Both HTTP and HTTPS protocols are supported:
http(s)://<JM_SERVER>/manager/secure/rest/archive/v1/
Parameters
--header ‘Authorization: Basic <USE-NAME-AND-PASSWORD-BASE64-ENCODED>’ - an HTTP header containing 'username:password' encoded as Base64Base64 is a binary to a text encoding scheme that represents binary data in an American Standard Code for Information Interchange (ASCII) string format..
--form ‘archiveFile=@“/Users/my-scheduled-job.zip”’ - a path to an archive file to be imported.
Response
If successful, this operation returns the following response with a HTTP 200 OK status code.
Example
curl --location --request PUT ‘https://<JM_SERVER>/manager/secure/rest/archive/v1/’ \
--header ‘Authorization: Basic <USE-NAME-AND-PASSWORD-BASE64-ENCODED>’ \
--form ‘archiveFile=@“/Users/my-scheduled-job.zip”’ 

Note

You can also update an existing scheduled job using the Configuration Service API.

Next, learn how to view scheduled job history.