Uploaded image for project: 'JS - JobScheduler'
  1. JS - JobScheduler
  2. JS-1470

It should be possible to call the method .start in the job object without the optional parameter variable_set

    XMLWordPrintable

Details

    • Fix
    • Status: Released (View Workflow)
    • Minor
    • Resolution: Fixed
    • 1.7
    • 1.8.4, 1.9.6, 1.10
    • None
    • None

    Description

      Description
      The API method .start that is available in the job object has the option parameter variable_set. When calling the method without the parameter, an error occurs.

      Z-JAVA-105  Java exception java.lang.RuntimeException: COM-80020009  Ausnahmefehler aufgetreten. [] [Ivariable_set is not a Com_variable_set (Calling Spooler.Job::start)], method=spooler_process()Z []
      

      Therefore the JITL-Job check_blacklist does not work any more when it is parameterized with the parameter job

      Desired behaviour
      The parameter variable_set in the method .start for an object job should be optional as documented.

      Reproduce
      To reproduce the error start this job. The job needs a job named job1 in the live folder.

      <job  name="job5">
          <script  language="java:javascript">
              <![CDATA[
      function spooler_process(){
          var j = spooler.job("job1");
          j.start();
      	return false;
      }
              ]]>
          </script>
      
          <run_time />
      </job>
      

      Workaround
      When the .start method is used (e.g. in customers scripts) create an empty variable_set and add the parameter to the call

      Example:

      
      
      
      <job  name="job5">
          <script  language="java:javascript">
              <![CDATA[
      function spooler_process(){
          var j = spooler.job("job1");
          var parameters = spooler.create_variable_set();
          j.start(parameters);
      	return false;
      }
              ]]>
          </script>
      
          <run_time />
      </job>
      
      

      Workaround for the job check_blacklist

      Use a job chain instead of a stand alone job and remove the parameter job. Put the job into the job chain

      Attachments

        Issue Links

          Activity

            People

              jz Joacim Zschimmer
              ur Uwe Risse
              Santiago Aucejo Petzoldt Santiago Aucejo Petzoldt
              Votes:
              0 Vote for this issue
              Watchers:
              2 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved: