IBM Support

PH55109: NULLPOINTEREXCEPTION WHEN OBTAINING JSON OUTPUT FOR HPEL LOGS IN LOGVIEWER

Subscribe to this APAR

By subscribing, you receive periodic emails alerting you to the status of the APAR, along with a link to the fix after it becomes available. You can track this item individually or track all items by product.

Notify me when this APAR changes.

Notify me when an APAR for this component changes.

 

APAR status

  • Closed as program error.

Error description

  • When using the LogViewer to obtain the HPEL logging information
    in JSON format, a NullPointerException is encountered.
    
    
    The error can occur when additional trace strings are set in
    the HPEL configuration.
    
    
    The NullPointerException may look similar to the following:
    
    Caused by: java.lang.NullPointerException
    	at java.util.regex.Matcher.getTextLength(Matcher.java:1294)
    	at java.util.regex.Matcher.reset(Matcher.java:320)
    	at java.util.regex.Matcher.<init>(Matcher.java:240)
    	at java.util.regex.Pattern.matcher(Pattern.java:1104)
    	at com.ibm.websphere.logging.hpel.reader.HpelJsonFormatter.par
    seMessageId(HpelJsonFormatter.java:199)
    	at com.ibm.websphere.logging.hpel.reader.HpelJsonFormatter.jso
    nifyTraceAndMessage(HpelJsonFormatter.java:142)
    	at com.ibm.websphere.logging.hpel.reader.HpelJsonFormatter.for
    matRecord(HpelJsonFormatter.java:98)
    	at com.ibm.websphere.logging.hpel.reader.HpelFormatter.formatR
    ecord(HpelFormatter.java:514)
    	at com.ibm.ws.logging.hpel.viewer.LogViewer.displayRecords(Log
    Viewer.java:830)
    	at com.ibm.ws.logging.hpel.viewer.LogViewer.execute(LogViewer.
    java:440)
    	at com.ibm.ws.logging.hpel.viewer.LogViewer.execute(LogViewer.
    java:347)
    	at com.ibm.ws.logging.hpel.viewer.LogViewer.main(LogViewer.jav
    a:192)
    

Local fix

  • Remove additional trace strings in HPEL configuration one at a
    time to see if the NullPointerException re-occurs.
    

Problem summary

  • ****************************************************************
    * USERS AFFECTED:  All users of IBM WebSphere Application      *
    *                  Server                                      *
    ****************************************************************
    * PROBLEM DESCRIPTION: NullPointerException when using JSON    *
    *                      format logging with HPEL                *
    ****************************************************************
    * RECOMMENDATION:                                              *
    ****************************************************************
    When using the LogViewer to obtain the HPEL logging information
    in JSON format, a NullPointerException is encountered.
    The error can occur when additional trace strings are set in
    the HPEL configuration.
    The NullPointerException may look similar to the following:
    Caused by: java.lang.NullPointerException
    at java.util.regex.Matcher.getTextLength(Matcher.java:1294)
    at java.util.regex.Matcher.reset(Matcher.java:320)
    at java.util.regex.Matcher.<init>(Matcher.java:240)
    at java.util.regex.Pattern.matcher(Pattern.java:1104)
    at com.ibm.websphere.logging.hpel.reader.HpelJsonFormatter.par
    seMessageId(HpelJsonFormatter.java:199)
    at com.ibm.websphere.logging.hpel.reader.HpelJsonFormatter.jso
    nifyTraceAndMessage(HpelJsonFormatter.java:142)
    at com.ibm.websphere.logging.hpel.reader.HpelJsonFormatter.for
    matRecord(HpelJsonFormatter.java:98)
    at com.ibm.websphere.logging.hpel.reader.HpelFormatter.formatR
    ecord(HpelFormatter.java:514)
    at com.ibm.ws.logging.hpel.viewer.LogViewer.displayRecords(Log
    Viewer.java:830)
    at com.ibm.ws.logging.hpel.viewer.LogViewer.execute(LogViewer.
    java:440)
    at com.ibm.ws.logging.hpel.viewer.LogViewer.execute(LogViewer.
    java:347)
    at com.ibm.ws.logging.hpel.viewer.LogViewer.main(LogViewer.jav
    a:192)
    

Problem conclusion

  • When the JSON log is sent, we attempt to parse through the
    JSON to
    find the messageID field. If that JSON log is null, then an
    NPE is
    thrown when trying to parse through the null message. A null
    check
    has been added to address when a null log is sent.
    
    The fix for this APAR is targeted for inclusion in fix
    pack 8.5.5.25 and 9.0.5.18. For more information, see
    'Recommended Updates for WebSphere Application Server':
    https://www.ibm.com/support/pages/node/715553
    

Temporary fix

Comments

APAR Information

  • APAR number

    PH55109

  • Reported component name

    WEBSPHERE APP S

  • Reported component ID

    5724J0800

  • Reported release

    900

  • Status

    CLOSED PER

  • PE

    NoPE

  • HIPER

    NoHIPER

  • Special Attention

    NoSpecatt / Xsystem

  • Submitted date

    2023-06-12

  • Closed date

    2023-09-11

  • Last modified date

    2023-09-11

  • APAR is sysrouted FROM one or more of the following:

  • APAR is sysrouted TO one or more of the following:

Fix information

  • Fixed component name

    WEBSPHERE APP S

  • Fixed component ID

    5724J0800

Applicable component levels

[{"Business Unit":{"code":"BU059","label":"IBM Software w\/o TPS"},"Product":{"code":"SSEQTP","label":"WebSphere Application Server"},"Platform":[{"code":"PF025","label":"Platform Independent"}],"Version":"9.0","Line of Business":{"code":"LOB45","label":"Automation"}}]

Document Information

Modified date:
12 September 2023