Imagine the case where you have a few ORM-managed objects mapped to compass, and a few additional objects that are mapped independently of any CompassGps Device.
What's going to happen is that when doing gps.index(), the whole index will be deleted, and of course, the index that corresponds to the additional objects wont be re-indexed.
In my opinion, it would seem natural that CompassGps only deletes the indexes managed by gps devices.
in SingleCompassGps, it seems that the following line
indexCompass.getSearchEngineIndexManager().deleteIndex();
could be replaced by something a little more specific. I guess this would need GpsDevices to suppot an additional method String [] getManagedSubIndexes(), or something similar.
Good luck !
Sami
The deleteIndex is called on the indexCompass instance, which is not pointing to the "real time" index, but to the index used when reindexing the system.