开发者

Running jetty from eclipse

Please let me know how can I configure jetty server to run from eclipse IDE? Also, suggest me some good plugins for the same. I downloaded jetty launcher but 开发者_开发百科not able create new configuration with it. Please help.


The best way I found to run Jetty from eclipse (and debug, etc.) was this : http://neelzone.wordpress.com/2007/06/18/jetty-and-eclipse-integration/

Basically, you create a java project, put jetty's code in it, create a context file in jetty/contexts that points to your web application, and Run as Java application.

No need for a plugin.


With Eclipse Kepler, I found two plugins, "Eclipse Jetty" and "Run Jetty Run" in the market place.

I tried "Run Jetty Run" first but couldn't make it work (css file didn't load), but with "Eclipse Jetty", it worked out of the box for my project.


I have followed the below steps to set up Jetty server in my eclipse:

(1) Download the 'net.sourceforge.eclipsejetty.launcher' jar (plugin) from the below URL: http://sourceforge.net/projects/eclipse-jetty/

(2) Copy the downloaded jar file to your eclipse 'plugins' folder (Example: C:\eclipse-jee-luna\plugins)

(3) Restart Eclipse

(4) Go to Eclipse Workspace -> Right click on your web project -> Run -> Run Configurations > Jetty Web App > Set the 'WebApp Directory' > Click on Run

Running jetty from eclipse

After following the above steps, I am able to successfully deploy & run my web project using Jetty Server in Eclipse.

I hope this is helpful and easy to set up.

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