avalon-phoenix-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Steve Short <Steve.Sh...@PostX.com>
Subject RE: James sar unpacks libraries into new "work" every startup
Date Thu, 30 May 2002 17:29:04 GMT

It would be good if this can be implemented so that a clean recovery can be
made from a catastrophic failure, such as a JVM crash.  While these are
rare, they do still happen.  Therefore I'd vote for cleaning up all of the
work dir on startup.

Steve

-----Original Message-----
From: Peter Donald [mailto:peter@apache.org]
Sent: Thursday, May 30, 2002 5:33 AM
To: Avalon-Phoenix Developers List
Subject: Re: James sar unpacks libraries into new "work" every startup


On Thu, 30 May 2002 01:23, Danny Angus wrote:
> > Hmm - can you tell me in what situations this directory is not
> > removed. I have
> > only tested under unix (which has no file locking) but it seemed to
work.
>
> Windows, any shutdown at all leaves it intact.

grr... stupid file locking ;)

Okay. If a file can not be imediately be deleted then it will instead be 
scheduled for delete at JVM shutdown. 

So in theory this should mean that the files will all be deleted by the time

the JVM shuts down. However in practice this may not be so. It seems to be a

JVM/platform dependent behaviour and in 99% of cases the files will be 
deleted correctly but the directories may or may not be deleted. The reason 
being that delete could be called on directory before it is empty (which
will 
fail). So in this case you may get a lot of ugly empty directories.

Solutions:

* I could modify phoenix so that at startup all the empty directories (ie 
remanents of last run on windows platforms) are deleted.

* I could modify phoenix so that all of work dir is deleted at startup. This

would make it difficult to run multiple instances of phoenix in same 
hierarchy unless we added a --work-dir option on command line.

Thoughts?


-- 
Cheers,

Peter Donald


--
To unsubscribe, e-mail:
<mailto:avalon-phoenix-dev-unsubscribe@jakarta.apache.org>
For additional commands, e-mail:
<mailto:avalon-phoenix-dev-help@jakarta.apache.org>

--
To unsubscribe, e-mail:   <mailto:avalon-phoenix-dev-unsubscribe@jakarta.apache.org>
For additional commands, e-mail: <mailto:avalon-phoenix-dev-help@jakarta.apache.org>


Mime
View raw message