Public class EventPublisher implements IEventPublisher {
Private static final Logger log=LoggerFactory. GetLogger (EventPublisher. Class);
The @autowired
Private ApplicationEventPublisher ApplicationEventPublisher;
//public EventPublisher (ApplicationEventPublisher ApplicationEventPublisher) {
//this. ApplicationEventPublisher=applicationEventPublisher;
//}
Public EventPublisher () {
}
/* *
* publish event
*
* @ param event
* @ param & lt; T>
*/
@ Override
The public & lt; T extends ActEvent> Void the publish event (T) {
The info (" publish immediately event | {} ", the event).
ApplicationEventPublisher. PublishEvent (event);
}
CodePudding user response:
EventPublisher are not sweep to?CodePudding user response:
@ Component 1, do you have a lead the wrong package2, Bean scanning path is properly
3, the Bean's loading sequence is correct