Scheduled Job

Steps

  1. Create a project job_console_project
  2. Then create a JavaScript service named my_job_handler.js
  3. Replace the service code with the following content:

Log Levels

1
2
3
console.log("Hello from the My Job!");

  1. Then create a job descriptor file my_job.job
  2. Replace the content with the following JSON code:
1
2
3
4
5
6
7

{
	"expression":"0/10 * * * * ?",
	"handler":"job_console_project/my_job_handler.js",
	"description":"My Job"
}

  1. Publish the project
  2. After 10s in the Console view you should see the following lines:

    [2018-05-14T12:05:00.061Z] [INFO] Hello from the My Job!

Note: the log messages in the Console view are in a reverse order - the newest are on top


For more information, see the API documentation.

Edit