Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.
Comment: 'FAQ by Topic' links modified

Table of Contents
outlinh1. true
outlinh1. true
1printablefalse
2stylh1. none
3indent20px

You want to save a job in the live folder. The job should start immediately and when execution has finished, the file with the job should be deleted.

You can achive achieve this by using the run time attribute "once=yes" and with a postprocessing post-processing script that will delete the file after execution.

Code Block

 <?xml version="1.0" encoding="ISO-8859-1"?> 
 
 
 <job  stop_on_error="no">
     <script  language="shell">
         <![CDATA[
 echo hello world
         ]]>
     </script>
 
     <monitor  name="remove" ordering="0">
         <script  language="javax.script:rhino">
             <![CDATA[
 function spooler_task_after()\{ 
    spooler_job.remove(); 
 \}
             ]]>
         </script>
     </monitor>
 
     <run_time  once="yes"/>
 </job>

see also: