Versions Compared

Key

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

Looking for the documentation on the newest versions of SIL Engine and the Simple Issue Language for Jira 8 for Server/Data Center? Click here !


Info
titleAvailability

This routine is available since starting with Power Scripts Scripts™ for JIRA (formerly known as JJUPIN) 3Jira 3.0.8.

This routine is available for Jira server and cloud deployment options.

Syntax

...

runJobInAndRepeat(silFile, args, intervalinterval [, user])

Description

...

Excerpt
Runs a job every specified interval.

Parameters

...

Parameter name

Type

Required

Description

silFile

scriptPath

string

Yes

The

sil file name

source of the script to be executed.

args

array string

Yes

The list of the arguments of the job.
interval

int

Yes

The interval

userstringNo

The user which will be used to run the script.

Info
titleAvailability

This param is available starting with version 4.8.0.10 of Power Scripts .


Return type

...

none

The returned value has no meaning.

Example

...

Code Block
string[] args = {key, project};
interval varInterval = "30m";
runJobInAndRepeat("script.sil", args, varInterval);

The example above will create creates a job that will run runs the script "script.sil" every 30 minutes. (the The job running will repeat every 30 minutes.


For the scriptPath parameter you can either give the relative path (as in the example above), or the absolute path: 
C:/Program Files/Atlassian/Application Data/JIRA/silprograms/script.sil.


In "script.sil" you can access the args using the next syntax:

Code Block
string issueKey = argv[0];

 

See Also:

...


Warning
titleNo user provided

This routine doesn't assume any user when executed because of the nature of this action(the execution of the script can be scheduled at any point in time and that cannot guarantee the user is authenticated). Therefore, the script will NOT have the required permissions to interact with Jira tickets, unless the project allows for anonymous access or the script explicitly calls out the user to use within in the script using the runAs routine.

It is highly recommended to provide a user to the scheduled job when interacting with Jira tickets.

Starting with version 4.8.0.10 of Power Scripts an optional param will be available that will give the possibility to assume an user when executing the script.

See also

Filter by label (Content by label)
showLabelsfalse
showSpacefalse
cqllabel = "scheduler_routines"
labelsscheduler_routines