eclipse-platform / eclipse.platform.resources

Eclipse Public License 2.0
3 stars 18 forks source link

ContentDescriptionManager.FlushJob could be improved #119

Closed iloveeclipse closed 2 years ago

iloveeclipse commented 2 years ago

Observed in our product: if one re-creates some project (via delete/create sequence), it triggers cache update of the ContentDescriptionManager for this project. This is not a bug, but the project cache is cleaned/refreshed two times because ContentDescriptionManager.FlushJob.toFlush is a list, not a set, so every time a project is recreated (or anything else is touched, it will happily add the path even if it is already there).

The job is scheduled with 1 second delay, so unlikely this affects real word cases, but I assume this could affect SDK tests a lot, doing same work twice isn't surely good for the runtime.

I will push a patch.