Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Eclipse Projects » Equinox » Jetty Configuration
Jetty Configuration [message #97106] Tue, 11 September 2007 19:19 Go to next message
Eclipse UserFriend
Originally posted by: irbull.cs.uvic.ca

Does anyone have any pointers for howto configure Jetty running as an
Equinox bundle? In particular, I would like to setup something like
apache's document index (that is, when I navigate to a directory I can
get it to automatically use index.html).

Can these be configured using an external file (configuration.xml or
something) or do they have to be coded against the Jetty API (or using
extension points?).

Any help is appreciated.

Cheers,
Ian
Re: Jetty Configuration [message #97122 is a reply to message #97106] Tue, 11 September 2007 23:14 Go to previous messageGo to next message
Eclipse UserFriend
Originally posted by: kitplummer.gmail.com

Have you seen this:

http://www.eclipse.org/equinox/server/http_in_equinox.php

I've not been able to get 6.1.5 to work...complains about javax.servlet
which is a bit strange. But, I have this stuff working:

http://www.eclipse.org/equinox/server/http_writing_applicati on.php

Both the static page, and the servlet.

Kit

On 9/11/07 12:19 PM, in article fc6po0$t26$1@build.eclipse.org, "Ian Bull"
<irbull@cs.uvic.ca> wrote:

> Does anyone have any pointers for howto configure Jetty running as an
> Equinox bundle? In particular, I would like to setup something like
> apache's document index (that is, when I navigate to a directory I can
> get it to automatically use index.html).
>
> Can these be configured using an external file (configuration.xml or
> something) or do they have to be coded against the Jetty API (or using
> extension points?).
>
> Any help is appreciated.
>
> Cheers,
> Ian
Re: Jetty Configuration [message #97135 is a reply to message #97106] Tue, 11 September 2007 23:16 Go to previous messageGo to next message
Eclipse UserFriend
Originally posted by: kitplummer.gmail.com

Oh yeh, I also was going to tell that most of the Jetty config can be passed
as VM args: -Dorg.eclipse.equinox.http.jetty.http.port=8080



On 9/11/07 12:19 PM, in article fc6po0$t26$1@build.eclipse.org, "Ian Bull"
<irbull@cs.uvic.ca> wrote:

> Does anyone have any pointers for howto configure Jetty running as an
> Equinox bundle? In particular, I would like to setup something like
> apache's document index (that is, when I navigate to a directory I can
> get it to automatically use index.html).
>
> Can these be configured using an external file (configuration.xml or
> something) or do they have to be coded against the Jetty API (or using
> extension points?).
>
> Any help is appreciated.
>
> Cheers,
> Ian
Re: Jetty Configuration [message #97424 is a reply to message #97106] Fri, 14 September 2007 01:29 Go to previous messageGo to next message
Simon Kaegi is currently offline Simon KaegiFriend
Messages: 381
Registered: July 2009
Senior Member
Hi Ian,

In addition to Kit's suggestions you might want to take a look at
"org.eclipse.equinox.http.jetty.JettyConfigurator"
This lets you create you programmatically configure your own instance of the
Http Service based on Jetty. This is the approach used by UA/Help and WTP.

The Http Service unfortunately does not provide direct support for mapping
requests for a directory to "index.html".
What you can do is register a servlet at the directory path and then either
requestDispatcher.forward the request or something similar.
There's a bug open on that particular topic also --
https://bugs.eclipse.org/bugs/show_bug.cgi?id=193202

HTH
-Simon

"Ian Bull" <irbull@cs.uvic.ca> wrote in message
news:fc6po0$t26$1@build.eclipse.org...
> Does anyone have any pointers for howto configure Jetty running as an
> Equinox bundle? In particular, I would like to setup something like
> apache's document index (that is, when I navigate to a directory I can get
> it to automatically use index.html).
>
> Can these be configured using an external file (configuration.xml or
> something) or do they have to be coded against the Jetty API (or using
> extension points?).
>
> Any help is appreciated.
>
> Cheers,
> Ian
Re: Jetty Configuration [message #97529 is a reply to message #97424] Mon, 17 September 2007 18:48 Go to previous message
Eclipse UserFriend
Originally posted by: irbull.cs.uvic.ca

Thanks Kit and Simon,

I was able to map a servlet a "/", and then forward to index.html. The
problem is, the forward is picked up by the servlet again (since
/index.html get picked up by "/"), so I get an infinite number of
redirects. Is there a way to forward to a resource alias from a serlvet
programmatically (without forwarding to any servlet aliases?

Thanks again,
Ian


Simon Kaegi wrote:
> Hi Ian,
>
> In addition to Kit's suggestions you might want to take a look at
> "org.eclipse.equinox.http.jetty.JettyConfigurator"
> This lets you create you programmatically configure your own instance of the
> Http Service based on Jetty. This is the approach used by UA/Help and WTP.
>
> The Http Service unfortunately does not provide direct support for mapping
> requests for a directory to "index.html".
> What you can do is register a servlet at the directory path and then either
> requestDispatcher.forward the request or something similar.
> There's a bug open on that particular topic also --
> https://bugs.eclipse.org/bugs/show_bug.cgi?id=193202
>
> HTH
> -Simon
>
> "Ian Bull" <irbull@cs.uvic.ca> wrote in message
> news:fc6po0$t26$1@build.eclipse.org...
>> Does anyone have any pointers for howto configure Jetty running as an
>> Equinox bundle? In particular, I would like to setup something like
>> apache's document index (that is, when I navigate to a directory I can get
>> it to automatically use index.html).
>>
>> Can these be configured using an external file (configuration.xml or
>> something) or do they have to be coded against the Jetty API (or using
>> extension points?).
>>
>> Any help is appreciated.
>>
>> Cheers,
>> Ian
>
>
Previous Topic:Extension-Registry as OSGi Services
Next Topic:OSGi Plugin Deployment
Goto Forum:
  


Current Time: Fri Apr 26 22:47:47 GMT 2024

Powered by FUDForum. Page generated in 0.02800 seconds
.:: Contact :: Home ::.

Powered by: FUDforum 3.0.2.
Copyright ©2001-2010 FUDforum Bulletin Board Software

Back to the top