I don’t think it’s a CGLib problem. This is just an error you get when there is an event listener that cannot be assigned to a cluster. The cluster selector normally looks at the class of the actual bean (the Cglib proxy implements EventListenerProxy, so the class that is being proxies is checked for annotations, classname, etc).
Make sure the criteria you have configured in your spring context are complete.
The Dao’s which don’t work with the annotation selector are JpaRepositories (the classes are also annotated with the @Repository annotation (spring). I’m just curious because other classes annotated with the same cluster selector do work just fine… Only the dao’s fail.
When I use other criteria (e.g. the class-name criterium it works fine. I just liked the annotation approach because no classname mappings need to be configured in the spring configuration.)
You can also set a cluster as “default”. In that case, all listeners not assigned to a cluster will be assigned to the default one.
I would like to assign everything to a specific cluster. Otherwise I could end up with the fact that some events are not replayed when doing a cluster replay because the didn’t belong to that cluster…