Uploaded image for project: 'jBPM'
  1. jBPM
  2. JBPM-2977

NPE in HistoryActivityInstanceImpl ctor when Activity is null

    XMLWordPrintable

Details

    • Bug
    • Resolution: Unresolved
    • Major
    • jBPM 4.x
    • jBPM 4.4
    • Runtime Engine

    Description

      In 4.4, automatic history recording was added for custom activities (JBPM-2495). In order to work around (JBPM-2976), we had to create a custom activity that was basically the ForkActivity with slight modification. In the jbpm implementation of the ForkActivity (on which ours was based), it sets the Activity of the root execution to null before launching child executions. When the process engine later executes the history code, the constructor for HistoryActivityInstanceImpl fails with an NPE because the activity is null.

      Our workaround is to comment out the line in our Fork implementation that sets the Activity to null. Not sure if this has any side effects, but we haven't seen any so far.

      Now granted, it is a rather odd case to have a custom activity setting the activity to null. But nonetheless, it seems that a generic history mechanism should handle this case gracefully, rather than just throwing an NPE.

      Our

      Attachments

        Activity

          People

            Unassigned Unassigned
            gubespam Mike M (Inactive)
            Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

            Dates

              Created:
              Updated: