Bug 779321 (SOA-1709) - NullPointerException in jbpm-console when viewing running process
Summary: NullPointerException in jbpm-console when viewing running process
Keywords:
Status: CLOSED NEXTRELEASE
Alias: SOA-1709
Product: JBoss Enterprise SOA Platform 5
Classification: JBoss
Component: Documentation, JBPM - within SOA, Monitoring and Management, JBPM - standalone
Version: 5.0.2,5.0.0 ER5
Hardware: Unspecified
OS: Unspecified
high
high
Target Milestone: ---
: 5.0.2
Assignee: Alejandro Guizar
QA Contact:
URL: http://jira.jboss.org/jira/browse/SOA...
Whiteboard:
Depends On: SOA-1596
Blocks:
TreeView+ depends on / blocked
 
Reported: 2009-12-11 13:09 UTC by Jaroslaw Kijanowski
Modified: 2010-07-12 17:15 UTC (History)
1 user (show)

Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed: 2010-07-12 17:15:16 UTC
Type: Bug


Attachments (Terms of Use)


Links
System ID Private Priority Status Summary Last Updated
Red Hat Issue Tracker SOA-1709 0 Major Closed NullPointerException in jbpm-console when viewing running process 2013-08-14 11:15:05 UTC

Description Jaroslaw Kijanowski 2009-12-11 13:09:39 UTC
Affects: Documentation (Ref Guide, User Guide, etc.), Release Notes
Date of First Response: 2009-12-15 15:33:09
Workaround: Workaround Exists
project_key: SOA

Details in SOA-1596.
Provided workaround/fix works fine.

Comment 1 Jaroslaw Kijanowski 2009-12-11 13:10:08 UTC
Link: Added: This issue depends SOA-1596


Comment 3 David Le Sage 2010-02-08 01:53:27 UTC
I have added the following draft text to the release notes:



If you try to view running process instances through the jBPM Console, a ServletException
will occur. This happens when process definitions use <fork> with <state>, <task> or <node
async="true">.

To workaround this issue, open the jbpm-console.war/app/t_tokens.xhtml and change

<gd:sort source="#{token.availableTransitions}" target="#{transitions}"
entryVar="e" argument="#{e.name}"/>

to

<gd:sort if="#{! empty token.availableTransitions}"
source="#{token.availableTransitions}" target="#{transitions}"
entryVar="e" argument="#{e.name == null ? '' : e.name}"/>.


Comment 5 David Le Sage 2010-02-15 00:43:20 UTC
I have documented this as per the above but can we please have a little bit more information as to what the workaround actually does - ie, how does it work and does it have any impact on functionality?


The Release Notes will be more useful for our users with this extra information.

Thanks, 

David

Comment 6 Toshiya Kobayashi 2010-02-15 01:43:18 UTC
This workaround is provided by Sara Rodríguez Dorrego (http://www.jboss.org/index.html?module=bb&op=viewtopic&t=151429)
It eliminates the possibility of NullPointerException by
- [if="#{! empty token.availableTransitions}"] -- don't render if there is no available transition
- [argument="#{e.name == null ? '' : e.name}"] -- use empty strings if transition name is null
I believe there is no drawback on functionality.


Comment 7 David Le Sage 2010-02-15 05:30:08 UTC
Thank you, Toshiya, for this information.  Much appreciated.



David

Comment 8 Len DiMaggio 2010-02-15 16:29:56 UTC
Affects: Added: [Documentation (Ref Guide, User Guide, etc.), Release Notes]


Comment 10 Len DiMaggio 2010-05-27 16:46:44 UTC
The issue was documented in 5.0 - can we safely fix it in 5.0.2?

Comment 11 Martin Vecera 2010-05-27 16:50:02 UTC
The documentation part of this issue is fine but we are still missing the fix in SOA-P 5.0.2. There is just half of the workaround implemented and the following part is not present:
- [if="#{! empty token.availableTransitions}"] -- don't render if there is no available transition

Comment 12 Martin Vecera 2010-05-27 16:52:01 UTC
Workaround: Added: [Workaround Exists]


Comment 13 Alejandro Guizar 2010-05-28 04:11:59 UTC
Link: Added: This issue incorporates JBPM-1930


Comment 14 Alejandro Guizar 2010-05-28 04:12:00 UTC
Reopened JBPM-1930 to incorporate the suggestion of not sorting if there are no available transitions.

Comment 15 Alejandro Guizar 2010-06-02 06:17:51 UTC
Resolved JBPM-1930: available transition set is no longer sorted if it is empty.
Deployed jsf-console-3.2.0 to the jboss release repo.

Comment 16 Len DiMaggio 2010-07-12 17:15:16 UTC
Verified to be resolved in 5.0.2, CR3 build:

jboss-soa-p.5.0.0/jboss-as/server/production/deploy/jbpm.esb/jbpm-console.war/app/t_tokens.xhtml

   155                              <gd:sort if="#{! empty token.availableTransitions}"
   156                                  source="#{token.availableTransitions}" target="#{transitions}"
   157                                  entryVar="t" argument="#{t.name != null ? t.name : ''}"/>

==============================================================

The fix was made in CR2 and CR3:

diff /opt/local/502_CR1/jboss-soa-p.5.0.0/jboss-as/server/production/deploy/jbpm.esb/jbpm-console.war/app/t_tokens.xhtml /opt/local/502_CR3_signed/jboss-soa-p.5.0.0/jboss-as/server/production/deploy/jbpm.esb/jbpm-console.war/app/t_tokens.xhtml 
155c155,156
<                             <gd:sort source="#{token.availableTransitions}" target="#{transitions}"
---
>                             <gd:sort if="#{! empty token.availableTransitions}"
>                                 source="#{token.availableTransitions}" target="#{transitions}"




Note You need to log in before you can comment on or make changes to this bug.