It's okay everyone, I figured it out :). I used environment="MY_VAR_NAME=$(Process)" in the submit fileand System.getenv("MY_VAR_NAME") in Java. Simple..On 12 December 2013 08:39, Oliver Coleman <oliver.coleman@xxxxxxxxx> wrote:
I'm using htcondor 7.0, I submit up to 100 Java jobs in the same cluster at once, and I need to know the process number in the Java code. What's the best way of doing this?
So far all I can think of is transferring a file with the process number in the name and getting the code to find and parse the number out of this file name, but this seems like quite a kludge. Maybe it's available in an environment variable?
I want the process number so that a random number generator can be initialised with the same seed if it has the same process number across clusters of jobs.