Zend_Queue-Introduction.xml 1.9 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758
  1. <?xml version="1.0" encoding="UTF-8"?>
  2. <!-- Reviewed: no -->
  3. <sect1 id="zend.queue.introduction">
  4. <title>Introduction</title>
  5. <para>
  6. <classname>Zend_Queue</classname> provides a factory function to create
  7. specific queue client objects.
  8. </para>
  9. <para>
  10. A message queue is a method for distributed processing. For example, a
  11. Job Broker application may accept multiple applications for jobs from
  12. a variety of sources.
  13. </para>
  14. <para>
  15. You could create a queue "<filename>/queue/applications</filename>" that
  16. would have a sender and a receiver. The sender would be any available
  17. source that could connect to your message service or indirectly to an
  18. application (web) that could connect to the message service.
  19. </para>
  20. <para>
  21. The sender sends a message to the queue:
  22. </para>
  23. <programlisting language="xml"><![CDATA[
  24. <resume>
  25. <name>John Smith</name>
  26. <location>
  27. <city>San Francisco</city>
  28. <state>California</state>
  29. <zip>00001</zip>
  30. </location>
  31. <skills>
  32. <programming>PHP</programming>
  33. <programming>Perl</programming>
  34. </skills>
  35. </resume>
  36. ]]></programlisting>
  37. <para>
  38. The recipient or consumer of the queue would pick up the message and
  39. process the resume.
  40. </para>
  41. <para>
  42. There many messaging patterns that can be applied to queues to abstract
  43. the flow of control from the code and provide metrics, transformations,
  44. and monitoring of messages queues. A good book on messaging patterns is
  45. <ulink
  46. url="http://www.amazon.com/Enterprise-Integration-Patterns-Designing-Addison-Wesley/dp/0321200683">Enterprise
  47. Integration Patterns: Designing, Building, and Deploying Messaging Solutions
  48. (Addison-Wesley Signature Series)</ulink>
  49. (ISBN-10 0321127420; ISBN-13 978-0321127426).
  50. </para>
  51. </sect1>