<div dir="ltr"><div class="gmail_quote"><div dir="ltr" class="gmail_attr"><br></div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex"><div>It's great to make projects aware that they
    are depending on APIs that are long deprecated<br></div></blockquote><div><br></div><div>I gave Oracle WebLogic Server 14.1.1 a spin on 21-internal with Identity and friends removed. This version of WLS supports Java EE 8.</div><div><br></div><div>Accessing an EJB with an injected EJBContext somewhat predictably fails with a NoClassDefFoundError / ClassNotFoundException:</div><div><br></div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex">Root cause of ServletException.<br>java.lang.NoClassDefFoundError: java/security/Identity<br>        at weblogic.ejb.container.manager.StatefulSessionManager.allocateContext(StatefulSessionManager.java:947)<br>[..]<br>Caused By: java.lang.ClassNotFoundException: java.security.Identity<br>        at java.base/jdk.internal.loader.BuiltinClassLoader.loadClass(BuiltinClassLoader.java:641)</blockquote><div><br></div><div>I believe this NoClassDefFoundError has an easily fix, which is to move any BaseEJBContext code touching java/security/Identity out of the BaseEJBContext class, such that any class loading of java/security/Identity is deferred until any of the deprecated methods are actually called. This fix would allow apps not calling the deprecated methods to deploy as usual in WLS using a JDK with these classes removed.</div><div><br></div><div>If anyone knows how to get in touch with relevant people in the WebLogic organization to discuss this, please let me know in a private email.</div><div><br></div><div>Eirik.</div></div></div>