IBM Support

PI49978: If CDI 1.2 is enabled then a BeanManager could be returned when resolving any JNDI value.

Subscribe

You can track all active APARs for this component.

 

APAR status

  • Closed as program error.

Error description

  • If a value is programmatically bound into JNDI using
    InitialContext.bind() then when the variable is resolved
    using InitialContext.lookup(), it will always return the
    current CDI BeanManager instead of the real value. This only
    occurs if CDI 1.2 is enabled and the value is
    programmatically bound. It will not occur if the value is
    specified as a jndiEntry in the server.xml.
    

Local fix

Problem summary

  • ****************************************************************
    * USERS AFFECTED:  All users of IBM WebSphere Application      *
    *                  Server using CDI 1.2 and JNDI               *
    ****************************************************************
    * PROBLEM DESCRIPTION: If CDI 1.2 is enabled then a            *
    *                      BeanManager could be returned when      *
    *                      resolving any JNDI value.               *
    ****************************************************************
    * RECOMMENDATION:                                              *
    ****************************************************************
    If a value is programmatically bound into JNDI using
    InitialContext.bind() then when the variable is resolved using
    InitialContext.lookup(), it will always return the current CDI
    BeanManager instead of the real value. This only occurs if CDI
    1.2 is enabled and the value is programmatically bound. It will
    not occur if the value is specified as a jndiEntry in the
    server.xml.
    

Problem conclusion

  • We have fixed the CDI BeanManager ObjectFactory to only return a
    BeanManager when the JNDI object being resolved is a Reference
    and not, for example, just a String.
    
    The fix for this APAR is currently targeted for inclusion in fix
    pack 8.5.5.8.  Please refer to the Recommended Updates page for
    delivery information:
    http://www.ibm.com/support/docview.wss?rs=180&uid=swg27004980
    

Temporary fix

  • Use a jndiEntry in the server.xml to configure JNDI values
    rather than adding them via the InitialContext.
    

Comments

APAR Information

  • APAR number

    PI49978

  • Reported component name

    WAS LIBERTY COR

  • Reported component ID

    5725L2900

  • Reported release

    855

  • Status

    CLOSED PER

  • PE

    NoPE

  • HIPER

    NoHIPER

  • Special Attention

    NoSpecatt / Xsystem

  • Submitted date

    2015-10-06

  • Closed date

    2015-10-09

  • Last modified date

    2015-10-09

  • 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

    WAS LIBERTY COR

  • Fixed component ID

    5725L2900

Applicable component levels

  • R855 PSY

       UP

[{"Business Unit":{"code":"BU053","label":"Cloud \u0026 Data Platform"},"Product":{"code":"SSD28V","label":"WebSphere Application Server Liberty Core"},"Platform":[{"code":"PF025","label":"Platform Independent"}],"Version":"855","Line of Business":{"code":"LOB36","label":"IBM Automation"}}]

Document Information

Modified date:
17 October 2021