4 Replies Latest reply on Jun 12, 2006 4:05 AM by Ronald van Kuijk

    SubProcess Logging

    David Hosier Novice

      I'm trying to work with the jBPM logging to provide process details for a customer. I know begging is frowned upon, but I really really need some enlightenment here. I want to get the full trace of the process from the LoggingSession. However, when I get the logs for the main super process, I can see no indication that a sub process was created. The sub process executed, and its logs are in the database, but I have no idea how to actually get at them. I can see a TransitionLog where it goes to my Process State, but then the next thing I see basically is the signal leaving the Process State and going to the next node in the process.

      I tried to test the destination node in the TransitionLog to see if it is an instanceof a ProcessState, but it's not, it's some CGLIB thing (org.jbpm.graph.def.Node$$EnhancerByCGLIB$$46898e07). The only other solution I can think of is to set a process variable in the super process from the sub process that holds that sub process' ID and then key off of the Variableinstance.StringUpdateLog to grab the ID and go get the process' logs. *sigh* I really don't want to do that, and I have to think there is a way to do what I want...but alas, the solution eludes me. Thanks for any help that anyone can offer.

      This is in jBPM 3.1.1. by the way.

      -David

        • 1. Re: SubProcess Logging
          David Hosier Novice

          I just stumbled across the fact that you can call JbpmContext.save(Token). Is this what I need to do in order for a given logging trace for a Token to contain details about sub process creation? I don't have time to try it right now, but it would be nice if I could find this out from someone in the know, instead of wasting my time later today. Thanks.

          • 2. Re: SubProcess Logging
            Koen Aers Master

            David,

            I don't think JbpmContext.save(Token) will help you. I had a brief look at your problem and I did indeed not find an easy way to have this information logged. But maybe I am overlooking something. I will talk to Tom about it in case he doesn't see this post.

            Cheers,
            Koen

            • 3. Re: SubProcess Logging
              Koen Aers Master

              David,

              Tom just told me that he answered your post but apparently he pressed on the wrong button. I always believe Tom when he says something, but this time I have even more reason to believe him because I saw he entered this JIRA issue related to this.
              In fact his response was mostly a confirmation that it is indeed not supported out of the box. It will be supported in the jBPM 3.2 branch because it needs a database modification. The way to work around this is the way you figured out already.

              Regards,
              Koen

              • 4. Re: SubProcess Logging
                Ronald van Kuijk Master

                I've had the same problem, thinking I answerd some post but days later saw I didn't. Could be something is wrong with the forums