[esb-issues] [JBoss JIRA] Commented: (JBESB-2976) Null pointer exception in JOPR plugin (plus fix?)
Kevin Conner (JIRA)
jira-events at lists.jboss.org
Thu Nov 12 06:44:05 EST 2009
[ https://jira.jboss.org/jira/browse/JBESB-2976?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12494300#action_12494300 ]
Kevin Conner commented on JBESB-2976:
-------------------------------------
I have copied the code used in other paths, although not sure why we are doing it this way. It now reads
String processed = new String();
if (attribute != null) {
processed = (String) attribute.refresh();
}
> Null pointer exception in JOPR plugin (plus fix?)
> -------------------------------------------------
>
> Key: JBESB-2976
> URL: https://jira.jboss.org/jira/browse/JBESB-2976
> Project: JBoss ESB
> Issue Type: Bug
> Security Level: Public(Everyone can see)
> Components: Management
> Affects Versions: 4.6
> Reporter: Kevin Conner
> Assignee: Kevin Conner
> Fix For: 4.7
>
>
> Hi,
> I deployed the BPM orchestration 2 quickstart and then went to:
> JBoss ESB Statistics
> JBoss ESB Deployments
> Quickstart_bpm_orchestration2.esb JBoss ESB Statistics
> JBoss ESB Services
> ResultsService Service
> JBoss ESB Listeners
> ESB-Listener - BPM_Orchestration2_Service1 Listener Configuration
> in the admin console. I saw:
> 15:58:15,811 ERROR [MeasurementManager] Could not get measurement values
> java.lang.NullPointerException
> at org.jbosson.plugins.jbossesb.ListenerComponent.getValues(ListenerComponent.java:64)
> Is the attached the correct fix (it hides the exception and is similar to the
> other clauses)?
> Thanks,
> J
> Index: product/tools/jonplugin/src/main/java/org/jbosson/plugins/jbossesb/ListenerComponent.java
> ===================================================================
> --- product/tools/jonplugin/src/main/java/org/jbosson/plugins/jbossesb/ListenerComponent.java (revision 30085)
> +++ product/tools/jonplugin/src/main/java/org/jbosson/plugins/jbossesb/ListenerComponent.java (working copy)
> @@ -61,8 +61,10 @@
> String metricName = request.getName();
> if (metricName.equals(MEP)) {
> EmsAttribute attribute = getEmsBean().getAttribute(MEP);
> - String processed = (String) attribute.refresh();
> - report.addData(new MeasurementDataTrait(request, processed));
> + if (attribute != null) {
> + String processed = (String) attribute.refresh();
> + report.addData(new MeasurementDataTrait(request, processed));
> + }
> } else if (metricName.equals(LIFECYCLE_STATE)) {
> EmsAttribute attribute = getEmsBean().getAttribute(LIFECYCLE_STATE);
> String processed = new String();
--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: https://jira.jboss.org/jira/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira
More information about the esb-issues
mailing list