On September 25, 2002 02:04 pm, Jason Hildebrand wrote:
> Here are a couple of ideas for improving the implementation, though.
>
> One procedure I do fairly often is to 'cvs update' my application then
> restart the server.  I'm not sure if your implementation will work
> flawlessly in the situation where multiple files change -- there is a
> race condition which I see:
>
> 1) File A is updated
> 2) Appserver notices that A has changed, shuts down and begins to
> restart
> 3) In restarting, Appserver imports file B at time t.
> 4) File B is updated at time t+1.
> 5) The file monitor thread notices that File B has been imported,
> records the mtime as t+1.
>
> So the appserver is running using an out-of-date File B.

I don't think there's a graceful way around that:  if a module is changed 
after the appserver starts, but before the application actually imports it.

The implementation could be extended so that you can manually add files to the 
dicts self._monitoredFiles and self._monitoredModules, but a simpler solution 
in this restricted case of a cvs update would be to issue a restart command 
along with the 'cvs update':
  cvs update; webkit stop; webkit start
or in expWebware:
  cvs update; webkit restart





-------------------------------------------------------
This sf.net email is sponsored by:ThinkGeek
Welcome to geek heaven.
http://thinkgeek.com/sf
_______________________________________________
Webware-discuss mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/webware-discuss

Reply via email to