I'm using org.openide.util.Lookup as a standalone library in an application (not a NetBeans Platform Application).
Everywhere I look it says that you can get rid of META-INF/services entries from old classes that used the @ServiceProvider annotation by doing a Clean and Build, but no matter how many times I Clean/Clean and Build/restart NetBeans/reboot the computer it still remembers the old annotations. I even looked through a ton of config files to see if it was caching the references somewhere.
The only way I have found that works is to create a fresh project and never delete or refactor any class after adding the @ServiceProvider annotation to it. This gets HIGHLY frustrating.
Does anyone know the magic bullet for getting these old class references out of the generated META-INF/services files?