Hi Janko, Thanks for your quick response. I changed the lookup as you suggested in option 1, but I still have the exception (except it now tells it cannot find system-info). Any more ideas or things to check ?
Kind regards, Marco Janko Heilgeist-3 wrote: > > Hi Marco, > > the line "<ref-name>system-info</ref-name>" defines the local name of > the ServerInfo object in the context of your WAR. Therefore, you can > either > > 1) keep the ref-name and try to lookup "java:comp/env/system-info", or > > 2) keep the lookup and change the line in geronimo-web.xml to > <ref-name>ServerInfo</ref-name>. > > I hope I could help you! > > Regards, Janko > > > MarcoLaponder wrote: >> I am trying to get some information for the ServerInfo object, i have >> added >> the gbean to my geronimo-web.xml: >> >> <web-app xmlns="http://geronimo.apache.org/xml/ns/j2ee/web-1.1"> >> <context-root>/navi</context-root> >> <gbean-ref> >> <ref-name>system-info</ref-name> >> >> <ref-type>org.apache.geronimo.system.serverinfo.ServerInfo</ref-type> >> <pattern> >> <name>ServerInfo</name> >> </pattern> >> </gbean-ref> >> </web-app> >> >> and a try to get a handle of the serverinfo in my servlet by: >> >> serverInfo = (ServerInfo)(new >> InitialContext().lookup("java:comp/env/ServerInfo")); >> >> but this throws a NameNotFoundException. >> >> What am I doing wrong in the situation above ? >> >> Kind regards, >> Marco Laponder > > > -- View this message in context: http://www.nabble.com/cannot-find-serverinfo-jndi-lookup-tp16646510s134p16648695.html Sent from the Apache Geronimo - Users mailing list archive at Nabble.com.
