tomcat-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Tim Tye" <tt...@ticnet.com>
Subject Re: Strange problem with URL_PKG_PREFIXES
Date Wed, 14 Mar 2001 03:51:39 GMT
According to NamingManager documentation, first it will look for
'org.jnp.interfaces.java.javaURLContextFactory' which does not exist, so it
should next look for 'org.apache.naming.java.javaURLContextFactory' which
does exist.
So, this should work.
BTW, the 'org.apache.naming' prefix is concatenated onto the URL prefixes by
jakarta.  Also, when the jnp.jar is removed, it still fails with the same
error.
How can this be made to work?

----- Original Message -----
From: Remy Maucherat <remm@apache.org>
To: <tomcat-dev@jakarta.apache.org>
Sent: Tuesday, March 13, 2001 5:49 PM
Subject: Re: Strange problem with URL_PKG_PREFIXES


> > The Context.URL_PKG_PREFIXES environment variable is a colon-seperated
> list
> > of package prefixes.  However, when I set this environment variable to
> > "org.jnp.interfaces:org.apache.naming" and attempt to get a Context;
> >   Context ctx = new InitialContext().lookup("java:/comp");
> > The lookup fails with:
> > javax.naming.ConfigurationException: Provider URL missing
> >     at org.jnp.interfaces.NamingContext.checkRef(NamingContext.java:702)
>
> > However, when I set this environment variable to
> > "org.apache.naming:org.jnp.interfaces"
> > The lookup succeeds!
> > "org.jnp.interfaces" only contains one class and that is
> > "org.jnp.interfaces.jnp.jnpURLContextFactory".
> > It seems to me that the lookup code is not correctly parsing the
> > Context.URL_PKG_PREFIXES environment variable.
>
> It looks like the JNP InitialContext has a custom way to retrieve URL
> contexts.
> It's supposed to call NamingManager.getURLContext (see the
> javax.naming.InitialContext source code for more details).
>
> Remy
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: tomcat-dev-unsubscribe@jakarta.apache.org
> For additional commands, email: tomcat-dev-help@jakarta.apache.org
>
>


---------------------------------------------------------------------
To unsubscribe, e-mail: tomcat-dev-unsubscribe@jakarta.apache.org
For additional commands, email: tomcat-dev-help@jakarta.apache.org


Mime
View raw message