commons-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Mario Ivankovits <>
Subject Re: [VFS] accessing FileObjects from different threads
Date Wed, 12 Jul 2006 07:24:12 GMT
Hi Filip, nice to read you again.

> Sometimes, the FileObject gets detached while it's still being used by
> another
> thread causing exceptions and sometimes the FileObject go into a
> deadlock.
As you already noticed ( you are bleedingly fast) :-) I committed a try
to fix this issue.
Maybe if you simply try the svn head version it might behave better
already without any additional change. But for sure, if one thread tries
to copy the file and another one deletes it at the same time you'll get
exceptions again.
Could you please provide more informations about the operations you try
in parallel on the same fileObject?

The next NEW thing you can try is, to decorate the file object so that
it will synchronize each call.

        StandardFileSystemManager manager = new StandardFileSystemManager();

if you use instanceof with your FileObjects you have to change this to

However, the deadlock problem might be more problematic. We need a "full
thread dump" to figure out whats the problem.
Also the SynchronizedFileObject might introduce new deadlocks as it
synchronize against the fileObject instance, internally the FileObject
itself has to synchronize against the fileSystem .... but hey, its a try.

Could you please check this out.


To unsubscribe, e-mail:
For additional commands, e-mail:

View raw message