users@glassfish.java.net

Re: Glassfish V3 Standalone JMS Client - Question

From: Alexis Moussine-Pouchkine <alexis.mp_at_sun.com>
Date: Thu, 20 May 2010 23:41:50 +0200

yes, appserv-rt.jar is there for compatibility with v2.
gf-client.jar is the way to go with v3.x.
-Alexis

On 20 mai 2010, at 22:22, Antonio Goncalves wrote:

> I found how to make it work. I was in the wrong direction with the appserv-rt.jar. The needed file is the gf-client.jar
>
> <dependency>
> <groupId>org.glassfish.appclient</groupId>
> <artifactId>gf-client</artifactId>
> <version> 3.0.1-b19 </version>
> </dependency>
>
> Antonio
>
> 2010/5/20 Antonio Goncalves <antonio.mailing_at_gmail.com>
> Hi all,
>
> I'm using this post as I have the same problem. I'm using the latest GlassFish 3.0.1-b19 promoted build and want to access JMS connection factory and destination using a standalone JMS client. I don't want to use the appclient (ACC) and need to do JNDI lookups. I'm also using Maven. In my pom.xml I've added :
>
> <dependency>
> <groupId>org.glassfish.extras</groupId>
> <artifactId>appserv-rt</artifactId>
> <version>3.0.1-b19</version>
> </dependency>
>
> It brings me a 3Kb jar file with no class nor jndi.properties file.
>
> Is there an easy way (with Maven) to have the needed JNDI classes and config files to do a JNDI lookup ?
>
> Thanks,
> Antonio
>
> 2010/1/6 <glassfish_at_javadesktop.org>
>
> I've removed 100% of the jars, and 100% of the code aside from my ejb lookup.
> The only jar that I am including right now is <strong>appserv-rt.jar</strong> plus, my ejb interfaces.
>
> When I attempt to invoke the bean (By the portable jndi name now..
> http://blogs.sun.com/MaheshKannan/entry/portable_global_jndi_names
> )
>
> I receive this exception:
> [code]
> javax.naming.NoInitialContextException: Need to specify class name in environment or system property, or as an applet parameter, or as an application resource file: java.naming.factory.initial
> [/code]
>
> When I saw that exception (java.naming.factory.initial) I located the jndi.properties file, and I added it to the classpath. However, numerous run time errors ensued. I was able to correct them by adding more and more jar files, to the point of which I received a new exception (detailed below).
>
> Is there a better way to fix this without adding jars so that I can reach an ejb?
> [Message sent by forum member 'hoffman462' (HoffmanDanielG_at_comcast.net)]
>
> http://forums.java.net/jive/thread.jspa?messageID=379101
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscribe_at_glassfish.dev.java.net
> For additional commands, e-mail: users-help_at_glassfish.dev.java.net
>
>
>
>
> --
> --
> Antonio Goncalves (antonio.goncalves_at_gmail.com)
> Software architect
>
> Web site : www.antoniogoncalves.org
> Blog: agoncal.wordpress.com
> Feed: feeds2.feedburner.com/AntonioGoncalves
> Paris JUG leader : www.parisjug.org
> LinkedIn: www.linkedin.com/in/agoncal
>
>
>
> --
> --
> Antonio Goncalves (antonio.goncalves_at_gmail.com)
> Software architect
>
> Web site : www.antoniogoncalves.org
> Blog: agoncal.wordpress.com
> Feed: feeds2.feedburner.com/AntonioGoncalves
> Paris JUG leader : www.parisjug.org
> LinkedIn: www.linkedin.com/in/agoncal