How do i register AbstractMongoEventListener programmatically?
问题 In my Spring Boot application, i have a configuration, which reads entries from a Mongo database. After this is done, my subclass of AbstractMongoEventListener is created, even though it operates on a different table and different scope (my own custom @CustomerScope ). Here is the listener: @CustomerScoped @Component public class ProjectsRepositoryListener extends AbstractMongoEventListener<Project> { @Override public void onAfterSave(Project source, DBObject dbo) { System.out.println("saved"