Mastering RabbitMQ
eBook - ePub

Mastering RabbitMQ

Emrah Ayanoglu, Yusuf Aytas, Dotan Nahum

Partager le livre
  1. 286 pages
  2. English
  3. ePUB (adapté aux mobiles)
  4. Disponible sur iOS et Android
eBook - ePub

Mastering RabbitMQ

Emrah Ayanoglu, Yusuf Aytas, Dotan Nahum

DĂ©tails du livre
Aperçu du livre
Table des matiĂšres
Citations

À propos de ce livre

Master the art of developing message-based applications with RabbitMQ

About This Book

  • Learn how to administer, manage, and extend your own message broker, RabbitMQ
  • Develop clients to make a message bridge between your software systems using RabbitMQ
  • Discover how to achieve proficiency with RabbitMQ with the well-defined descriptions of the topics

Who This Book Is For

If you are an intermediate-level RabbitMQ developer, who wants to achieve professional-level expertise in the subject, this book is for you. You'll also need to have a decent understanding of message queuing.

What You Will Learn

  • Administer RabbitMQ using different tools
  • Understand the roots and details of messaging, message brokers, and AMQP protocol
  • Scale the RabbitMQ server using the clusters and high availability techniques
  • Extend RabbitMQ by developing the Erlang OTP-based applications that use the RabbitMQ API
  • Manage the RabbitMQ server using its powerful tools
  • Monitor the RabbitMQ Server using different open source tools such as Nagios, Munin, and Zabbix
  • Ensure your RabbitMQ's security using SSL, SASL, and access control
  • Develop RabbitMQ clients using Java, Python, and C# with an industry example

In Detail

RabbitMQ is one of the most powerful Open Source message broker software, which is widely used in tech companies such as Mozilla, VMware, Google, AT&T, and so on. RabbitMQ gives you lots of fantastic and easy-to-manage functionalities to control and manage the messaging facility with lots of community support. As scalability is one of our major modern problems, messaging with RabbitMQ is the main part of the solution to this problem.

This book explains and demonstrates the RabbitMQ server in a detailed way. It provides you with lots of real-world examples and advanced solutions to tackle the scalability issues.

You'll begin your journey with the installation and configuration of the RabbitMQ server, while also being given specific details pertaining to the subject. Next, you'll study the major problems that our server faces, including scalability and high availability, and try to get the solutions for both of these issues by using the RabbitMQ mechanisms. Following on from this, you'll get to design and develop your own plugins using the Erlang language and RabbitMQ's internal API. This knowledge will help you to start with the management and monitoring of the messages, tools, and applications. You'll also gain an understanding of the security and integrity of the messaging facilities that RabbitMQ provides. In the last few chapters, you will build and keep track of your clients (senders and receivers) using Java, Python, and C#.

Style and approach

An easy-to-follow guide, full of hands-on examples based around managing, monitoring, extending, and securing RabbitMQ and its internal tools. You will learn how to develop your own clients using Java, Python, and C#.

Foire aux questions

Comment puis-je résilier mon abonnement ?
Il vous suffit de vous rendre dans la section compte dans paramĂštres et de cliquer sur « RĂ©silier l’abonnement ». C’est aussi simple que cela ! Une fois que vous aurez rĂ©siliĂ© votre abonnement, il restera actif pour le reste de la pĂ©riode pour laquelle vous avez payĂ©. DĂ©couvrez-en plus ici.
Puis-je / comment puis-je télécharger des livres ?
Pour le moment, tous nos livres en format ePub adaptĂ©s aux mobiles peuvent ĂȘtre tĂ©lĂ©chargĂ©s via l’application. La plupart de nos PDF sont Ă©galement disponibles en tĂ©lĂ©chargement et les autres seront tĂ©lĂ©chargeables trĂšs prochainement. DĂ©couvrez-en plus ici.
Quelle est la différence entre les formules tarifaires ?
Les deux abonnements vous donnent un accĂšs complet Ă  la bibliothĂšque et Ă  toutes les fonctionnalitĂ©s de Perlego. Les seules diffĂ©rences sont les tarifs ainsi que la pĂ©riode d’abonnement : avec l’abonnement annuel, vous Ă©conomiserez environ 30 % par rapport Ă  12 mois d’abonnement mensuel.
Qu’est-ce que Perlego ?
Nous sommes un service d’abonnement Ă  des ouvrages universitaires en ligne, oĂč vous pouvez accĂ©der Ă  toute une bibliothĂšque pour un prix infĂ©rieur Ă  celui d’un seul livre par mois. Avec plus d’un million de livres sur plus de 1 000 sujets, nous avons ce qu’il vous faut ! DĂ©couvrez-en plus ici.
Prenez-vous en charge la synthÚse vocale ?
Recherchez le symbole Écouter sur votre prochain livre pour voir si vous pouvez l’écouter. L’outil Écouter lit le texte Ă  haute voix pour vous, en surlignant le passage qui est en cours de lecture. Vous pouvez le mettre sur pause, l’accĂ©lĂ©rer ou le ralentir. DĂ©couvrez-en plus ici.
Est-ce que Mastering RabbitMQ est un PDF/ePUB en ligne ?
Oui, vous pouvez accĂ©der Ă  Mastering RabbitMQ par Emrah Ayanoglu, Yusuf Aytas, Dotan Nahum en format PDF et/ou ePUB ainsi qu’à d’autres livres populaires dans Informatica et Programmazione in Java. Nous disposons de plus d’un million d’ouvrages Ă  dĂ©couvrir dans notre catalogue.

Informations

