Background
----------------
We are using a dependency management tool called Savant that downloads project JAR files into the users home directory in the same manner that Maven does. We also are using vertigo-ant, which provides a two features of importance:
1. The ability to create IML files that reference the JAR files Savant downloads into the users home directory
2. Release processing for creating tags and releasing JAR files into remote locations
Most of our projects are configured to reference the JAR files from the users home directory because our developers use the vertigo-ant support for generating the .IML files for projects. Plus, the release process deletes all of these JAR files and downloads them fresh to ensure the project is releasable.
Issues
--------
When the release process deletes all of the JAR files referenced by the IML and cached/indexed by IJ, IJ has issues recovering from this. Often IJ has to re-cache/re-index the entire set of project libraries, even though the JAR files that are downloaded are identical to the JAR files IJ had previously indexed/cached. I would think that a simple MD5 sum might save some time and headaches when re-caching/re-indexing. This process is extremely time consuming and sometimes can put IJ into a state where it is unable to correctly find classes inside JAR files. I've even seen things get as bad as IJ assuming all the JAR files are missing, even though they exist and are completely valid. I would assume that the cache is getting corrupted.
One of the difficult problems is that our release tool might be in the process of downloading a JAR file while IJ is trying to parse it. In this case, IJ might think that the JAR file is corrupt. Once IJ gets into this state, the only solution seems to be to remove the JAR file, clear the cache, close IJ and restart everything from scratch. Perhaps IJ could add the concept of a MD5 file for each JAR file and waits until the MD5 of the JAR matches the value in the MD5 file. Savant, Maven and most dependency management tools support MD5 files for JARs. Otherwise, I would suggest that periodically checking if the JAR files size has changed (say every 10 milliseconds) until it is stable for a period of time should work.
Also, with the latest EAP build we are now seeing a number of exceptions and errors from IJ when these JAR files disappear and re-appear. I've attached my latest log file that contains some of these stack traces for you guys to look over.