ASPit - Totally ASP JSit - Totally JavaScript
Search PHPit

Use this textbox to search for articles on PHPit. Seperate keywords with a space.


How to ‘JMS’ PHP

(Page 1 out of 3)

PHPMQ gives the PHP developer JMS like abilities through the MantaRay messaging bus.

This article gives an overview of PHPMQ and its use by the PHP developer. The article assumes that the reader is familiar with both PHP and Apache, and does not describe how to install or use either product.

MantaRay � an open source serverless messaging fabric, based on peer-to-peer technology. It is written in pure Java, supports JMS 1.1 and 1.02, and integrates with WebLogic and WebSphere. MantaRay provides guaranteed message delivery and security, and it supports transactions.

PHPMQ � an open source serverless messaging toolkit for PHP, giving the PHP developer the ability to perform JMS operations such as sending and receiving messages on queues and topics while ensuring delivery and enabling persistent messaging.

PHP / JAVA integration - PHPMQ uses the PHP / Java integration extension of PHP. More information about this extension can be found at

PHP in the world of messaging

With PHPMQ, developers get the ability to communicate with other applications on the message bus, whether they are written in PHP, Java, or C++, using standard JMS-like messaging, by enqueuing messages to queues and dequeuing them, and by publishing messages to topics and subscribing for them.

PHPMQ runs a thin Java client that connects to the message bus and is the incoming and outgoing interface of the bus. The client uses the RMI API to communicate with a messaging interface located on the message bus. The interface exposes the messaging abilities of MantaRay and maintains a stateful session for the remote (PHP) client - this is done in order to keep the PHP client as thin as possible, and to provide a long-lived messaging session despite using a short-lived script.

Next: Configuring MantaRay to run with PHPMQ »

Leave a Reply

About the author
Dennis Pallett is the main contributor to PHPit. He owns several websites, including ASPit and Chill2Music. He is currently still studying.
Article Index
  1. Definitions
  2. Configuring MantaRay to run with PHPMQ
  3. PHP / JAVA and Apache
Bookmark Article
Download Article
Download this article as a PDF file