Année
2016
ISBN
9781783981526
Édition
1

Mastering RabbitMQ


Table of Contents

Mastering RabbitMQ
Credits
About the Authors
About the Reviewers
www.PacktPub.com
Support files, eBooks, discount offers, and more
Why subscribe?
Free access for Packt account holders
Preface
What this book covers
What you need for this book
Who this book is for
Conventions
Reader feedback
Customer support
Downloading the example code
Errata
Piracy
Questions
1. Getting Started
Message brokers and message queue
Message brokers
Message Queues
An introduction to the advanced message queue protocol
An overview of RabbitMQ
Installation of RabbitMQ
Windows
Mac OS X
Ubuntu
Fedora
Amazon elastic compute cloud (EC2)
Starting RabbitMQ
Starting RabbitMQ on Windows
Other OSes (Linux, Mac OS X)
Summary
2. Configuring RabbitMQ
Overall configuration of RabbitMQ
The RabbitMQ environment variables
Common environment variables
Unix-specific default location
Windows-specific default location
The configuration file
Runtime parameters
Parameter management
Policy management
Memory management
Summary
3. Architecture and Messaging
Messaging and its use cases
Coupling of the software systems
Heterogeneous integration
Addressing scalability
Enterprise messaging
Messaging-related software architectures
Message oriented middleware – Architecture
Event-driven architecture
Messaging concepts
Message producers
Message brokers
Message consumers
Messages
Advanced Message Queuing Protocol (AMQP)
AMQ elements
Message flow
Exchanges in AMQ
Message queues
Bindings
Functional specifications of AMQP
AMQP messages
Virtual hosts
Exchange types
The direct exchange type – amq.direct
The fan-out exchange type – amq.fanout
The topic exchange type – amq.topic
The headers exchange type – amq.match
Summary
4. Clustering and High Availability
High reliability in RabbitMQ
Federation in RabbitMQ
Clustering in RabbitMQ
Creating clusters
Checking the cluster status
Changing the cluster node types
Updating cluster nodes
Clustering the settings of RabbitMQ
Load balancing for high availability of queues
Summary
5. Plugins and Plugin Development
Plugin management and default plugins
Enabling and disabling plugins
Installing plugin from third-party sources
Default plugin list
Plugin configuration
Custom plugin development
Basics of Erlang
Variables and expressions
Tuples and lists
Functions and modules
Conditionals
Looping in Erlang
Concurrent programming
Simple RabbitMQ metronome plugin
Summary
6. Managing Your RabbitMQ Server
Management via a command line
Cluster commands
User commands
Virtual host and permission commands
Miscellaneous commands
Management via a web plugin
Management via a REST API
Summary
7. Monitoring
RabbitMQ command-line tools
Web plugins
Nagios
Munin
Zabbix
Summary
8. Security in RabbitMQ
An brief introduction to security in RabbitMQ
Vulnerabilities
Information leakage
Session management
Authentication and authorization
Solutions to the vulnerabilities
Fixing information leakage
Session management
Authentication and authorization
Applying access control
Providing SASL authentication
SSL support in RabbitMQ
Keys, certificates, and CA certificates
Enabling SSL support
Summary
9. Java RabbitMQ Client Programming
Case study
Use cases
Interaction diagram – sequence diagram
Application language – Java
Java Message Service (JMS)
RabbitMQ Java client API
Client package in detail
Connection
Channel
Exchanges
Queues
Publishing messages
Consuming messages
Synchronously receiving messages
Asynchronously receiving messages
Case study – client implementations
Model classes
JSONMessage interface
Message model
File message
Task
Single message
Sender
Receiver
Group message – routing
Sender
Receiver
Bulk message – PubSub
Sender
Receiver
File message
Sender
Receiver
RPC message
RPC client
RPC server
Creating tasks – manual acknowledgment
Task creator
Task handler
Creating distributing tasks
Task creator
Task handler clients
Spring framework and RabbitMQ
Spring AMQP
Single message
Spring config
Sender
Receiver
PubSub messages
Spring config
Private messages – routing
Spring config
Summary
10. Ruby Client Programming
Case study
Small data
Big data
Medium data
Solving all data problems
Bunny and Ruby
Installing Ruby
Linux
Windows
OSX/Mac
Rbenv
Installing Bunny
Using Bunny
Bunny producer
Bunny consumer
Exploring the AMQP model with Bunny
Workers
Publish – subscribe
Routing
The real-time processing
Sneakers
Installing
Lambda architecture
The real-time processors
Key performance indicators (KPIs)
Building averaging workers
Windows
Linux
Mac OS X
Building the IP2Location worker
Exploring sneakers
Timeouts
Job handling
Metrics
Summary
11. Python Client Programming
Case study
Getting Python dependencies
Pika
Installing Pika
Our first Pika client
A consumer
Introducing the web scraper
Scheduler
Scraper
Implementing the scheduler
Implementing the scraper
Running the scraper
Handling failure
Using acknowledgement
The Pika API
Connecting
Using connection adapters
BlockingConnection
BlockingChannel
Declaring queues and exchanges
Authentication
Plain credentials
SSL and external credentials
Certificate authentication
Background processing
Celery
Installation
Celery scraper
Celery scheduler
Exploring Celery
Scheduling
HTTP hook tasks
Other Celery features
Summary
Index

Mastering RabbitMQ

Copyright © 2015 Packt Publishing
All rights reserved. No part of this book may be reproduced, stored in a retrieval system, or transmitted in any form or by any means, without the prior written permission of the publisher, except in the case of...

Table des matiĂšres