Thursday, January 8, 2015

Downloading and Installing Jetty

Jetty is a web server and servlet container. In 2009, it moved its core components to the projects of Eclipse Foundation, in order to broaden licensing and community of the project.


Installation

1. Download the latest distribution here http://download.eclipse.org/jetty/
2. Extract the distribution file jetty-distribution-9.2.6.v20141205.zip, for example.
3. Start Jetty:
> cd jetty-distribution-9.2.6.v20141205
> java -jar start.jar
2015-01-02 20:51:35.971:INFO::main: Logging initialized @1044ms
2015-01-02 20:51:36.063:WARN:oejs.HomeBaseWarning:main: This instance of Jetty is not running from a separate {jetty.base} directory, this is not recommended.  See documentation at http://www.eclipse.org/jetty/documentation/current/startup.html
2015-01-02 20:51:36.351:INFO:oejs.Server:main: jetty-9.2.6.v20141205
2015-01-02 20:51:36.370:INFO:oejdp.ScanningAppProvider:main: Deployment monitor [file:/Users/vathanakmao/workspace/jetty-distribution-9.2.6.v20141205/webapps/] at interval 1
2015-01-02 20:51:36.424:INFO:oejs.ServerConnector:main: Started ServerConnector@69121bc1{HTTP/1.1}{0.0.0.0:8080}
2015-01-02 20:51:36.425:INFO:oejs.Server:main: Started @1497ms
4. Open browser and type http://localhost:8080/ You will see error 404 page below. It means Jetty is running but there is no any default page to serve. You can check in the jetty-distribution-9.2.6.v20141205/webapps directory. It's empty. In previous versions of Jetty, there are default page included.





















No comments:

Post a Comment