• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Jeanne Boyarsky
  • Ron McLeod
  • Paul Clapham
  • Liutauras Vilda
Sheriffs:
  • paul wheaton
  • Rob Spoor
  • Devaka Cooray
Saloon Keepers:
  • Stephan van Hulst
  • Tim Holloway
  • Carey Brown
  • Frits Walraven
  • Tim Moores
Bartenders:
  • Mikalai Zaikin

Hi, why am I getting this exception on console

 
Ranch Hand
Posts: 242
Mac Java Ubuntu
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Output in console:

Buildfile: build.xml

prepare:
[mkdir] Created dir: H:\workbook\ex04_1\build
[mkdir] Created dir: H:\workbook\ex04_1\build\classes
[echo] It starts now

compile:
[echo] compilng starts here
[javac] Compiling 11 source files to H:\workbook\ex04_1\build\classes
[echo] compilng ends here

ejbjar:
[jar] Building jar: H:\workbook\ex04_1\build\titan.jar
[copy] Copying 1 file to H:\jboss\jboss-4.2.2.GA\jboss-4.2.2.GA\server\defa
ult\deploy

run.client_3:
[java] javax.naming.NameNotFoundException: TravelAgentRemote not bound
[java] at org.jnp.server.NamingServer.getBinding(NamingServer.java:529)

[java] at org.jnp.server.NamingServer.getBinding(NamingServer.java:537)

[java] at org.jnp.server.NamingServer.getObject(NamingServer.java:543)
[java] at org.jnp.server.NamingServer.lookup(NamingServer.java:296)
[java] at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
[java] at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAcces
sorImpl.java:39)
[java] at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMet
hodAccessorImpl.java:25)
[java] at java.lang.reflect.Method.invoke(Method.java:597)
[java] at sun.rmi.server.UnicastServerRef.dispatch(UnicastServerRef.jav
a:305)
[java] at sun.rmi.transport.Transport$1.run(Transport.java:159)
[java] at java.security.AccessController.doPrivileged(Native Method)
[java] at sun.rmi.transport.Transport.serviceCall(Transport.java:155)
[java] at sun.rmi.transport.tcp.TCPTransport.handleMessages(TCPTranspor
t.java:535)
[java] at sun.rmi.transport.tcp.TCPTransport$ConnectionHandler.run0(TCP
Transport.java:790)
[java] at sun.rmi.transport.tcp.TCPTransport$ConnectionHandler.run(TCPT
ransport.java:649)
[java] at java.util.concurrent.ThreadPoolExecutor$Worker.runTask(Thread
PoolExecutor.java:885)
[java] at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPool
Executor.java:907)
[java] at java.lang.Thread.run(Thread.java:619)
[java] at sun.rmi.transport.StreamRemoteCall.exceptionReceivedFromServe
r(StreamRemoteCall.java:255)
[java] at sun.rmi.transport.StreamRemoteCall.executeCall(StreamRemoteCa
ll.java:233)
[java] at sun.rmi.server.UnicastRef.invoke(UnicastRef.java:142)
[java] at org.jnp.server.NamingServer_Stub.lookup(Unknown Source)
[java] at org.jnp.interfaces.NamingContext.lookup(NamingContext.java:66
7)
[java] at org.jnp.interfaces.NamingContext.lookup(NamingContext.java:62
7)
[java] at javax.naming.InitialContext.lookup(InitialContext.java:392)
[java] at com.title.clients.Client_3.main(Client_3.java:17)

BUILD SUCCESSFUL
Total time: 8 seconds


My http://localhost:8080/jmx-console/HtmlAdaptor looks like this

