This is how I had to embed it. It took me a while to find this
solution. Hope it helps. Our application uses it own classloaders.
try {
URL jettyConfig = new URL("file:web/etc/jetty.xml");
if (jettyConfig == null) {
log.fatal(
"Unable to locate jetty.xml ");
}
ClassLoader savecl =
Thread.currentThread().getContextClassLoader();
Thread.currentThread().setContextClassLoader(Web.class.getClassLoader())
;
server = new Server(jettyConfig);
server.start();
Thread.currentThread().setContextClassLoader(savecl);
} catch (Exception e) {
log.fatal("Could not start the Jetty server: " + e);
if (server != null) {
try {
server.stop();
} catch (InterruptedException e1) {
log.fatal("Unable to stop the jetty server: " + e1);
}
}
}
-----Original Message-----
From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]
Sent: Tuesday, May 09, 2006 11:20 AM
To: [email protected]
Subject: Re: [xfire-user] Any success stories with embedding?
Where can I read about this? I didn't see any reference to jetty in the
XFire
documentation? I'd like to study just what is involved if I want to
embed XFire
with jetty in this data server.
Quoting Dan Diephouse <[EMAIL PROTECTED]>:
> Robert Nicholson wrote:
> > Are there any success stories embedding the HTTP server?
> >
> > I'm looking for a solution to replace a web service that currently
> > provides a SOAP interface to an existing CORBA based caching data
> > server. Currently we have a websphere web service act as a proxy to
> > the CORBA data server. As we're moving to JDK 1.5 I'm thinking it
may
> > be possible to embed the webservice directly into the data server.
> >
> > This data server already acts as a client using Axis stubs. Can
xfire
> > coexst with axis on the classpath?
> >
> Yes Axis can coexist. Also, the embedded HTTP server just uses Jetty
> with the XFire servlet and that type of situation has been widely
> deployed already.
>
> Cheers,
> - Dan
>
> --
> Dan Diephouse
> Envoi Solutions
> http://envoisolutions.com
> http://netzooid.com/blog
>
>
----------------------------------------------------------------
This message was sent using IMP, the Internet Messaging Program.