
|
If you were logged in you would be able to see more operations.
|
|
|
|
I've just taken a very quick look at the changes that were made to make cache.removeEntry() public. It doesn't look like thread-safety has been taken into account! Take a look at line 390 of AbstractConcurrentReadCache - the internal calls that are made to remove() are taking care to synchronize as required. So just making removeEntry() public is definitely going to cause problems.
One thing we *definitely* don't want to do is sync on GeneralCacheAdministrator.getFromCache() - that will both kill performance and cause implementation problems for users. The fix needs to go with removeEntry(). Without looking into this in more detail my first guess is that synchronizing the removeEntry() call might be enough. This hopefully won't affect performance too much since:
a) removeEntry() wasn't exposed previously anyway
b) internal calls to it are synchronized already
I'm not sure it's ideal though since there will be some double-syncing going on internally. It's not clear to me what this will do to performance.
|
|
Description
|
I've just taken a very quick look at the changes that were made to make cache.removeEntry() public. It doesn't look like thread-safety has been taken into account! Take a look at line 390 of AbstractConcurrentReadCache - the internal calls that are made to remove() are taking care to synchronize as required. So just making removeEntry() public is definitely going to cause problems.
One thing we *definitely* don't want to do is sync on GeneralCacheAdministrator.getFromCache() - that will both kill performance and cause implementation problems for users. The fix needs to go with removeEntry(). Without looking into this in more detail my first guess is that synchronizing the removeEntry() call might be enough. This hopefully won't affect performance too much since:
a) removeEntry() wasn't exposed previously anyway
b) internal calls to it are synchronized already
I'm not sure it's ideal though since there will be some double-syncing going on internally. It's not clear to me what this will do to performance.
|
Show » |
| There are no comments yet on this issue.
|
|