3 Replies Latest reply on Jun 8, 2005 12:39 PM by shushamen

    NameNotFoundException while running client.

    bill.burke

      1) EJB3 only is tested on 4.0.1SP1. People have reported problems with 4.0.2 with WARs accesssing Entities, as the default classloading config has changed. DO NOT USE 4.0.2 RC1!!!! Please follow the install directions.

      2) If you try 4.0.1SP! or 4.0.2 final and it still doesn't work, please look to see if there were any errors on JBoss startup. If there were, please check the install directions to make sure you installed things correctly.

        • 1. Re: NameNotFoundException while running client.
          murtuza52

          Hello,

          I installed jboss 4.0.2 final and deployed application on the same. Again there are no errors on the JBoss console, a folder with the ".ejb3" in created in the jboss deployed location correctly but the jmx-console still not have the bean listed. Anyways, here are the step for writing (:- copying) this application from the tutorial.

          1. In MyEclipse create new EJB application with name KTEE.ejb3
          2. Create new class for Order, LineItem, ShoppingCart, ShoppingCartBean from the tutorial code.
          3. Deploy on JBoss4.0.2 final with no descriptor file ( as per ejb3 specification there are no deployment descriptor)
          4. The client.java is again from the tutorial.

          When run it throws the same "NameNotFound" exception posted earlier. There are two things i suspect:
          1. A bug in jboss or any step that i m missing somewhere.
          2. Can anyone tell me how to include jndi.properties file in the classpath using MyEclipse for the client.java.

          Here it the log snippet from the JBoss console, there is not much in it as there are no errors thrown.

          09:51:59,738 INFO [RARDeployment] Required license terms exist view the META-INF/ra.xml: file:/D:/jboss-4.0.2/server/default/deploy/jboss-ha-local-jdbc.rar
          09:52:00,395 INFO [RARDeployment] Required license terms exist view the META-INF/ra.xml: file:/D:/jboss-4.0.2/server/default/deploy/jboss-ha-xa-jdbc.rar
          09:52:00,863 INFO [RARDeployment] Required license terms exist view the META-INF/ra.xml: file:/D:/jboss-4.0.2/server/default/deploy/jboss-local-jdbc.rar
          09:52:01,379 INFO [RARDeployment] Required license terms exist view the META-INF/ra.xml: file:/D:/jboss-4.0.2/server/default/deploy/jboss-xa-jdbc.rar
          09:52:01,848 INFO [RARDeployment] Required license terms exist view the META-INF/ra.xml: file:/D:/jboss-4.0.2/server/default/deploy/jms/jms-ra.rar
          09:52:02,363 INFO [RARDeployment] Required license terms exist view the META-INF/ra.xml: file:/D:/jboss-4.0.2/server/default/deploy/mail-ra.rar
          09:52:06,770 INFO [WrapperDataSourceService] Bound connection factory for resource adapter for ConnectionManager 'jboss.jca:service=DataSourceBinding,name=DefaultDS to JNDI name 'java:DefaultDS'
          09:52:08,082 INFO [A] Bound to JNDI name: queue/A
          09:52:08,082 INFO [B] Bound to JNDI name: queue/B
          09:52:08,082 INFO [C] Bound to JNDI name: queue/C
          09:52:08,098 INFO [D] Bound to JNDI name: queue/D
          09:52:08,098 INFO [ex] Bound to JNDI name: queue/ex
          09:52:08,238 INFO [testTopic] Bound to JNDI name: topic/testTopic
          09:52:08,238 INFO [securedTopic] Bound to JNDI name: topic/securedTopic
          09:52:08,270 INFO [testDurableTopic] Bound to JNDI name: topic/testDurableTopic
          09:52:08,285 INFO [testQueue] Bound to JNDI name: queue/testQueue
          09:52:08,488 INFO [UILServerILService] JBossMQ UIL service available at : /0.0.0.0:8093
          09:52:08,738 INFO [DLQ] Bound to JNDI name: queue/DLQ
          09:52:09,832 INFO [ConnectionFactoryBindingService] Bound connection factory for resource adapter for ConnectionManager 'jboss.jca:service=ConnectionFactoryBinding,name=JmsXA to JNDI name 'java:JmsXA'
          09:52:10,457 INFO [WrapperDataSourceService] Bound connection factory for resource adapter for ConnectionManager 'jboss.jca:service=DataSourceBinding,name=MySqlDS to JNDI name 'java:MySqlDS'
          09:52:10,660 INFO [TomcatDeployer] deploy, ctxPath=/jmx-console, warUrl=file:/D:/jboss-4.0.2/server/default/deploy/jmx-console.war/
          09:52:12,504 INFO [Http11Protocol] Starting Coyote HTTP/1.1 on http-0.0.0.0-8080
          09:52:13,926 INFO [ChannelSocket] JK: ajp13 listening on /0.0.0.0:8009
          09:52:14,192 INFO [JkMain] Jk running ID=0 time=0/1079 config=null
          09:52:14,238 INFO [Server] JBoss (MX MicroKernel) [4.0.2 (build: CVSTag=JBoss_4_0_2 date=200505022023)] Started in 1m:5s:687ms


          Can anyone help on this soon.

          Thanks in advance.

          • 2. Re: NameNotFoundException while running client.
            murtuza52

            Further to my last posting, i also have hibernate.properties file in the META-INF folder

            hibernate.transaction.manager_lookup_class=org.hibernate.transaction.JBossTransactionManagerLookup
            hibernate.query.factory_class=org.hibernate.hql.ast.ASTQueryTranslatorFactory
            hibernate.hbm2ddl.auto=create-drop
            #hibernate.hbm2ddl.auto=create
            hibernate.cache.provider_class=org.hibernate.cache.HashtableCacheProvider
            # Clustered cache with TreeCache
            #hibernate.cache.provider_class=org.jboss.ejb3.entity.TreeCacheProviderHook
            #hibernate.treecache.mbean.object_name=jboss.cache:service=EJB3EntityTreeCache
            hibernate.connection.datasource=java:/MySqlDS
            hibernate.dialect=org.hibernate.dialect.MySQLDialect

            Can anyone help me on this and tell me why i cannot deploy the bean. I'll appreciate if someone can show me show direction.

            Thanks in advance.

            • 3. Re: NameNotFoundException while running client.

              I think the problem is running jboss 4.0.2 with default configuration try with all configuration