2 Replies Latest reply on Mar 6, 2007 11:59 AM by Sebastian Pätzold

    java.lang.NoClassDefFoundError: org/jboss/aop/WeavingStrateg

    Sebastian Pätzold Newbie

      Hi!

      I#ve got a problem with a test application I try to write. If I execute the following piece of code, I get the exception "java.lang.NoClassDefFoundError: org/jboss/aop/WeavingStrategy" on the last line. I don't know at all what to do with it. Google and a forum search didn't turn up anything. Also the messaging documentation didn't help (or at least I haven't found anything). This is the code:

      // properties of context
      Properties props = new Properties();
      props.put(Context.INITIAL_CONTEXT_FACTORY, "org.jnp.interfaces.NamingContextFactory");
      props.put(Context.PROVIDER_URL, "jnp://127.0.0.1:1099");
      props.put("java.naming.factory.url.pkgs", "org.jboss.naming:org.jnp.interfaces");
      props.put("jnp.disableDiscovery", "true");
      
      // prepare context for JNDI look ups
      InitialContext jndiContext = new InitialContext(props);
      
      // get connection factory via JNDI look up
      ConnectionFactory factory = (ConnectionFactory)jndiContext.lookup("/ConnectionFactory");
      


      I use JBoss AS 5.0.0 Beta 1. The configuration is unmodified. Has anyone tips where to do research or any hints what might be wrong? Thanks in advance.

      Cheers,
      Sebastian