Skip to main content

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [List Home]
[eclipselink-dev] Fix for enhancement 323403: NPE on missing Weaving VH getMethod on deploy validation requires better error message stating the application.xml deployment descriptor module order should be switched - ready for review

    The following fix for bug# 323403 is ready for review (this bug also unblocks bug # 323148 - the tracking bug for the base Glassfish-JSF classLoader issue)"">
    WebLogic minimal JSF EAR reproduction

    - Essentially we no longer throw a NPE when we fail to find weaved methods on LAZY mappings like "_persistence_*_vh" - we now warn and throw a proper DescriptorException that details the reason why weaving is failing - instead of throwing a secondary NPE on a null(missing) method call.

    - This bug occurs on certain EE servers including WebLogic and Glassfish (they both use Glassfish-JSF) when an EAR containing an injected JTA @PersistenceContext on a SSB on an ejb-jar is referenced in a non-servlet context like on a JSF managed-bean POJO in a WAR in a WAR/EJB-jar order.
    - The base bug is an issue with how JSF uses EE classLoaders on the server.  Therefore the base workaround for 323148 is to reverse the order of the ejb.jar and war in the application.xml deployment descriptor by placing the ejb-jar first so that it will be weaved before it is referenced during validation in the EM deploy()

    Note: The cause of the NPE was a group effort between Michael O'Brien, Douglas Clarke and Steve Button.
    The following open issues benefit from this fix.

        Re: [eclipselink-users] OneToOne AND ManyToOne Mapping works with FetchType.EAGER but not with FetchType.LAZY -> Exception when deploying (SGES 2.1)
        Re: [eclipselink-users] JPA not working inside Equinox but fine in unit tests
        Re: [eclipselink-users] Can't deploy when using LAZY, can deply when using EAGER
        Re: [eclipselink-users] NPE when running with option javaagent:eclipselink.jar
        JPA test suties failed in OSGi with enabled weaving

    Regression testing:
       Core LRG and JPA LRG are OK

    thank you

Back to the top