Background: Our current system involves two services (one written in Java, the other in PHP) that communicate with each other using HTTP callbacks. We would like to migrate from HTTP callbacks to a message-based architecture using ActiveMQ (or another, if necessary). We'll probably use STOMP to communicate between them. Eventually, the PHP service will be rewritten in Java, but that's not part of this project.
Question: How can the ActiveMQ system notify PHP that a new message has been posted to the queue that the PHP system is subscribed to? In the current system, the callback inherently calls into the PHP and triggers it. This goes away with a message-based architecture.
Possible solutions:
- Cron düzenli olarak yeni iletileri denetler bir PHP komut dosyası çağırır. iğrenç.
- Ve uyur ve yeni mesajlar için çek döngüler uzun soluklu PHP süreci. daha iğrenç?
- Yeni bir mesaj yolladı zaman ActiveMQ bir PHP komut dosyası çağırır. iyi, nasıl?
- ?