I am getting the following error, when running the client class

Discussions

EJB programming & troubleshooting: I am getting the following error, when running the client class

  1. I am getting the following error, when running the client class.


    F:\weblogic\myserver\clientclasses>java examples.ejb.basic.statelessSession.Client "t3://localhost:7001"

    Beginning statelessSession.Client...

    Exception in thread "main" java.lang.NoClassDefFoundError: com/sun/java/util/collections/ArrayList
            at weblogic.jndi.WLInitialContextFactoryDelegate.getInitialContext(WLInitialContextFactoryDelegate.java:193)
            at weblogic.jndi.WLInitialContextFactoryDelegate.getInitialContext(WLInitialContextFactoryDelegate.java:148)
            at weblogic.jndi.WLInitialContextFactory.getInitialContext(WLInitialContextFactory.java:123)
            at javax.naming.spi.NamingManager.getInitialContext(NamingManager.java:668)
            at javax.naming.InitialContext.getDefaultInitCtx(InitialContext.java:246)
            at javax.naming.InitialContext.init(InitialContext.java:222)
            at javax.naming.InitialContext.<init>(InitialContext.java:198)
            at examples.ejb.basic.statelessSession.Client.getInitialContext(Client.java:175)
            at examples.ejb.basic.statelessSession.Client.lookupHome(Client.java:144)
            at examples.ejb.basic.statelessSession.Client.<init>(Client.java:44)
            at examples.ejb.basic.statelessSession.Client.main(Client.java:82)

    I appreciate any one help?
    Thanks,
    Usha.
  2. Try Unjaring weblogicaux.jar file and set the path to its directory.
  3. Thank you, I got it.