You are viewing a plain text version of this content. The canonical link for it is here.
Posted to server-dev@james.apache.org by Vincenzo Gianferrari Pini <vi...@praxis.it> on 2006/08/02 18:45:18 UTC
Re: FileStreamStore file is left in the spool
Moved this thread to server-dev, because more appropriate.
Stefano Bagnara wrote:
> I think the problem is that there is a stream opened on that file when
> the delete is called. So the file is locked and the delete fail.
> Under linux you can remove an opened file because it is really removed
> but the one that is reading it still keep an handle to the file and the
> stream is still valid. The file is finally removed when you close every
> stream for that file.
It happens that the file remains locked *until James is shutdown*. If it
is true (as it very likely is) that a stream remains open "forever", we
have a *memory leak*, not just a diskspace leak. And the memory leak
would occur also under *nix.
>
> I agree this is a bug but we had this in ALL versions of James and we
> can't block 2.3 for this as we are in RC and this bug has always been
> there.
I would absolutely agree if we had this in ALL versions of James, but
are we sure of this?
Vincenzo
>
> Furthermore, even if I think I know a few places where to look to fix
> this problem I currenlty have no time to work on this. So this have to
> wait at least 4 weeks if no one else works on this.
>
> Stefano
>
> Vincenzo Gianferrari Pini wrote:
>
>> I too could reproduce the issue with current 2.3rc1 (not tried with
>> current trunk).
>>
>> The problem occurs *only* under Windows, as a very similar
>> configuration under linux (at least with same repositories structure)
>> works fine.
>>
>> Using a debugger I found that command "file.delete();" at line 277 of
>> AbstracFileRepository fails (returns false) *because the
>> XXX.Repository.FileStreamStore file is locked by Windows*, while the
>> XXX.Repository.FileStreamStore file is not and because of that it is
>> successfully deleted.
>>
>> The XXX.Repository.FileStreamStore probably is flushed but not closed
>> when created into the spool, and there may be a difference in
>> behaviour between Windows and Linux. We should investigate further.
>>
>> This is a major bug.
>>
>> Vincenzo
>
>
---------------------------------------------------------------------
To unsubscribe, e-mail: server-dev-unsubscribe@james.apache.org
For additional commands, e-mail: server-dev-help@james.apache.org
Re: FileStreamStore file is left in the spool
Posted by Stefano Bagnara <ap...@bago.org>.
Vincenzo Gianferrari Pini wrote:
> It happens that the file remains locked *until James is shutdown*. If it
> is true (as it very likely is) that a stream remains open "forever", we
> have a *memory leak*, not just a diskspace leak. And the memory leak
> would occur also under *nix.
>
>> I agree this is a bug but we had this in ALL versions of James and we
>> can't block 2.3 for this as we are in RC and this bug has always been
>> there.
>
> I would absolutely agree if we had this in ALL versions of James, but
> are we sure of this?
Ok (not so ok), I checked 2.2.0 and it does not happen.
2.2.0 have a 30 seconds delay to spool the message but then it remove
the file correctly. So I'll try to increase the priority of the
investatigations..
Stefano
---------------------------------------------------------------------
To unsubscribe, e-mail: server-dev-unsubscribe@james.apache.org
For additional commands, e-mail: server-dev-help@james.apache.org