-
Bug
-
Resolution: Not an Issue
-
P4
-
8, 11, 17, 21, 22, 23
-
None
Looking at the methods of BasicDirectoryModel, I can see that some methods use synchronized(fileCache) before accessing the field but others (getSize, contains, indexOf, getElementAt), which makes the BasicDirectoryModel class not thread-safe; it is especially dangerous with contains and indexOf where the contents of the fileCache can be changed while the method is iterating over the values inside fileCache.
These methods—getSize, contains, indexOf, getElementAt—are to access fileCache within synchronized(fileCache) {}.
https://github.com/openjdk/jdk/pull/17462#issuecomment-1909906871
These methods—getSize, contains, indexOf, getElementAt—are to access fileCache within synchronized(fileCache) {}.
https://github.com/openjdk/jdk/pull/17462#issuecomment-1909906871
- relates to
-
JDK-8240690 Race condition between EDT and BasicDirectoryModel.FilesLoader.run0()
- Resolved
-
JDK-8323670 A few client tests intermittently throw ConcurrentModificationException
- Resolved
-
JDK-8307091 A few client tests intermittently throw ConcurrentModificationException
- Closed