1 Reply Latest reply on Jul 25, 2011 6:35 PM by doctorwho

    Adding custom classes to script tasks

    doctorwho Newbie



      I have a workflow that uses script tasks to execute a custom class. I am using Guvnor to deploy to the console for execution. However, if the code for the task is defined as:




      Guvnor complains that it cannot find the variable com...

      so I tried moving the class into the defaultPacakage, out of com.jpl.scripts, which resulted in Guvnor not able to find the variable ScriptExecute. Next I tried to add kcontext on the front:




      which will get it past Guvnor, but then upon execution there are errors. The original runs just fine under ecplise.


      How is this done? I need to use custom classes with script tasks, and it would be nice to use packages that I define.

        • 1. Re: Adding custom classes to script tasks
          doctorwho Newbie

          Nevermind, I have solved it.


          It would seem that the best way to accomplish what I wanted was to create a custom work definition, with a custom handler that provided the services that I needed. It was simple enough to pass the required variables, and get a return value.


          I wish there was more documentation for correctly getting a return value, however the examples helped.