Skip to main content

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [List Home]
Re: [jetty-users] Upgrade jetty 8.1.3.v20120416 to 9.3.x


On Tue, Jan 31, 2017 at 7:59 AM, Tharindu Munasinghe
<munasinghetharindu@xxxxxxxxx> wrote:
> Hi all,
> I am currently working on a project which use jetty as the embedded web
> server. In that project, jetty is the main dependency for handling
> web-socket connections with the browser, proxy connection to the cloud and
> as the main HTTP server. After changing the jetty maven dependency version
> from 8.1.3.v20120416 to 9.3.x,  some of the dependencies are deprecated,
> some classes were not there so I  could not build the project. I searched
> for migration guide from Jetty 8 to 9 but I could not find a good reference
> for that.

Please use the 9.4.x series, currently at 9.4.1.v20170120.

> These are the main usages that were broken due to the version change :
>  org.eclipse.jetty.server.nio.SelectChannelConnector => No class definition

Replaced by ServerConnector.

>  org.eclipse.jetty.server.Request => API has been changed(NO METHOD
> setRequestURI)

Use Request.setHttpURI.

>  org.eclipse.jetty.http.HttpHeaders => NO CLASS
>   org.eclipse.jetty.http.HttpHeaders => No Class


>  org.eclipse.jetty.http.HttpSchemes => No class


> => No class

Replaced by java.nio.ByteBuffer.

>  org.eclipse.jetty.http.HttpHeaderValues; => No class

Functionality is in HttpFields.

>   org.eclipse.jetty.client.HttpClient  =>  interface has been changed. no
> definitions for followings
>     setConnectorType

These are not needed anymore.

>     setThreadPool
>     getThreadPool


>   HttpExchange => THERE IS NO DEFAULT CONSTRUCTOR , api has been changed

Yes that is a major change.

>   org.eclipse.jetty, jetty-websocket dependency does not exist

It has been split to implement JSR 356.

Simone Bordet
Developer advice, training, services and support
from the Jetty & CometD experts.

Back to the top