Issue on the programmatic usage of Subprocess Operator

User: "jaysonpryde"
New Altair Community Member
Updated by Jocelyn
Hi,

    I am currently coding, in Java, a module that utilizes a rapid miner process I've created. The said process contains a Subprocess operator, which in turn, contains operators whose parameters are to be set in the code (i.e filename, csv file, etc).

    I was able to that using the below code:

   

        Process process = new Process(new File(filename of the rapidminer process));
        ...
        ...
        OperatorChain oc = (OperatorChain)process.getOperator(label of the subprocess);
oc.getSubprocess(0).getOperatorByName("Log").setParameter("filename", log filename);
        ...
        ...
        process.run()
   
    The code is OK and the module is working perfectly. Only, it HANGS and it never terminates.
    Based on my testing and observation, I am quite sure that this is caused by the usage of the Subprocess operator
    because when tried and moved out the operators inside the subprocess and just connect it in the main process,
    the module is no longer hanging (both during debug and running as a JAR)

Any ideas on this? Thank you!

 

Find more posts tagged with