Global JNDI Namespace
+- TravelAgentRemote (proxy: $Proxy91 implements interface com.title.travelagent.TravelAgentRemote,interface org.jboss.ejb3.JBossProxy)
+- TopicConnectionFactory (class: org.jboss.naming.LinkRefPair)
+- jmx (class: org.jnp.interfaces.NamingContext)
| +- invoker (class: org.jnp.interfaces.NamingContext)
| | +- RMIAdaptor (proxy: $Proxy47 implements interface org.jboss.jmx.adaptor.rmi.RMIAdaptor,interface org.jboss.jmx.adaptor.rmi.RMIAdaptorExt)
| +- rmi (class: org.jnp.interfaces.NamingContext)
| | +- RMIAdaptor[link -> jmx/invoker/RMIAdaptor] (class: javax.naming.LinkRef)
+- HTTPXAConnectionFactory (class: org.jboss.mq.SpyXAConnectionFactory)
+- TransactionPersistenceContextRemote (class: java.lang.Object)
+- ConnectionFactory (class: org.jboss.mq.SpyConnectionFactory)
+- ExtendedPersistenceContextRemoteStatefulProxyFactory (proxy: $Proxy76 implements interface org.jboss.ejb3.ProxyFactory)
+- UserTransactionSessionFactory (proxy: $Proxy14 implements interface org.jboss.tm.usertx.interfaces.UserTransactionSessionFactory)
+- HTTPConnectionFactory (class: org.jboss.mq.SpyConnectionFactory)
+- XAConnectionFactory (class: org.jboss.mq.SpyXAConnectionFactory)
+- TransactionSynchronizationRegistry (class: com.arjuna.ats.internal.jta.transaction.arjunacore.TransactionSynchronizationRegistryImple)
+- TransactionPersistenceContextRemoteStatefulProxyFactory (proxy: $Proxy76 implements interface org.jboss.ejb3.ProxyFactory)
+- UserTransaction (class: org.jboss.tm.usertx.client.ClientUserTransaction)
+- UILXAConnectionFactory[link -> XAConnectionFactory] (class: javax.naming.LinkRef)
+- ExtendedPersistenceContextRemote (class: java.lang.Object)
+- UIL2XAConnectionFactory[link -> XAConnectionFactory] (class: javax.naming.LinkRef)
+- persistence.units:jar=titan.jar,unitName=titan (class: org.hibernate.impl.SessionFactoryImpl)
+- queue (class: org.jnp.interfaces.NamingContext)
| +- A (class: org.jboss.mq.SpyQueue)
| +- testQueue (class: org.jboss.mq.SpyQueue)
| +- ex (class: org.jboss.mq.SpyQueue)
| +- DLQ (class: org.jboss.mq.SpyQueue)
| +- D (class: org.jboss.mq.SpyQueue)
| +- C (class: org.jboss.mq.SpyQueue)
| +- B (class: org.jboss.mq.SpyQueue)
+- topic (class: org.jnp.interfaces.NamingContext)
| +- testDurableTopic (class: org.jboss.mq.SpyTopic)
| +- testTopic (class: org.jboss.mq.SpyTopic)
| +- securedTopic (class: org.jboss.mq.SpyTopic)
+- console (class: org.jnp.interfaces.NamingContext)
| +- PluginManager (proxy: $Proxy48 implements interface org.jboss.console.manager.PluginManagerMBean)
+- UIL2ConnectionFactory[link -> ConnectionFactory] (class: javax.naming.LinkRef)
+- HiLoKeyGeneratorFactory (class: org.jboss.ejb.plugins.keygenerator.hilo.HiLoKeyGeneratorFactory)
+- UILConnectionFactory[link -> ConnectionFactory] (class: javax.naming.LinkRef)
+- QueueConnectionFactory (class: org.jboss.naming.LinkRefPair)
+- UUIDKeyGeneratorFactory (class: org.jboss.ejb.plugins.keygenerator.uuid.UUIDKeyGeneratorFactory)



My Client Class is like this:



My Bean class is like this:



My Remote interface is like this:


My persistence.xml looks like this:


My jboss.xml is like this:


And my titan.ear folder structure is like this:

titan
|--META-INF
| |- persistence.xml
| |- jboss.xml
|
|- class files with proper pckg structure



Rest things are set in class path via an ant file

Please let me know..
 
Greenhorn
Posts: 29
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
place jboss.xml in your ejb-jar like jboss.xml

 
khushhal yadav
Ranch Hand
Posts: 242
Mac Java Ubuntu
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Thanks a lot Ram, it's working now..
 
Morning came much too soon and it brought along a friend named Margarita Hangover, and a tiny ad.
a bit of art, as a gift, the permaculture playing cards
https://gardener-gift.com
reply
    Bookmark Topic Watch Topic
  • New Topic