Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Language IDEs » ServerTools (WTP) » Servlet won't refresh
Servlet won't refresh [message #186494] Thu, 18 January 2007 20:00 Go to next message
Eclipse UserFriend
Originally posted by: spam.free.fr

Greetings,

There is something I do not understand on eclipse :
When I write a servlet, I need to restart the server manually in order to
take the changes of code. What I do not understand is that, according to
the help file, Eclipse, if configured correctly in the server settings
should normally automatically restart the server. I ticked the box to
republish but no avail.

Moreover, it seems a little extreme to me to need to restart the whole
server to change a single servlet. I though that it was possible to
restart only the web app.

Can someone shed some light on this please ?

Many thanks.
Re: Servlet won't refresh [message #186589 is a reply to message #186494] Fri, 19 January 2007 16:18 Go to previous messageGo to next message
Larry Isaacs is currently offline Larry IsaacsFriend
Messages: 1354
Registered: July 2009
Senior Member
Which server and version of WTP are you using?

Cheers,
Larry

charly wrote:
> Greetings,
>
> There is something I do not understand on eclipse : When I write a
> servlet, I need to restart the server manually in order to take the
> changes of code. What I do not understand is that, according to the help
> file, Eclipse, if configured correctly in the server settings should
> normally automatically restart the server. I ticked the box to republish
> but no avail.
>
> Moreover, it seems a little extreme to me to need to restart the whole
> server to change a single servlet. I though that it was possible to
> restart only the web app.
> Can someone shed some light on this please ?
>
> Many thanks.
>
Re: Servlet won't refresh [message #187246 is a reply to message #186589] Sun, 28 January 2007 13:11 Go to previous messageGo to next message
Eclipse UserFriend
Originally posted by: spam.free.fr

Sorry for not answering earlier, I was busy on a dot net project.

The wtp I use is Eclipse 3.2.1 with a tomcat server 5.
Re: Servlet won't refresh [message #187252 is a reply to message #186589] Sun, 28 January 2007 13:19 Go to previous messageGo to next message
Eclipse UserFriend
Originally posted by: spam.free.fr

The version of WTP is RC1.5.2
Tomcat is 5.5

Thank you for your concern.

Regards,
Re: Servlet won't refresh [message #187265 is a reply to message #187252] Mon, 29 January 2007 14:39 Go to previous message
Larry Isaacs is currently offline Larry IsaacsFriend
Messages: 1354
Registered: July 2009
Senior Member
Hi,

The typical sequence of events when modifying a servlet is that when the
servlet is saved, the changes are published (assuming auto-publishing is
enabled) and if the server was running, the server goes into the Restart
state. However, because the "reloadable" context attribute defaults to
true when adding projects to a Tomcat server, you should see console
message like "INFO: Reloading this Context has started", indicating that
the Context for the changed project has reloaded. Following this
reload, you should be able to see the changes in your servlet. The
Tomcat plug-ins in WTP don't have a good way to know about this reload,
so it assumes a restart is necessary. You can postpone the restart if
desired.

The Context reload or server restart is needed to cause the classloader
containing the old version of the servlet to be discarded and replaced
with a new one to hold the new version. Note that the classloader in
question is the web application's classloader, and that it is easy for
this classloader to leak, i.e. not be garbage collectible for a variety
of reasons. If this is the case, then with enough reloads, the server
will run out of memory and a restart will be needed to start fresh again.

Cheers,
Larry

charly wrote:
> The version of WTP is RC1.5.2
> Tomcat is 5.5
>
> Thank you for your concern.
>
> Regards,
>
Previous Topic:XML validation will not work in used XMLEditor
Next Topic:Adding a menu contribution to XML Editor
Goto Forum:
  


Current Time: Thu Mar 28 21:57:16 GMT 2024

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

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

Back to the top