Hi,
I have a Laravel 5.3 installation running as a pure API application and need to connect from several different applications.
Everything is working fine (after all it's Laravel we're talking about :P), except I can't figure out one thing:
I have a MQTT server that is listening for messages from several devices (doesn't matter what). These messages contain information about a Job Class and method that need to be called on the backend.
I can't call the API directly, the devices simply don't support this (they do, but it's a lot more effort than using MQTT to transmit data).
My thought was to push a new job onto the queue defining which Laravel Job Class to call (and which method). The problem is the JSON serialization...
The MQTT server is running on NodeJS, my queues are running on Redis.
I remember a Tweet from Taylor where he mentioned that theoretically it could be possible to serialize the JSON needed and push to the queue from outside Laravel, and have the job processed by Laravel.
Anyone any idea how to approach this? Is there a documentation available about the structure of the JSON?
Thanks in advance :)
EDIT:
I found this http://locutus.io/php/var/serialize/ to reproduce a similar structure than what Laravel generates. The only problem is that jobs are being discarded without being processed (no errors are thrown from the queue worker)...
Sign in to participate in this thread!
The Laravel portal for problem solving, knowledge sharing and community building.
The community