2 Replies Latest reply on Jul 12, 2005 1:57 AM by Patrik Meisinger

    NameNotFoundException at context lookup

    Patrik Meisinger Newbie

      hi!

      i want to use a stateless session bean in my servlet code, but i'm getting a namenotfoundexception when i try to do a lookup for my bean.

      here's the code of the init()-method of the servlet.

       public void init(ServletConfig config) throws ServletException {
       try {
      
       InitialContext ctx = new InitialContext();
       aktenBean = (AktenBean)(ctx.lookup(AktenBean.class.getName()));
       it = (aktenBean.getAllAkten().iterator());
      
       } catch (Exception e) {
       System.out.println("*******************");
       System.out.println("** lookup failed **");
       System.out.println("*******************");
      
      
       e.printStackTrace ();
       }
       }
      

      there's something wrong with call to ctx.lookup(...), but i don't know it.

      the code of my bean:
      @Stateless
      public class AktenBean implements Akten {
      
       @PersistenceContext (unitName="IngresManager")
       private EntityManager em;
      
       public Collection getAllAkten() {
       return ((new AkteFacade(em)).getAllAkten());
       }
      }
      


      the "IngresManager" is the name of the entitymanager in persistence.xml which is in the META-INF directory of the entities.par. the AkteFacade should use the entitymanager to make a query to my entity beans using the properties defined in the file persistence.properties from the directory jbosshome/deploy/ejb3.deployer/META-INF.

      my application is packaged into an ear consisting of web.war (my web-app with the servlet), business.ejb3 (inside is stateless session bean) and entities.par (hibernate persistence archive with two entity beans).

      the deployment is done well except the web.war. i got the following output on the jboss-console:
      12:28:00,400 INFO [STDOUT] *******************
      12:28:00,400 INFO [STDOUT] ** lookup failed **
      12:28:00,400 INFO [STDOUT] *******************
      12:28:00,400 INFO [STDOUT] javax.naming.NameNotFoundException: ams.beans.statel
      ess.AktenBean not bound
      12:28:00,410 INFO [STDOUT] at org.jnp.server.NamingServer.getBinding(Naming
      Server.java:491)
      12:28:00,410 INFO [STDOUT] at org.jnp.server.NamingServer.getBinding(Naming
      Server.java:499)
      12:28:00,410 INFO [STDOUT] at org.jnp.server.NamingServer.getObject(NamingS
      erver.java:505)
      12:28:00,410 INFO [STDOUT] at org.jnp.server.NamingServer.lookup(NamingServ
      er.java:278)
      12:28:00,410 INFO [STDOUT] at org.jnp.interfaces.NamingContext.lookup(Namin
      gContext.java:610)
      12:28:00,410 INFO [STDOUT] at org.jnp.interfaces.NamingContext.lookup(Namin
      gContext.java:572)
      12:28:00,410 INFO [STDOUT] at javax.naming.InitialContext.lookup(InitialCon
      text.java:351)
      12:28:00,410 INFO [STDOUT] at ams.web.client.DipasNgHibernateServlet.init(D
      ipasNgHibernateServlet.java:33)
      12:28:00,410 INFO [STDOUT] at org.apache.catalina.core.StandardWrapper.load
      Servlet(StandardWrapper.java:1091)
      12:28:00,410 INFO [STDOUT] at org.apache.catalina.core.StandardWrapper.load
      (StandardWrapper.java:925)
      12:28:00,410 INFO [STDOUT] at org.apache.catalina.core.StandardContext.load
      OnStartup(StandardContext.java:3857)
      12:28:00,410 INFO [STDOUT] at org.apache.catalina.core.StandardContext.star
      t(StandardContext.java:4118)
      12:28:00,410 INFO [STDOUT] at org.apache.catalina.core.ContainerBase.addChi
      ldInternal(ContainerBase.java:759)
      12:28:00,410 INFO [STDOUT] at org.apache.catalina.core.ContainerBase.addChi
      ld(ContainerBase.java:739)
      12:28:00,410 INFO [STDOUT] at org.apache.catalina.core.StandardHost.addChil
      d(StandardHost.java:524)
      12:28:00,410 INFO [STDOUT] at sun.reflect.GeneratedMethodAccessor108.invoke
      (Unknown Source)
      12:28:00,410 INFO [STDOUT] at sun.reflect.DelegatingMethodAccessorImpl.invo
      ke(DelegatingMethodAccessorImpl.java:25)
      12:28:00,410 INFO [STDOUT] at java.lang.reflect.Method.invoke(Method.java:5
      85)
      12:28:00,410 INFO [STDOUT] at org.apache.commons.modeler.BaseModelMBean.inv
      oke(BaseModelMBean.java:503)
      12:28:00,410 INFO [STDOUT] at org.jboss.mx.server.RawDynamicInvoker.invoke(
      RawDynamicInvoker.java:150)
      12:28:00,410 INFO [STDOUT] at org.jboss.mx.server.MBeanServerImpl.invoke(MB
      eanServerImpl.java:644)
      12:28:00,410 INFO [STDOUT] at org.apache.catalina.core.StandardContext.init
      (StandardContext.java:5005)
      12:28:00,410 INFO [STDOUT] at sun.reflect.NativeMethodAccessorImpl.invoke0(
      Native Method)
      12:28:00,410 INFO [STDOUT] at sun.reflect.NativeMethodAccessorImpl.invoke(N
      ativeMethodAccessorImpl.java:39)
      12:28:00,410 INFO [STDOUT] at sun.reflect.DelegatingMethodAccessorImpl.invo
      ke(DelegatingMethodAccessorImpl.java:25)
      12:28:00,410 INFO [STDOUT] at java.lang.reflect.Method.invoke(Method.java:5
      85)
      12:28:00,410 INFO [STDOUT] at org.apache.commons.modeler.BaseModelMBean.inv
      oke(BaseModelMBean.java:503)
      12:28:00,410 INFO [STDOUT] at org.jboss.mx.server.RawDynamicInvoker.invoke(
      RawDynamicInvoker.java:150)
      12:28:00,410 INFO [STDOUT] at org.jboss.mx.server.MBeanServerImpl.invoke(MB
      eanServerImpl.java:644)
      12:28:00,410 INFO [STDOUT] at org.jboss.web.tomcat.tc5.TomcatDeployer.perfo
      rmDeployInternal(TomcatDeployer.java:274)
      12:28:00,410 INFO [STDOUT] at org.jboss.web.tomcat.tc5.TomcatDeployer.perfo
      rmDeploy(TomcatDeployer.java:91)
      12:28:00,410 INFO [STDOUT] at org.jboss.web.AbstractWebDeployer.start(Abstr
      actWebDeployer.java:357)
      12:28:00,410 INFO [STDOUT] at org.jboss.web.WebModule.startModule(WebModule
      .java:68)
      12:28:00,410 INFO [STDOUT] at org.jboss.web.WebModule.startService(WebModul
      e.java:46)
      12:28:00,410 INFO [STDOUT] at org.jboss.system.ServiceMBeanSupport.jbossInt
      ernalStart(ServiceMBeanSupport.java:267)
      12:28:00,410 INFO [STDOUT] at org.jboss.system.ServiceMBeanSupport.jbossInt
      ernalLifecycle(ServiceMBeanSupport.java:217)
      12:28:00,410 INFO [STDOUT] at sun.reflect.NativeMethodAccessorImpl.invoke0(
      Native Method)
      12:28:00,410 INFO [STDOUT] at sun.reflect.NativeMethodAccessorImpl.invoke(N
      ativeMethodAccessorImpl.java:39)
      12:28:00,410 INFO [STDOUT] at sun.reflect.DelegatingMethodAccessorImpl.invo
      ke(DelegatingMethodAccessorImpl.java:25)
      12:28:00,410 INFO [STDOUT] at java.lang.reflect.Method.invoke(Method.java:5
      85)
      12:28:00,410 INFO [STDOUT] at org.jboss.mx.interceptor.ReflectedDispatcher.
      invoke(ReflectedDispatcher.java:141)
      12:28:00,410 INFO [STDOUT] at org.jboss.mx.server.Invocation.dispatch(Invoc
      ation.java:80)
      12:28:00,410 INFO [STDOUT] at org.jboss.mx.server.Invocation.invoke(Invocat
      ion.java:72)
      12:28:00,410 INFO [STDOUT] at org.jboss.mx.server.AbstractMBeanInvoker.invo
      ke(AbstractMBeanInvoker.java:245)
      12:28:00,410 INFO [STDOUT] at org.jboss.mx.server.MBeanServerImpl.invoke(MB
      eanServerImpl.java:644)
      12:28:00,410 INFO [STDOUT] at org.jboss.system.ServiceController$ServicePro
      xy.invoke(ServiceController.java:950)
      12:28:00,410 INFO [STDOUT] at $Proxy0.start(Unknown Source)
      12:28:00,410 INFO [STDOUT] at org.jboss.system.ServiceController.start(Serv
      iceController.java:436)
      12:28:00,410 INFO [STDOUT] at sun.reflect.GeneratedMethodAccessor7.invoke(U
      nknown Source)
      12:28:00,410 INFO [STDOUT] at sun.reflect.DelegatingMethodAccessorImpl.invo
      ke(DelegatingMethodAccessorImpl.java:25)
      12:28:00,410 INFO [STDOUT] at java.lang.reflect.Method.invoke(Method.java:5
      85)
      12:28:00,410 INFO [STDOUT] at org.jboss.mx.interceptor.ReflectedDispatcher.
      invoke(ReflectedDispatcher.java:141)
      12:28:00,410 INFO [STDOUT] at org.jboss.mx.server.Invocation.dispatch(Invoc
      ation.java:80)
      12:28:00,410 INFO [STDOUT] at org.jboss.mx.server.Invocation.invoke(Invocat
      ion.java:72)
      12:28:00,410 INFO [STDOUT] at org.jboss.mx.server.AbstractMBeanInvoker.invo
      ke(AbstractMBeanInvoker.java:245)
      12:28:00,410 INFO [STDOUT] at org.jboss.mx.server.MBeanServerImpl.invoke(MB
      eanServerImpl.java:644)
      12:28:00,410 INFO [STDOUT] at org.jboss.mx.util.MBeanProxyExt.invoke(MBeanP
      roxyExt.java:176)
      12:28:00,410 INFO [STDOUT] at $Proxy28.start(Unknown Source)
      12:28:00,410 INFO [STDOUT] at org.jboss.web.AbstractWebContainer.start(Abst
      ractWebContainer.java:394)
      12:28:00,410 INFO [STDOUT] at sun.reflect.GeneratedMethodAccessor106.invoke
      (Unknown Source)
      12:28:00,410 INFO [STDOUT] at sun.reflect.DelegatingMethodAccessorImpl.invo
      ke(DelegatingMethodAccessorImpl.java:25)
      12:28:00,410 INFO [STDOUT] at java.lang.reflect.Method.invoke(Method.java:5
      85)
      12:28:00,410 INFO [STDOUT] at org.jboss.mx.interceptor.ReflectedDispatcher.
      invoke(ReflectedDispatcher.java:141)
      12:28:00,410 INFO [STDOUT] at org.jboss.mx.server.Invocation.dispatch(Invoc
      ation.java:80)
      12:28:00,410 INFO [STDOUT] at org.jboss.mx.interceptor.AbstractInterceptor.
      invoke(AbstractInterceptor.java:118)
      12:28:00,410 INFO [STDOUT] at org.jboss.mx.server.Invocation.invoke(Invocat
      ion.java:74)
      12:28:00,410 INFO [STDOUT] at org.jboss.mx.interceptor.ModelMBeanOperationI
      nterceptor.invoke(ModelMBeanOperationInterceptor.java:127)
      12:28:00,410 INFO [STDOUT] at org.jboss.mx.interceptor.DynamicInterceptor.i
      nvoke(DynamicInterceptor.java:80)
      12:28:00,410 INFO [STDOUT] at org.jboss.mx.server.Invocation.invoke(Invocat
      ion.java:74)
      12:28:00,410 INFO [STDOUT] at org.jboss.mx.server.AbstractMBeanInvoker.invo
      ke(AbstractMBeanInvoker.java:245)
      12:28:00,410 INFO [STDOUT] at org.jboss.mx.server.MBeanServerImpl.invoke(MB
      eanServerImpl.java:644)
      12:28:00,410 INFO [STDOUT] at org.jboss.mx.util.MBeanProxyExt.invoke(MBeanP
      roxyExt.java:176)
      12:28:00,410 INFO [STDOUT] at $Proxy29.start(Unknown Source)
      12:28:00,410 INFO [STDOUT] at org.jboss.deployment.MainDeployer.start(MainD
      eployer.java:973)
      12:28:00,971 INFO [STDOUT] at org.jboss.deployment.MainDeployer.deploy(Main
      Deployer.java:774)
      12:28:00,971 INFO [STDOUT] at org.jboss.deployment.MainDeployer.deploy(Main
      Deployer.java:737)
      12:28:00,981 INFO [STDOUT] at sun.reflect.GeneratedMethodAccessor16.invoke(
      Unknown Source)
      12:28:00,991 INFO [STDOUT] at sun.reflect.DelegatingMethodAccessorImpl.invo
      ke(DelegatingMethodAccessorImpl.java:25)
      12:28:01,001 INFO [STDOUT] at java.lang.reflect.Method.invoke(Method.java:5
      85)
      12:28:01,001 INFO [STDOUT] at org.jboss.mx.interceptor.ReflectedDispatcher.
      invoke(ReflectedDispatcher.java:141)
      12:28:01,011 INFO [STDOUT] at org.jboss.mx.server.Invocation.dispatch(Invoc
      ation.java:80)
      12:28:01,021 INFO [STDOUT] at org.jboss.mx.interceptor.AbstractInterceptor.
      invoke(AbstractInterceptor.java:118)
      12:28:01,031 INFO [STDOUT] at org.jboss.mx.server.Invocation.invoke(Invocat
      ion.java:74)
      12:28:01,031 INFO [STDOUT] at org.jboss.mx.interceptor.ModelMBeanOperationI
      nterceptor.invoke(ModelMBeanOperationInterceptor.java:127)
      12:28:01,041 INFO [STDOUT] at org.jboss.mx.server.Invocation.invoke(Invocat
      ion.java:74)
      12:28:01,051 INFO [STDOUT] at org.jboss.mx.server.AbstractMBeanInvoker.invo
      ke(AbstractMBeanInvoker.java:245)
      12:28:01,061 INFO [STDOUT] at org.jboss.mx.server.MBeanServerImpl.invoke(MB
      eanServerImpl.java:644)
      12:28:01,071 INFO [STDOUT] at org.jboss.mx.util.MBeanProxyExt.invoke(MBeanP
      roxyExt.java:176)
      12:28:01,071 INFO [STDOUT] at $Proxy6.deploy(Unknown Source)
      12:28:01,081 INFO [STDOUT] at org.jboss.deployment.scanner.URLDeploymentSca
      nner.deploy(URLDeploymentScanner.java:325)
      12:28:01,081 INFO [STDOUT] at org.jboss.deployment.scanner.URLDeploymentSca
      nner.scan(URLDeploymentScanner.java:501)
      12:28:01,091 INFO [STDOUT] at org.jboss.deployment.scanner.AbstractDeployme
      ntScanner$ScannerThread.doScan(AbstractDeploymentScanner.java:204)
      12:28:01,101 INFO [STDOUT] at org.jboss.deployment.scanner.AbstractDeployme
      ntScanner$ScannerThread.loop(AbstractDeploymentScanner.java:215)
      12:28:01,111 INFO [STDOUT] at org.jboss.deployment.scanner.AbstractDeployme
      ntScanner$ScannerThread.run(AbstractDeploymentScanner.java:194)
      12:28:16,152 INFO [TomcatDeployer] undeploy, ctxPath=/web, warUrl=file:/D:/jbos
      s-4.0.3RC1/server/default/tmp/deploy/tmp46467web-exp.war/



      how can i use the stateless session bean in the servlet? i guess it's a trivial problem but i'm not able to solve it.
      i appreciate any hint which will lead me to a right way. thanks in advance!
      regards
      patrik


      ps.: my system config
      eclipse 3.1rc4, jdk1.5update3, jboss4.0.3rc1 with ejb3, hibernate 3.1alpha

      pps.: more info:
      the global jndi namespace:
      +- XAConnectionFactory (class: org.jboss.mq.SpyXAConnectionFactory)
      +- containers (class: org.jnp.interfaces.NamingContext)
      | +- ams.beans.stateless.AktenBean (class: org.jboss.ejb3.stateless.StatelessContainer)
      (in the third line i see that the bean is bound, or am i wrong?)

        • 1. Re: NameNotFoundException at context lookup
          Patrik Meisinger Newbie

          more info on the deployment. the following lines happen before ** lookup failed **:

          13:06:33,001 INFO [EARDeployer] Init J2EE application: file:/D:/jboss-4.0.3RC1/
          server/default/deploy/DipasNgHibernate.ear
          13:06:33,071 INFO [JaccHelper] Initialising JACC Context for deployment: busine
          ss.ejb3
          13:06:33,081 INFO [Ejb3AnnotationHandler] found EJB3: ejbName=ams.beans.statele
          ss.AktenBean, class=ams.beans.stateless.AktenBean, type=STATELESS
          13:06:33,091 INFO [JaccHelper] ams.beans.stateless.AktenBean has no @SecurityDo
          main - skipping JACC configuration
          13:06:33,091 INFO [JaccHelper] JACC Policy Configuration for deployment has bee
          n put in service
          13:06:33,091 INFO [Ejb3Module] EJB3 deployment time took: 20
          13:06:33,101 INFO [JaccHelper] Initialising JACC Context for deployment: entiti
          es.par
          13:06:33,111 INFO [Ejb3AnnotationHandler] found EJB3: ejbName=ams.ingres.model.
          PvFamip, class=ams.ingres.model.PvFamip, type=ENTITY
          13:06:33,111 INFO [Ejb3Module] found EJB3 Entity bean: ams.ingres.model.PvFamip
          
          13:06:33,121 INFO [Ejb3AnnotationHandler] found EJB3: ejbName=ams.ingres.model.
          PvStamp, class=ams.ingres.model.PvStamp, type=ENTITY
          13:06:33,131 INFO [Ejb3Module] found EJB3 Entity bean: ams.ingres.model.PvStamp
          
          13:06:33,131 INFO [Ejb3Module] Found persistence.xml file in EJB3 jar
          13:06:33,152 INFO [Configuration] processing extends queue
          13:06:33,152 INFO [Configuration] processing collection mappings
          13:06:33,152 INFO [Configuration] processing association property references
          13:06:33,152 INFO [Configuration] processing foreign key constraints
          13:06:33,172 INFO [Configuration] processing extends queue
          13:06:33,172 INFO [Configuration] processing collection mappings
          13:06:33,172 INFO [Configuration] processing association property references
          13:06:33,172 INFO [Configuration] processing foreign key constraints
          13:06:33,172 INFO [NamingHelper] JNDI InitialContext properties:{}
          13:06:33,172 INFO [DatasourceConnectionProvider] Using datasource: java:/Defaul
          tDS
          13:06:33,172 INFO [SettingsFactory] RDBMS: HSQL Database Engine, version: 1.8.0
          
          13:06:33,172 INFO [SettingsFactory] JDBC driver: HSQL Database Engine Driver, v
          ersion: 1.8.0
          13:06:33,172 INFO [Dialect] Using dialect: org.hibernate.dialect.IngresDialect
          13:06:33,172 INFO [TransactionFactoryFactory] Using default transaction strateg
          y (direct JDBC transactions)
          13:06:33,172 INFO [TransactionManagerLookupFactory] instantiating TransactionMa
          nagerLookup: org.hibernate.transaction.JBossTransactionManagerLookup
          13:06:33,172 INFO [TransactionManagerLookupFactory] instantiated TransactionMan
          agerLookup
          13:06:33,172 INFO [SettingsFactory] Automatic flush during beforeCompletion():
          disabled
          13:06:33,172 INFO [SettingsFactory] Automatic session close at end of transacti
          on: disabled
          13:06:33,172 INFO [SettingsFactory] Scrollable result sets: enabled
          13:06:33,172 INFO [SettingsFactory] JDBC3 getGeneratedKeys(): disabled
          13:06:33,172 INFO [SettingsFactory] JDBC result set fetch size: 600
          13:06:33,172 INFO [SettingsFactory] Connection release mode: after_statement
          13:06:33,172 INFO [SettingsFactory] Default batch fetch size: 1
          13:06:33,172 INFO [SettingsFactory] Generate SQL with comments: disabled
          13:06:33,172 INFO [SettingsFactory] Order SQL updates by primary key: disabled
          13:06:33,172 INFO [SettingsFactory] Query translator: org.hibernate.hql.ast.AST
          QueryTranslatorFactory
          13:06:33,172 INFO [ASTQueryTranslatorFactory] Using ASTQueryTranslatorFactory
          13:06:33,172 INFO [SettingsFactory] Query language substitutions: {}
          13:06:33,172 INFO [SettingsFactory] Second-level cache: enabled
          13:06:33,172 INFO [SettingsFactory] Query cache: disabled
          13:06:33,172 INFO [SettingsFactory] Cache provider: org.hibernate.cache.Hashtab
          leCacheProvider
          13:06:33,172 INFO [SettingsFactory] Optimize cache for minimal puts: disabled
          13:06:33,172 INFO [SettingsFactory] Structured second-level cache entries: disa
          bled
          13:06:33,172 INFO [SettingsFactory] Statistics: disabled
          13:06:33,172 INFO [SettingsFactory] Deleted entity synthetic identifier rollbac
          k: enabled
          13:06:33,172 INFO [SettingsFactory] Default entity-mode: pojo
          13:06:33,182 INFO [SessionFactoryImpl] building session factory
          13:06:33,272 INFO [SessionFactoryObjectFactory] Not binding factory to JNDI, no
           JNDI name configured
          13:06:33,272 INFO [Dialect] Using dialect: org.hibernate.dialect.IngresDialect
          13:06:33,282 INFO [Configuration] processing extends queue
          13:06:33,282 INFO [Configuration] processing collection mappings
          13:06:33,282 INFO [Configuration] processing association property references
          13:06:33,282 INFO [Configuration] processing foreign key constraints
          13:06:33,282 INFO [Configuration] processing extends queue
          13:06:33,282 INFO [Configuration] processing collection mappings
          13:06:33,282 INFO [Configuration] processing association property references
          13:06:33,282 INFO [Configuration] processing foreign key constraints
          13:06:33,282 INFO [SchemaExport] Running hbm2ddl schema export
          13:06:33,282 INFO [SchemaExport] exporting generated schema to database
          13:06:33,282 INFO [NamingHelper] JNDI InitialContext properties:{}
          13:06:33,282 INFO [DatasourceConnectionProvider] Using datasource: java:/Defaul
          tDS
          13:06:33,282 ERROR [SchemaExport] Unsuccessful: create table PV_FAMIP (ident int
          eger4 not null, revision integer4, status integer4, anmeldung date, kennung varc
          har(255), referenz varchar(255), aenderDatum date, aenderName varchar(255), akte
          nzeichen varchar(255), anzahlFamilien integer4, anzahlFristen integer4, anzahlSt
          aemme integer4, aufrecht varchar(255), ausgabe date, bekanntmachung date, bekann
          tmachungArt varchar(255), bekanntmachungNummer varchar(255), beschluss51 date, e
          rfassDatum date, erfassName varchar(255), erteilung date, freigabe varchar(255),
           frist1 date, frist2 date, frist3 date, identNatph integer4, jgEintrag varchar(2
          55), kategorie1 varchar(255), kategorie2 varchar(255), kategorie3 varchar(255),
          kategorie4 varchar(255), kennungIdent integer4, land varchar(255), landIdent int
          eger4, lfdnr integer4, modulIdent integer4, natAnmeldung date, nationalePhase va
          rchar(255), offenlegung date, offenlegungArt varchar(255), offenlegungNummer var
          char(255), patentArt varchar(255), patentNummer varchar(255), pctAktenzeichen va
          rchar(255), prioritaet varchar(255), pruefungsAntrag varchar(255), pruefungsfris
          t date, prz varchar(255), przIdent integer4, reg516Erteilung date, regPatAn varc
          har(255), regPatNummer varchar(255), schlagwort varchar(255), sessionIdent integ
          er4, stammanmeldung varchar(255), technischeAbteilung varchar(255), uebersetzung
          Art varchar(255), uebersetzungNummer varchar(255), primary key (ident))
          13:06:33,282 ERROR [SchemaExport] Wrong data type: INTEGER4 in statement [create
           table PV_FAMIP (ident integer4]
          13:06:33,282 ERROR [SchemaExport] Unsuccessful: create table PV_STAMP (IDENT int
          eger4 not null, REVISION integer4, STATUS integer4, anmeldung date, KENNUNG varc
          har(255), REFERENZ varchar(255), AENDER_DATUM date, AENDER_NAME varchar(255), AK
          TENZEICHEN varchar(255), ANZAHL_FAMILIEN integer4, ANZAHL_FRISTEN integer4, ANZA
          HL_STAEMME integer4, AUFRECHT varchar(255), AUSGABE date, BEKANNTMACHUNG date, B
          EKANNTMACHUNG_ART varchar(255), BEKANNTMACHUNG_NUMMER varchar(255), BESCHLUSS_51
           date, ERFASS_DATUM date, ERFASS_NAME varchar(255), ERTEILUNG date, FREIGABE var
          char(255), FRIST1 date, FRIST2 date, FRIST3 date, IDENT_NATPH integer4, JG_EINTR
          AG varchar(255), KATEGORIE1 varchar(255), KATEGORIE2 varchar(255), KATEGORIE3 va
          rchar(255), KATEGORIE4 varchar(255), KENNUNG_IDENT integer4, LAND varchar(255),
          LAND_IDENT integer4, LFDNR integer4, MODUL_IDENT integer4, NAT_ANMELDUNG date, N
          ATIONALE_PHASE varchar(255), OFFENLEGUNG date, OFFENLEGUNG_ART varchar(255), OFF
          ENLEGUNG_NUMMER varchar(255), PATENT_ART varchar(255), PATENT_NUMMER varchar(255
          ), PCT_AKTENZEICHEN varchar(255), PRIORITAET varchar(255), PRUEFUNGSANTRAG varch
          ar(255), PRUEFUNGSFRIST date, PRZ varchar(255), PRZ_IDENT integer4, REG_51_6_ERT
          EILUNG date, REG_PAT_AN varchar(255), REG_PAT_NUMMER varchar(255), SCHLAGWORT va
          rchar(255), SESSION_IDENT integer4, STAMMANMELDUNG varchar(255), TECHNISCHE_ABTE
          ILUNG varchar(255), UEBERSETZUNG_ART varchar(255), UEBERSETZUNG_NUMMER varchar(2
          55), primary key (IDENT))
          13:06:33,282 ERROR [SchemaExport] Wrong data type: INTEGER4 in statement [create
           table PV_STAMP (IDENT integer4]
          13:06:33,282 INFO [SchemaExport] schema export complete
          13:06:33,282 INFO [Dialect] Using dialect: org.hibernate.dialect.IngresDialect
          13:06:33,282 INFO [Configuration] processing extends queue
          13:06:33,282 INFO [Configuration] processing collection mappings
          13:06:33,282 INFO [Configuration] processing association property references
          13:06:33,282 INFO [Configuration] processing foreign key constraints
          13:06:33,282 INFO [Configuration] processing extends queue
          13:06:33,582 INFO [Configuration] processing collection mappings
          13:06:33,582 INFO [Configuration] processing association property references
          13:06:33,582 INFO [Configuration] processing foreign key constraints
          13:06:33,592 INFO [NamingHelper] JNDI InitialContext properties:{}
          13:06:33,592 INFO [SessionFactoryImpl] Checking 0 named queries
          13:06:33,602 INFO [Ejb3Module] Create EntityManager with JNDI name: IngresManag
          er
          13:06:33,602 INFO [JaccHelper] JACC Policy Configuration for deployment has bee
          n put in service
          13:06:33,612 INFO [Ejb3Module] EJB3 deployment time took: 511
          13:06:33,632 INFO [ProxyDeployer] no declared remote bindings
          13:06:33,632 INFO [ProxyDeployer] there is remote interfaces
          13:06:33,642 INFO [ProxyDeployer] default remote binding has jndiName of ams.be
          ans.stateless.Akten
          13:06:33,652 INFO [EJB3Deployer] Deployed: file:/D:/jboss-4.0.3RC1/server/defau
          lt/tmp/deploy/tmp46470DipasNgHibernate.ear-contents/business.ejb3
          13:06:33,662 INFO [EJB3Deployer] Deployed: file:/D:/jboss-4.0.3RC1/server/defau
          lt/tmp/deploy/tmp46470DipasNgHibernate.ear-contents/entities.par
          13:06:33,672 INFO [TomcatDeployer] deploy, ctxPath=/DipasNgHibernate, warUrl=fi
          le:/D:/jboss-4.0.3RC1/server/default/tmp/deploy/tmp46470DipasNgHibernate.ear-con
          tents/web-exp.war/
          


          regards
          patrik

          • 2. Re: NameNotFoundException at context lookup
            Patrik Meisinger Newbie

            problem fixed:

            i declared the business interface "Akte" as @Remote and the stateless session bean implements the interface.

            a context lookup of the interface-class now works without troubles.

            regards
            patrik