2
votes

from a JavaServerAddin I trigger an agent that invokes another program on a domino server. The program takes a little time to run. Normally, the addin schedule does not interfere with the program. I would like to check from my JavaAddin if the program is still running and avoid invoking the agent when the result of the check returns true.

Anyone any idea, how to do this?

I've tried this (http://www.rgagnon.com/javadetails/java-0593.html) and other samples, but it only returns tasks that are running on the server but not inside Domino

1
Have the Java app write to a file and check the file for the status of the previous running app.Simon O'Doherty
please, add more details: your addin code invokes agent (how? agent.run? aget.runOnServer? console command?) and that agent (Java, LotusScript) invokes another program (how?)Frantisek Kossuth
how are you executing the external program? like here? rgagnon.com/javadetails/java-0014.htmljjtbsomhorst
The qotools program ( quickr 8.5.1) is triggered using NSFRemoteConsole(server, cmd, hBuf) from LotusScript.Ulrich Krause

1 Answers

4
votes

Did you consider to issue a SHOW TASKS to the console. With -XML you get something that is easy to parse.

  Session s = ...;
  String result = s.sendConsoleCommand("yourserver","SHOW TASKS -XML");

Hope that helps