Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Eclipse Projects » Web Tools Project (WTP) » Apache Tomcat (Tomcat and Eclipse long latency?)
Apache Tomcat [message #542895] Sun, 27 June 2010 06:44 Go to next message
NMO  is currently offline NMO
Messages: 9
Registered: June 2010
Junior Member
Hi!

I have installed Tomcat to develop web applications (servlets). I have found out that it takes a lot of clicks until the servlet gets displayed in the web browser. Everytime I make a change on my servlet I have to Rebuild my Project with Ctrl + B then I have to wait until the servlet gets redeployed and then I have to select my servlets source file and have to click: run as -> run on server. After that it takes further two seconds until the servlet gets executed. This is not really comfortable because even when I make small changes I have to click a lot and have to wait to see the result. Is there a faster way to execute web applications??
Re: Apache Tomcat [message #543157 is a reply to message #542895] Mon, 28 June 2010 11:00 Go to previous messageGo to next message
Larry Isaacs is currently offline Larry Isaacs
Messages: 1305
Registered: July 2009
Senior Member
On 6/27/2010 6:44 AM, NMO wrote:
> Hi!
>
> I have installed Tomcat to develop web applications (servlets). I have
> found out that it takes a lot of clicks until the servlet gets displayed
> in the web browser. Everytime I make a change on my servlet I have to
> Rebuild my Project with Ctrl + B then I have to wait until the servlet
> gets redeployed and then I have to select my servlets source file and
> have to click: run as -> run on server. After that it takes further two
> seconds until the servlet gets executed. This is not really comfortable
> because even when I make small changes I have to click a lot and have to
> wait to see the result. Is there a faster way to execute web applications??

You can eliminate the Ctrl + B by enabling automatic building and after
the first Run As -> Run on Server, you can leave the browser open and
just use "refresh" to re-execute the servlet in most cases. The main
delay, assuming Tomcat is already running, is waiting for Tomcat to
detect the change and reload the webapp (if auto-reload is enabled).

The alternative approach is to disable auto-reload and to run in debug
mode. The hot code replacement feature of debug mode can allow you to
test some changes immediately. If the change is such that hot code
replacement can't occur, you will have to restart Tomcat.

Cheers,
Larry
Re: Apache Tomcat [message #543178 is a reply to message #542895] Mon, 28 June 2010 11:30 Go to previous messageGo to next message
Russell Bateman is currently offline Russell Bateman
Messages: 3157
Registered: July 2009
Location: Provo, Utah, USA
Senior Member

On 6/27/2010 4:44 AM, NMO wrote:
> Hi!
>
> I have installed Tomcat to develop web applications (servlets). I have
> found out that it takes a lot of clicks until the servlet gets displayed
> in the web browser. Everytime I make a change on my servlet I have to
> Rebuild my Project with Ctrl + B then I have to wait until the servlet
> gets redeployed and then I have to select my servlets source file and
> have to click: run as -> run on server. After that it takes further two
> seconds until the servlet gets executed. This is not really comfortable
> because even when I make small changes I have to click a lot and have to
> wait to see the result. Is there a faster way to execute web applications??

From experience, I find that any JSP changes made (whether to HTML or
similar code, as well as to embedded Java code) are reflected by just
refreshing the browser already running my JSP.

However, changes to Java code outside the JSP file require me to rebuild
and relaunch.

Hope this helps,

Russ
Re: Apache Tomcat [message #543472 is a reply to message #542895] Tue, 29 June 2010 10:29 Go to previous message
NMO  is currently offline NMO
Messages: 9
Registered: June 2010
Junior Member
Thank you for your replies. Automatic Build works quite well. After clicking the refresh button I have to wait three seconds until the changes are displayed. But I can live with that.

Again thank you.
Previous Topic:EL validation error for quote escaping
Next Topic:WTP Tomcat hot deploy with m2eclipse
Goto Forum:
  


Current Time: Sat Aug 30 10:24:15 EDT 2014

Powered by FUDForum. Page generated in 0.09051 seconds