You are viewing a plain text version of this content. The canonical link for it is here.
Posted to soap-user@ws.apache.org by Fergus O'Dalaigh <Fe...@netscape.net> on 2002/11/14 09:40:40 UTC
Unable to initialize context error with EJB on IPlanet (iAS 6.0)
Hi, I've deployed normal Java classes as services on the SOAP web app, but I really need to use EJB's as services.
I'm using iAS 6.0 (iPlanet Application Server) and SOAP 2.3.1.
I get a "Unable to initialize context" error when I run my SOAP client.
Here is my SOAP deployment descriptor:
<?xml version="1.0"?>
<isd:service xmlns:isd="http://xml.apache.org/xml-soap/deployment"
id="urn:ejbhello">
<isd:provider type="org.apache.soap.providers.StatelessEJBProvider"
scope="Application"
methods="create">
<isd:option key="JNDIName" value="TheGreeter"/>
<isd:option key="FullHomeInterfaceName"
value="samples.helloworld.ejb.GreeterHome" />
<isd:option key="ContextProviderURL"value="iiop://localhost:900" />
<isd:option key="FullContextFactoryName"
value="com.sun.jndi.cosnaming.CNCtxFactory"/>
</isd:provider>
<isd:faultListener>org.apache.soap.server.DOMFaultListener
</isd:faultListener>
</isd:service>
I think the problem lies with value of ContextProviderURL, since I couldn't track down the actual naming provider URL to use with IPlanet.
The EJB is deployed and working on the server.
I also copied the EJB jar file <ias home>/APPS/modules/soap/WEB-INF/lib
Has anyone out there managed to do this?
Fergus, Barcelona Spain.
__________________________________________________________________
The NEW Netscape 7.0 browser is now available. Upgrade now! http://channels.netscape.com/ns/browsers/download.jsp
Get your own FREE, personal Netscape Mail account today at http://webmail.netscape.com/
Re: Unable to initialize context error with EJB on IPlanet (iAS 6.0)
Posted by Raghavan Srinivasan <ra...@iplanet.com>.
one way would be to tweak
org/apache/soap/providers/StatelessEJBProvider.java to use the
following mechanism to create the InitialContext . iAS 6.0 supports the
"no args" mechanism of creating the IntitialContext inside the container .
try
{
/// current mechanism
javax.naming.InitialContext context = new
javax.naming.InitialContext(props) ;
}
catch (NameNotFoundException e)
{
context = new javax.naming.InitialContext() ; // no args .
}
-Raghavan
Fergus O'Dalaigh wrote:
>Hi, I've deployed normal Java classes as services on the SOAP web app, but I really need to use EJB's as services.
>
>I'm using iAS 6.0 (iPlanet Application Server) and SOAP 2.3.1.
>
>I get a "Unable to initialize context" error when I run my SOAP client.
>Here is my SOAP deployment descriptor:
>
><?xml version="1.0"?>
><isd:service xmlns:isd="http://xml.apache.org/xml-soap/deployment"
> id="urn:ejbhello">
> <isd:provider type="org.apache.soap.providers.StatelessEJBProvider"
> scope="Application"
> methods="create">
> <isd:option key="JNDIName" value="TheGreeter"/>
> <isd:option key="FullHomeInterfaceName"
> value="samples.helloworld.ejb.GreeterHome" />
> <isd:option key="ContextProviderURL"value="iiop://localhost:900" />
> <isd:option key="FullContextFactoryName"
> value="com.sun.jndi.cosnaming.CNCtxFactory"/>
> </isd:provider>
><isd:faultListener>org.apache.soap.server.DOMFaultListener
></isd:faultListener>
></isd:service>
>
>I think the problem lies with value of ContextProviderURL, since I couldn't track down the actual naming provider URL to use with IPlanet.
>
>The EJB is deployed and working on the server.
>I also copied the EJB jar file <ias home>/APPS/modules/soap/WEB-INF/lib
>
>Has anyone out there managed to do this?
>
>Fergus, Barcelona Spain.
>
>
>
>__________________________________________________________________
>The NEW Netscape 7.0 browser is now available. Upgrade now! http://channels.netscape.com/ns/browsers/download.jsp
>
>Get your own FREE, personal Netscape Mail account today at http://webmail.netscape.com/
>
>--
>To unsubscribe, e-mail: <ma...@xml.apache.org>
>For additional commands, e-mail: <ma...@xml.apache.org>
>
>
>
--
To unsubscribe, e-mail: <ma...@xml.apache.org>
For additional commands, e-mail: <ma...@xml.apache.org>
Re: Unable to initialize context error with EJB on IPlanet (iAS 6.0)
Posted by Raghavan Srinivasan <ra...@iplanet.com>.
one way would be to tweak
org/apache/soap/providers/StatelessEJBProvider.java to use the
following mechanism to create the InitialContext . iAS 6.0 supports the
"no args" mechanism of creating the IntitialContext inside the container .
try
{
/// current mechanism
javax.naming.InitialContext context = new
javax.naming.InitialContext(props) ;
}
catch (NameNotFoundException e)
{
context = new javax.naming.InitialContext() ; // no args .
}
-Raghavan
Fergus O'Dalaigh wrote:
>Hi, I've deployed normal Java classes as services on the SOAP web app, but I really need to use EJB's as services.
>
>I'm using iAS 6.0 (iPlanet Application Server) and SOAP 2.3.1.
>
>I get a "Unable to initialize context" error when I run my SOAP client.
>Here is my SOAP deployment descriptor:
>
><?xml version="1.0"?>
><isd:service xmlns:isd="http://xml.apache.org/xml-soap/deployment"
> id="urn:ejbhello">
> <isd:provider type="org.apache.soap.providers.StatelessEJBProvider"
> scope="Application"
> methods="create">
> <isd:option key="JNDIName" value="TheGreeter"/>
> <isd:option key="FullHomeInterfaceName"
> value="samples.helloworld.ejb.GreeterHome" />
> <isd:option key="ContextProviderURL"value="iiop://localhost:900" />
> <isd:option key="FullContextFactoryName"
> value="com.sun.jndi.cosnaming.CNCtxFactory"/>
> </isd:provider>
><isd:faultListener>org.apache.soap.server.DOMFaultListener
></isd:faultListener>
></isd:service>
>
>I think the problem lies with value of ContextProviderURL, since I couldn't track down the actual naming provider URL to use with IPlanet.
>
>The EJB is deployed and working on the server.
>I also copied the EJB jar file <ias home>/APPS/modules/soap/WEB-INF/lib
>
>Has anyone out there managed to do this?
>
>Fergus, Barcelona Spain.
>
>
>
>__________________________________________________________________
>The NEW Netscape 7.0 browser is now available. Upgrade now! http://channels.netscape.com/ns/browsers/download.jsp
>
>Get your own FREE, personal Netscape Mail account today at http://webmail.netscape.com/
>
>--
>To unsubscribe, e-mail: <ma...@xml.apache.org>
>For additional commands, e-mail: <ma...@xml.apache.org>
>
>
>
Re: Unable to initialize context error with EJB on IPlanet (iAS 6.0)
Posted by Scott Nichol <sn...@scottnichol.com>.
Actually, here it is:
http://developer.iplanet.com/appserver/samples/helloworld_soap/docs/inde
x.html.
Scott Nichol
----- Original Message -----
From: "Scott Nichol" <sn...@scottnichol.com>
To: <so...@xml.apache.org>
Sent: Thursday, November 14, 2002 6:05 PM
Subject: Re: Unable to initialize context error with EJB on IPlanet (iAS
6.0)
> Here's a Sun iPlanet sample description. At the bottom, I notice that
> ContextProviderURL is left blank.
>
> Scott Nichol
> ----- Original Message -----
> From: "Fergus O'Dalaigh" <Fe...@netscape.net>
> To: <so...@xml.apache.org>
> Sent: Thursday, November 14, 2002 3:40 AM
> Subject: Unable to initialize context error with EJB on IPlanet (iAS
> 6.0)
>
>
> > Hi, I've deployed normal Java classes as services on the SOAP web
app,
> but I really need to use EJB's as services.
> >
> > I'm using iAS 6.0 (iPlanet Application Server) and SOAP 2.3.1.
> >
> > I get a "Unable to initialize context" error when I run my SOAP
> client.
> > Here is my SOAP deployment descriptor:
> >
> > <?xml version="1.0"?>
> > <isd:service xmlns:isd="http://xml.apache.org/xml-soap/deployment"
> > id="urn:ejbhello">
> > <isd:provider type="org.apache.soap.providers.StatelessEJBProvider"
> > scope="Application"
> > methods="create">
> > <isd:option key="JNDIName" value="TheGreeter"/>
> > <isd:option key="FullHomeInterfaceName"
> > value="samples.helloworld.ejb.GreeterHome" />
> > <isd:option key="ContextProviderURL"value="iiop://localhost:900"
/>
> > <isd:option key="FullContextFactoryName"
> > value="com.sun.jndi.cosnaming.CNCtxFactory"/>
> > </isd:provider>
> > <isd:faultListener>org.apache.soap.server.DOMFaultListener
> > </isd:faultListener>
> > </isd:service>
> >
> > I think the problem lies with value of ContextProviderURL, since I
> couldn't track down the actual naming provider URL to use with
IPlanet.
> >
> > The EJB is deployed and working on the server.
> > I also copied the EJB jar file <ias
> home>/APPS/modules/soap/WEB-INF/lib
> >
> > Has anyone out there managed to do this?
> >
> > Fergus, Barcelona Spain.
> >
> >
> >
> > __________________________________________________________________
> > The NEW Netscape 7.0 browser is now available. Upgrade now!
> http://channels.netscape.com/ns/browsers/download.jsp
> >
> > Get your own FREE, personal Netscape Mail account today at
> http://webmail.netscape.com/
> >
> > --
> > To unsubscribe, e-mail:
> <ma...@xml.apache.org>
> > For additional commands, e-mail:
> <ma...@xml.apache.org>
> >
> >
>
>
> --
> To unsubscribe, e-mail:
<ma...@xml.apache.org>
> For additional commands, e-mail:
<ma...@xml.apache.org>
>
>
--
To unsubscribe, e-mail: <ma...@xml.apache.org>
For additional commands, e-mail: <ma...@xml.apache.org>
Re: Unable to initialize context error with EJB on IPlanet (iAS 6.0)
Posted by Scott Nichol <sn...@scottnichol.com>.
Actually, here it is:
http://developer.iplanet.com/appserver/samples/helloworld_soap/docs/inde
x.html.
Scott Nichol
----- Original Message -----
From: "Scott Nichol" <sn...@scottnichol.com>
To: <so...@xml.apache.org>
Sent: Thursday, November 14, 2002 6:05 PM
Subject: Re: Unable to initialize context error with EJB on IPlanet (iAS
6.0)
> Here's a Sun iPlanet sample description. At the bottom, I notice that
> ContextProviderURL is left blank.
>
> Scott Nichol
> ----- Original Message -----
> From: "Fergus O'Dalaigh" <Fe...@netscape.net>
> To: <so...@xml.apache.org>
> Sent: Thursday, November 14, 2002 3:40 AM
> Subject: Unable to initialize context error with EJB on IPlanet (iAS
> 6.0)
>
>
> > Hi, I've deployed normal Java classes as services on the SOAP web
app,
> but I really need to use EJB's as services.
> >
> > I'm using iAS 6.0 (iPlanet Application Server) and SOAP 2.3.1.
> >
> > I get a "Unable to initialize context" error when I run my SOAP
> client.
> > Here is my SOAP deployment descriptor:
> >
> > <?xml version="1.0"?>
> > <isd:service xmlns:isd="http://xml.apache.org/xml-soap/deployment"
> > id="urn:ejbhello">
> > <isd:provider type="org.apache.soap.providers.StatelessEJBProvider"
> > scope="Application"
> > methods="create">
> > <isd:option key="JNDIName" value="TheGreeter"/>
> > <isd:option key="FullHomeInterfaceName"
> > value="samples.helloworld.ejb.GreeterHome" />
> > <isd:option key="ContextProviderURL"value="iiop://localhost:900"
/>
> > <isd:option key="FullContextFactoryName"
> > value="com.sun.jndi.cosnaming.CNCtxFactory"/>
> > </isd:provider>
> > <isd:faultListener>org.apache.soap.server.DOMFaultListener
> > </isd:faultListener>
> > </isd:service>
> >
> > I think the problem lies with value of ContextProviderURL, since I
> couldn't track down the actual naming provider URL to use with
IPlanet.
> >
> > The EJB is deployed and working on the server.
> > I also copied the EJB jar file <ias
> home>/APPS/modules/soap/WEB-INF/lib
> >
> > Has anyone out there managed to do this?
> >
> > Fergus, Barcelona Spain.
> >
> >
> >
> > __________________________________________________________________
> > The NEW Netscape 7.0 browser is now available. Upgrade now!
> http://channels.netscape.com/ns/browsers/download.jsp
> >
> > Get your own FREE, personal Netscape Mail account today at
> http://webmail.netscape.com/
> >
> > --
> > To unsubscribe, e-mail:
> <ma...@xml.apache.org>
> > For additional commands, e-mail:
> <ma...@xml.apache.org>
> >
> >
>
>
> --
> To unsubscribe, e-mail:
<ma...@xml.apache.org>
> For additional commands, e-mail:
<ma...@xml.apache.org>
>
>
Re: Unable to initialize context error with EJB on IPlanet (iAS 6.0)
Posted by Scott Nichol <sn...@scottnichol.com>.
Here's a Sun iPlanet sample description. At the bottom, I notice that
ContextProviderURL is left blank.
Scott Nichol
----- Original Message -----
From: "Fergus O'Dalaigh" <Fe...@netscape.net>
To: <so...@xml.apache.org>
Sent: Thursday, November 14, 2002 3:40 AM
Subject: Unable to initialize context error with EJB on IPlanet (iAS
6.0)
> Hi, I've deployed normal Java classes as services on the SOAP web app,
but I really need to use EJB's as services.
>
> I'm using iAS 6.0 (iPlanet Application Server) and SOAP 2.3.1.
>
> I get a "Unable to initialize context" error when I run my SOAP
client.
> Here is my SOAP deployment descriptor:
>
> <?xml version="1.0"?>
> <isd:service xmlns:isd="http://xml.apache.org/xml-soap/deployment"
> id="urn:ejbhello">
> <isd:provider type="org.apache.soap.providers.StatelessEJBProvider"
> scope="Application"
> methods="create">
> <isd:option key="JNDIName" value="TheGreeter"/>
> <isd:option key="FullHomeInterfaceName"
> value="samples.helloworld.ejb.GreeterHome" />
> <isd:option key="ContextProviderURL"value="iiop://localhost:900" />
> <isd:option key="FullContextFactoryName"
> value="com.sun.jndi.cosnaming.CNCtxFactory"/>
> </isd:provider>
> <isd:faultListener>org.apache.soap.server.DOMFaultListener
> </isd:faultListener>
> </isd:service>
>
> I think the problem lies with value of ContextProviderURL, since I
couldn't track down the actual naming provider URL to use with IPlanet.
>
> The EJB is deployed and working on the server.
> I also copied the EJB jar file <ias
home>/APPS/modules/soap/WEB-INF/lib
>
> Has anyone out there managed to do this?
>
> Fergus, Barcelona Spain.
>
>
>
> __________________________________________________________________
> The NEW Netscape 7.0 browser is now available. Upgrade now!
http://channels.netscape.com/ns/browsers/download.jsp
>
> Get your own FREE, personal Netscape Mail account today at
http://webmail.netscape.com/
>
> --
> To unsubscribe, e-mail:
<ma...@xml.apache.org>
> For additional commands, e-mail:
<ma...@xml.apache.org>
>
>
--
To unsubscribe, e-mail: <ma...@xml.apache.org>
For additional commands, e-mail: <ma...@xml.apache.org>
Re: Unable to initialize context error with EJB on IPlanet (iAS 6.0)
Posted by Scott Nichol <sn...@scottnichol.com>.
Here's a Sun iPlanet sample description. At the bottom, I notice that
ContextProviderURL is left blank.
Scott Nichol
----- Original Message -----
From: "Fergus O'Dalaigh" <Fe...@netscape.net>
To: <so...@xml.apache.org>
Sent: Thursday, November 14, 2002 3:40 AM
Subject: Unable to initialize context error with EJB on IPlanet (iAS
6.0)
> Hi, I've deployed normal Java classes as services on the SOAP web app,
but I really need to use EJB's as services.
>
> I'm using iAS 6.0 (iPlanet Application Server) and SOAP 2.3.1.
>
> I get a "Unable to initialize context" error when I run my SOAP
client.
> Here is my SOAP deployment descriptor:
>
> <?xml version="1.0"?>
> <isd:service xmlns:isd="http://xml.apache.org/xml-soap/deployment"
> id="urn:ejbhello">
> <isd:provider type="org.apache.soap.providers.StatelessEJBProvider"
> scope="Application"
> methods="create">
> <isd:option key="JNDIName" value="TheGreeter"/>
> <isd:option key="FullHomeInterfaceName"
> value="samples.helloworld.ejb.GreeterHome" />
> <isd:option key="ContextProviderURL"value="iiop://localhost:900" />
> <isd:option key="FullContextFactoryName"
> value="com.sun.jndi.cosnaming.CNCtxFactory"/>
> </isd:provider>
> <isd:faultListener>org.apache.soap.server.DOMFaultListener
> </isd:faultListener>
> </isd:service>
>
> I think the problem lies with value of ContextProviderURL, since I
couldn't track down the actual naming provider URL to use with IPlanet.
>
> The EJB is deployed and working on the server.
> I also copied the EJB jar file <ias
home>/APPS/modules/soap/WEB-INF/lib
>
> Has anyone out there managed to do this?
>
> Fergus, Barcelona Spain.
>
>
>
> __________________________________________________________________
> The NEW Netscape 7.0 browser is now available. Upgrade now!
http://channels.netscape.com/ns/browsers/download.jsp
>
> Get your own FREE, personal Netscape Mail account today at
http://webmail.netscape.com/
>
> --
> To unsubscribe, e-mail:
<ma...@xml.apache.org>
> For additional commands, e-mail:
<ma...@xml.apache.org>
>
>