Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Issue with Event Listener Not Firing #190

Open
HeadStudios opened this issue Aug 17, 2023 · 0 comments
Open

Issue with Event Listener Not Firing #190

HeadStudios opened this issue Aug 17, 2023 · 0 comments

Comments

@HeadStudios
Copy link

Hi SendPortal!

I'm encountering an issue with the event-listener flow in my application.

Details:

I've confirmed that the MessageDispatchEvent is being dispatched. I have added a dump statement within the constructor of this event, and I see the expected output.
I have also ensured that this event is linked to the MessageDispatchHandler listener in the EventServiceProvider.
When the event is dispatched, I expect the handle method in the MessageDispatchHandler to execute. However, it seems this method is not being called, even though the listener's constructor is.
I've also noticed that the MessageDispatchHandler is queued (implements ShouldQueue). While the constructor is being executed, the queued handle method seems to be the part not working.

What I've tried:

  1. Checked to ensure the queue worker is running and processing jobs.
  2. Checked for any failed jobs using php artisan queue:failed.
  3. Checked the application logs for any potential errors related to this flow.
  4. I'm not sure why the handle method inside the listener is not being executed after the event is dispatched. Any guidance or assistance would be much appreciated.

Thank you for your support.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant