Problema con los EventHandlers | Community
Skip to main content
November 6, 2023
Solved

Problema con los EventHandlers

  • November 6, 2023
  • 2 replies
  • 621 views

Buenas,

 

Nuestra proyecto esta basado en Adobe AEM 6.5 on premise. 

Tenemos varias clases que implementan la interfaz EventHandler, con la idea de que, cuando se publique una página, se ejecute en una o varias de esas clases (las que implementan la interfaz) para enviar correos, o enviar información a otro sistema cuando se publique la página.

El problema que tenemos ahora es que sólo se dispara uno de esos eventos y no todos los que tenemos implementados.

Entonces, ¿es posible que teniendo varias clases que implementan la interfaz EventHandler, sólo se ejecute una de esas clases y no el resto? ¿Existe alguna limitación en la implementación del EventHandler?

 

Gracias de antemano, 

This post is no longer active and is closed to new replies. Need help? Start a new post to ask your question.
Best answer by arunpatidar

Translation from Spanish to English

Hello,

 

Our project is based on Adobe AEM 6.5 on premise.

We have several classes that implement the EventHandler interface, with the idea that, when a page is published, it is executed in one or more of those classes (the ones that implement the interface) to send emails, or send information to another system when the page is published.

The problem we have now is that only one of those events is fired and not all the ones we have implemented.

So, is it possible that having several classes that implement the EventHandler interface, only one of those classes is executed and not the rest? Is there any limitation in the EventHandler implementation?

 

Thanks in advance,

2 replies

arunpatidar
Community Advisor
arunpatidarCommunity AdvisorAccepted solution
Community Advisor
November 6, 2023

Translation from Spanish to English

Hello,

 

Our project is based on Adobe AEM 6.5 on premise.

We have several classes that implement the EventHandler interface, with the idea that, when a page is published, it is executed in one or more of those classes (the ones that implement the interface) to send emails, or send information to another system when the page is published.

The problem we have now is that only one of those events is fired and not all the ones we have implemented.

So, is it possible that having several classes that implement the EventHandler interface, only one of those classes is executed and not the rest? Is there any limitation in the EventHandler implementation?

 

Thanks in advance,

Arun Patidar
arunpatidar
Community Advisor
Community Advisor
November 6, 2023

You can have multiple event Listener on same event.

Example : https://aemhints.com/2020/11/08/event-listener-in-aem-6-5/ 

Arun Patidar