SlideShare une entreprise Scribd logo
1  sur  33
PGDay.IT 2015 – 23 Ottobre 2015 - Prato 1 di 33
Rabbitmq & Postgresql
Lucio Grenzi
l.grenzi@gmail.com
PGDay.IT 2015 – 23 Ottobre 2015 - Prato 2 di 33
Who is this guy?
Delphi developer since 1999
IT Consultant 
Front end web developer
Postgresql addicted
      Nonantolando.blogspot.com
      lucio.grenzi
      lucio grenzi
PGDay.IT 2015 – 23 Ottobre 2015 - Prato 3 di 33
AgendaAgenda
 Messaging system
 Rabbitmq introduction
 Postgresql and pg_amqp
 PostgreSQL Listen exchange
PGDay.IT 2015 – 23 Ottobre 2015 - Prato 4 di 33
Message-oriented middlewareMessage-oriented middleware
Message­oriented middleware (MOM) is software or hardware 
infrastructure  supporting  sending  and  receiving  messages 
between distributed systems. MOM allows application modules 
to  be  distributed  over  heterogeneous  platforms  and  reduces 
the  complexity  of  developing  applications  that  span  multiple 
operating systems and network protocols
­ https://en.wikipedia.org/wiki/Message­oriented_middleware ­
PGDay.IT 2015 – 23 Ottobre 2015 - Prato 5 di 33
Why Should I use MOM?Why Should I use MOM?
Need to scale
Monitoring data feeds
Need things done in order
Use the cloud
Decoupling  applications  by  separating  sending  and  receiving 
data
Messaging is asynchronous
PGDay.IT 2015 – 23 Ottobre 2015 - Prato 6 di 33
Different protocolsDifferent protocols
Historically,  message  queuing  has  used  proprietary,  closed 
protocols
By the time three standards have emerged which are used in 
open source message queue implementations:
Advanced Message Queuing Protocol (AMQP)
Streaming Text Oriented Messaging Protocol (STOMP)
MQ Telemetry Transport (MQTT)
PGDay.IT 2015 – 23 Ottobre 2015 - Prato 7 di 33
STOMPSTOMP
Text based
Like  AMQP,  STOMP  provides  a  message  header  with 
properties, and a frame body
Does not deal in queues and topics
The  broker  must  map  onto  something  that  it  understands 
internally such as a topic, queue, or exchange
Destinations  are  not  mandated  in  the  specification,  different 
brokers may support different flavours of destination
PGDay.IT 2015 – 23 Ottobre 2015 - Prato 8 di 33
STOMP BrokerSTOMP Broker
Apache ActiveMQ
HornetQ
Net::STOMP::Client  (an  open  source  client  implementation  in 
Perl)
Open Message Queue (OpenMQ)
RabbitMQ (message broker, has support for STOMP)
Ruby server, also known as stompserver
http://stomp.github.io/implementations.html
PGDay.IT 2015 – 23 Ottobre 2015 - Prato 9 di 33
AMQPAMQP
Designed for interoperability between different vendors
wide range of features related to messaging
Lot of fine­grained control possible with such a rich feature set
PGDay.IT 2015 – 23 Ottobre 2015 - Prato 10 di 33
Protocol implementationsProtocol implementations
Amqp  :SwiftMQ,  Apache  Qpid,  Apache  MQ, 
Apache Apollo, RabbitMQ
Stomp:  Apache  MQ,  Apache  Apollo,  RabbitMQ, 
HornetQ,  Stampy 
(http://stomp.github.io/implementations.html#STOM
P_Servers)
MQTT:  Apache  MQ,  Apache  Apollo,  RabbitMQ, 
mosquitto, WebSphereMQ, HiveMQ, IBM Message 
Sight 
(https://github.com/mqtt/mqtt.github.io/wiki/server­
support)
PGDay.IT 2015 – 23 Ottobre 2015 - Prato 11 di 33
MQTTMQTT
Originally developed out of IBM’s pervasive computing team
Provides publish­and­subscribe messaging
 Publish = data to topics
 Subscribe = get data from topics
Designed for resource­constrained devices and low bandwidth, 
high latency networks (ideal for mobile and “Internet of Things”)
MQTT’s strengths are simplicity (just five API methods)
PGDay.IT 2015 – 23 Ottobre 2015 - Prato 12 di 33
MQTT BrokerMQTT Broker
ActiveMQ, 
Apollo
JoramMQ
Mosquitto
RabbitMQ
http://www.scalagent.com/IMG/pdf/Benchmark_MQTT_servers
­v1­1.pdf
PGDay.IT 2015 – 23 Ottobre 2015 - Prato 13 di 33
RabbitmqRabbitmq
open source message broker software (MPL)
Actively developed and with commercial support by Pivotal
written in Erlang
Client libraries to interface with the broker are available for all 
major programming languages.
Gateways  for  HTTP,  Streaming  Text  Oriented  Messaging 
Protocol (STOMP), and MQTT protocols
PGDay.IT 2015 – 23 Ottobre 2015 - Prato 14 di 33
Amqp native clientsAmqp native clients
.NET PHP Java Python
C /C++ Node.js Go Erlang
Javascript Ruby Perl Scala
Delphi Groovy Cobol Clojure
PGDay.IT 2015 – 23 Ottobre 2015 - Prato 15 di 33
Amqp packetAmqp packet
Headers
Properties
Bytea [] data
Headers: defined by the Amqp specification
Properties: contain arbitrary, application – specific, 
information
PGDay.IT 2015 – 23 Ottobre 2015 - Prato 16 di 33
Amqp message propertiesAmqp message properties
Content-type MIME content type
Content-encoding MIME content
encoding
headers Message header field
table
Delivery-mode Non-persistent (1) or
persistent (2)
priority Message priority, 0 to
9
Correlation-id Application
correlation identifier
Reply-to Address to reply to
expiration Message expiration
specification
Message-id Application message
identifier
timestamp Message timestamp
type Message type name
User-id Creating user id
App-id Creating application
id
reserved Reserved, must be
empty
PGDay.IT 2015 – 23 Ottobre 2015 - Prato 17 di 33
Producer - ConsumerProducer - Consumer
Producer: a program that sends messages
Queus: a “buffer” where messages are stored
Consumer: a program that waits to receive messages
PGDay.IT 2015 – 23 Ottobre 2015 - Prato 18 di 33
Work queuesWork queues
Work  Queue:  it  is  used  to  distribute  tasks  among  multiple 
workers.
Tasks will be shared between workers
Useful  in  web  applications  where  it's  impossible  to  handle  a 
complex task during a short HTTP request window
PGDay.IT 2015 – 23 Ottobre 2015 - Prato 19 di 33
Publish/SubscribePublish/Subscribe
Deliver a message to multiple consumers (messages are going 
to be broadcast to all the receivers.)
The exchange must know exactly what to do with a message it 
receives (rules for that are defined by the exchange type)
PGDay.IT 2015 – 23 Ottobre 2015 - Prato 20 di 33
Exchange typesExchange types
Direct: the binding key must match the routing key exactly – no 
wildcard support
Fanout:  it  broadcasts  all  the  messages  it  receives  to  all  the 
queues it knows
Topic: same as Direct, but wildcards are allowed in the binding 
key
Headers:  no  routing  key,  string  matching  in  the  message 
headers property
PGDay.IT 2015 – 23 Ottobre 2015 - Prato 21 di 33
pg_amqppg_amqp
Amqp client for Postgresql
Allow Postgresql to communicate with other components in the 
architecture
Stable
Suggested version 9.x, but it can works too with older versions
http://pgxn.org/dist/pg_amqp/
https://github.com/omniti­labs/pg_amqp
PGDay.IT 2015 – 23 Ottobre 2015 - Prato 22 di 33
How to install pg_ampq (v0.3.0)How to install pg_ampq (v0.3.0)
Wget http://api.pgxn.org/dist/pg_amqp/0.3.0/pg_amqp­0.3.0.zip 
Cd pg_ampq­0.3.0
Make
Make install
env PG_CONFIG=/path/to/pg_config make && make install
shared_preload_libraries = 'pg_amqp.so'   postgresql.conf→
CREATE EXTENSION amqp; (Postgresql >= 9.1)
psql  ­d  mydb  ­f  /path/to/pgsql/share/contrib/amqp.sql 
(Postgresql < 9.1)
PGDay.IT 2015 – 23 Ottobre 2015 - Prato 23 di 33
pg_amqp (v 0.4.0)pg_amqp (v 0.4.0)
Only supported as a PostgreSQL Extension
PG  versions  prior  to  9.1  and  means  to  install  it  without  the 
extension system are no longer officially supported.
Added support for upgrading extension installation from 0.3.0 
to 0.4.0
Add  support  for  amqp  message  properties  (delivery_mode, 
content_type, reply_to and correlation_id)
PGDay.IT 2015 – 23 Ottobre 2015 - Prato 24 di 33
SetupSetup
Insert AMQP broker information into the`amqp.broker` table
Insert  into  ampq.broker(host,port,vhost,username,password) 
values (localhost,'5432',null,'myuser','mypassword')
PGDay.IT 2015 – 23 Ottobre 2015 - Prato 25 di 33
How it worksHow it works
A process starts and connects to PostgreSQL and runs:
SELECT  amqp.publish(broker_id,  'amqp.direct',  'routing­key', 
'message');
snprintf(sql, sizeof(sql), "
 SELECT host, port, vhost, username, password "
 "  FROM amqp.broker "
 " WHERE broker_id = %d "
 " ORDER BY host DESC, port", broker_id);
PGDay.IT 2015 – 23 Ottobre 2015 - Prato 26 di 33
DisconnectDisconnect
In case of needing to disconnect from a specific broker
select amqp.disconnect(broker_id);
do nothing if it is already disconnected
PGDay.IT 2015 – 23 Ottobre 2015 - Prato 27 di 33
PostgreSQL LISTEN ExchangePostgreSQL LISTEN Exchange
A  RabbitMQ  exchange  type  that  translates  PostgreSQL 
NOTIFY messages to AMQP messages and publishes them to 
bound queues
Require Postgresql >= 9.0
Rabbitmq plugin so unobtrusive to Postgresql environment
https://github.com/aweber/pgsql­listen­exchange
PGDay.IT 2015 – 23 Ottobre 2015 - Prato 28 di 33
Installation & configurationInstallation & configuration
Unzip file into your RabbitMQ plugins directory
rabbitmq­plugins enable pgsql_listen_exchange
To  connect  to  PostgreSQL  using  the  default 
pgsql://postgres@localhost:5432/postgres
Edit rabbitmq.properties
[{pgsql_listen_exchange,
[
{host, "localhost"},
{port, 5432},
{dbname, "postgres"},
{user, "postgres"},
{password, ""}
]}
].
PGDay.IT 2015 – 23 Ottobre 2015 - Prato 29 di 33
Send a notifcationSend a notifcation
Psql (9.4.1)
postgres=# NOTIFY channel_name, 'This is a test';
PGDay.IT 2015 – 23 Ottobre 2015 - Prato 30 di 33
Receive a notificationReceive a notification
Psql (9.4.1)
Postgresl=# listen channel_name
PGDay.IT 2015 – 23 Ottobre 2015 - Prato 31 di 33
ResourcesResources
http://www.rabbitmq.com
http://blogs.vmware.com/vfabric/2013/02/choosing­your­m
http://interlinked.org/tutorials/postgresql.html
PGDay.IT 2015 – 23 Ottobre 2015 - Prato 32 di 33
Questions?Questions?
PGDay.IT 2015 – 23 Ottobre 2015 - Prato 33 di 33

Contenu connexe

Tendances

The RabbitMQ Message Broker
The RabbitMQ Message BrokerThe RabbitMQ Message Broker
The RabbitMQ Message BrokerMartin Toshev
 
RabbitMQ fairly-indepth
RabbitMQ fairly-indepthRabbitMQ fairly-indepth
RabbitMQ fairly-indepthWee Keat Chin
 
Introducing Kafka-on-Pulsar: bring native Kafka protocol support to Apache Pu...
Introducing Kafka-on-Pulsar: bring native Kafka protocol support to Apache Pu...Introducing Kafka-on-Pulsar: bring native Kafka protocol support to Apache Pu...
Introducing Kafka-on-Pulsar: bring native Kafka protocol support to Apache Pu...StreamNative
 
Alvaro Videla, Building a Distributed Data Ingestion System with RabbitMQ
Alvaro Videla, Building a Distributed Data Ingestion System with RabbitMQAlvaro Videla, Building a Distributed Data Ingestion System with RabbitMQ
Alvaro Videla, Building a Distributed Data Ingestion System with RabbitMQTanya Denisyuk
 
Apache Kafka: A high-throughput distributed messaging system @ JCConf 2014
Apache Kafka: A high-throughput distributed messaging system @ JCConf 2014Apache Kafka: A high-throughput distributed messaging system @ JCConf 2014
Apache Kafka: A high-throughput distributed messaging system @ JCConf 2014Chen-en Lu
 
MoP(MQTT on Pulsar) - a Powerful Tool for Apache Pulsar in IoT - Pulsar Summi...
MoP(MQTT on Pulsar) - a Powerful Tool for Apache Pulsar in IoT - Pulsar Summi...MoP(MQTT on Pulsar) - a Powerful Tool for Apache Pulsar in IoT - Pulsar Summi...
MoP(MQTT on Pulsar) - a Powerful Tool for Apache Pulsar in IoT - Pulsar Summi...StreamNative
 
Introduction to AMQP Messaging with RabbitMQ
Introduction to AMQP Messaging with RabbitMQIntroduction to AMQP Messaging with RabbitMQ
Introduction to AMQP Messaging with RabbitMQDmitriy Samovskiy
 
Scaling application with RabbitMQ
Scaling application with RabbitMQScaling application with RabbitMQ
Scaling application with RabbitMQNahidul Kibria
 
Messaging Standards and Systems - AMQP & RabbitMQ
Messaging Standards and Systems - AMQP & RabbitMQMessaging Standards and Systems - AMQP & RabbitMQ
Messaging Standards and Systems - AMQP & RabbitMQAll Things Open
 
An update from the RabbitMQ team - Michael Klishin
An update from the RabbitMQ team - Michael KlishinAn update from the RabbitMQ team - Michael Klishin
An update from the RabbitMQ team - Michael KlishinRabbitMQ Summit
 
Messaging Standards and Systems - AMQP & RabbitMQ
Messaging Standards and Systems - AMQP & RabbitMQMessaging Standards and Systems - AMQP & RabbitMQ
Messaging Standards and Systems - AMQP & RabbitMQPOSSCON
 
Improving Kafka at-least-once performance at Uber
Improving Kafka at-least-once performance at UberImproving Kafka at-least-once performance at Uber
Improving Kafka at-least-once performance at UberYing Zheng
 
Real time system_performance_mon
Real time system_performance_monReal time system_performance_mon
Real time system_performance_monTomas Doran
 
Practical Message Queuing Using RabbitMQ (PHPem, 3rd July 2014)
Practical Message Queuing Using RabbitMQ (PHPem, 3rd July 2014)Practical Message Queuing Using RabbitMQ (PHPem, 3rd July 2014)
Practical Message Queuing Using RabbitMQ (PHPem, 3rd July 2014)James Titcumb
 
Modern Distributed Messaging and RPC
Modern Distributed Messaging and RPCModern Distributed Messaging and RPC
Modern Distributed Messaging and RPCMax Alexejev
 
Full Stack Bus with Javascript, RabbitMQ and Postal.js
Full Stack Bus with Javascript, RabbitMQ and Postal.jsFull Stack Bus with Javascript, RabbitMQ and Postal.js
Full Stack Bus with Javascript, RabbitMQ and Postal.jsJavier Arias Losada
 

Tendances (20)

The RabbitMQ Message Broker
The RabbitMQ Message BrokerThe RabbitMQ Message Broker
The RabbitMQ Message Broker
 
RabbitMQ fairly-indepth
RabbitMQ fairly-indepthRabbitMQ fairly-indepth
RabbitMQ fairly-indepth
 
AMQP with RabbitMQ
AMQP with RabbitMQAMQP with RabbitMQ
AMQP with RabbitMQ
 
Introducing Kafka-on-Pulsar: bring native Kafka protocol support to Apache Pu...
Introducing Kafka-on-Pulsar: bring native Kafka protocol support to Apache Pu...Introducing Kafka-on-Pulsar: bring native Kafka protocol support to Apache Pu...
Introducing Kafka-on-Pulsar: bring native Kafka protocol support to Apache Pu...
 
Message Broker System and RabbitMQ
Message Broker System and RabbitMQMessage Broker System and RabbitMQ
Message Broker System and RabbitMQ
 
Alvaro Videla, Building a Distributed Data Ingestion System with RabbitMQ
Alvaro Videla, Building a Distributed Data Ingestion System with RabbitMQAlvaro Videla, Building a Distributed Data Ingestion System with RabbitMQ
Alvaro Videla, Building a Distributed Data Ingestion System with RabbitMQ
 
Apache Kafka: A high-throughput distributed messaging system @ JCConf 2014
Apache Kafka: A high-throughput distributed messaging system @ JCConf 2014Apache Kafka: A high-throughput distributed messaging system @ JCConf 2014
Apache Kafka: A high-throughput distributed messaging system @ JCConf 2014
 
MoP(MQTT on Pulsar) - a Powerful Tool for Apache Pulsar in IoT - Pulsar Summi...
MoP(MQTT on Pulsar) - a Powerful Tool for Apache Pulsar in IoT - Pulsar Summi...MoP(MQTT on Pulsar) - a Powerful Tool for Apache Pulsar in IoT - Pulsar Summi...
MoP(MQTT on Pulsar) - a Powerful Tool for Apache Pulsar in IoT - Pulsar Summi...
 
Introduction to AMQP Messaging with RabbitMQ
Introduction to AMQP Messaging with RabbitMQIntroduction to AMQP Messaging with RabbitMQ
Introduction to AMQP Messaging with RabbitMQ
 
Scaling application with RabbitMQ
Scaling application with RabbitMQScaling application with RabbitMQ
Scaling application with RabbitMQ
 
Messaging Standards and Systems - AMQP & RabbitMQ
Messaging Standards and Systems - AMQP & RabbitMQMessaging Standards and Systems - AMQP & RabbitMQ
Messaging Standards and Systems - AMQP & RabbitMQ
 
An update from the RabbitMQ team - Michael Klishin
An update from the RabbitMQ team - Michael KlishinAn update from the RabbitMQ team - Michael Klishin
An update from the RabbitMQ team - Michael Klishin
 
Messaging Standards and Systems - AMQP & RabbitMQ
Messaging Standards and Systems - AMQP & RabbitMQMessaging Standards and Systems - AMQP & RabbitMQ
Messaging Standards and Systems - AMQP & RabbitMQ
 
Spring RabbitMQ
Spring RabbitMQSpring RabbitMQ
Spring RabbitMQ
 
Improving Kafka at-least-once performance at Uber
Improving Kafka at-least-once performance at UberImproving Kafka at-least-once performance at Uber
Improving Kafka at-least-once performance at Uber
 
Real time system_performance_mon
Real time system_performance_monReal time system_performance_mon
Real time system_performance_mon
 
Practical Message Queuing Using RabbitMQ (PHPem, 3rd July 2014)
Practical Message Queuing Using RabbitMQ (PHPem, 3rd July 2014)Practical Message Queuing Using RabbitMQ (PHPem, 3rd July 2014)
Practical Message Queuing Using RabbitMQ (PHPem, 3rd July 2014)
 
Modern Distributed Messaging and RPC
Modern Distributed Messaging and RPCModern Distributed Messaging and RPC
Modern Distributed Messaging and RPC
 
Full Stack Bus with Javascript, RabbitMQ and Postal.js
Full Stack Bus with Javascript, RabbitMQ and Postal.jsFull Stack Bus with Javascript, RabbitMQ and Postal.js
Full Stack Bus with Javascript, RabbitMQ and Postal.js
 
RabbitMQ
RabbitMQRabbitMQ
RabbitMQ
 

En vedette

Django - The Web framework for perfectionists with deadlines
Django - The Web framework for perfectionists with deadlinesDjango - The Web framework for perfectionists with deadlines
Django - The Web framework for perfectionists with deadlinesMarkus Zapke-Gründemann
 
Django e il Rap Elia Contini
Django e il Rap Elia ContiniDjango e il Rap Elia Contini
Django e il Rap Elia ContiniWEBdeBS
 
Super Advanced Python –act1
Super Advanced Python –act1Super Advanced Python –act1
Super Advanced Python –act1Ke Wei Louis
 
NoSql Day - Chiusura
NoSql Day - ChiusuraNoSql Day - Chiusura
NoSql Day - ChiusuraWEBdeBS
 
라이트닝 토크 2015 파이콘
라이트닝 토크 2015 파이콘라이트닝 토크 2015 파이콘
라이트닝 토크 2015 파이콘Jiho Lee
 
2016 py con2016_lightingtalk_php to python
2016 py con2016_lightingtalk_php to python2016 py con2016_lightingtalk_php to python
2016 py con2016_lightingtalk_php to pythonJiho Lee
 
The Django Book Chapter 9 - Django Workshop - Taipei.py
The Django Book Chapter 9 - Django Workshop - Taipei.pyThe Django Book Chapter 9 - Django Workshop - Taipei.py
The Django Book Chapter 9 - Django Workshop - Taipei.pyTzu-ping Chung
 
Django - The Web framework for perfectionists with deadlines
Django - The Web framework  for perfectionists with deadlinesDjango - The Web framework  for perfectionists with deadlines
Django - The Web framework for perfectionists with deadlinesMarkus Zapke-Gründemann
 
Authentication & Authorization in ASPdotNet MVC
Authentication & Authorization in ASPdotNet MVCAuthentication & Authorization in ASPdotNet MVC
Authentication & Authorization in ASPdotNet MVCMindfire Solutions
 
Django mongodb -djangoday_
Django mongodb -djangoday_Django mongodb -djangoday_
Django mongodb -djangoday_WEBdeBS
 
Overview of Testing Talks at Pycon
Overview of Testing Talks at PyconOverview of Testing Talks at Pycon
Overview of Testing Talks at PyconJacqueline Kazil
 

En vedette (20)

Django - The Web framework for perfectionists with deadlines
Django - The Web framework for perfectionists with deadlinesDjango - The Web framework for perfectionists with deadlines
Django - The Web framework for perfectionists with deadlines
 
EuroDjangoCon 2009 - Ein Rückblick
EuroDjangoCon 2009 - Ein RückblickEuroDjangoCon 2009 - Ein Rückblick
EuroDjangoCon 2009 - Ein Rückblick
 
2 × 3 = 6
2 × 3 = 62 × 3 = 6
2 × 3 = 6
 
PythonBrasil[8] closing
PythonBrasil[8] closingPythonBrasil[8] closing
PythonBrasil[8] closing
 
Django e il Rap Elia Contini
Django e il Rap Elia ContiniDjango e il Rap Elia Contini
Django e il Rap Elia Contini
 
Super Advanced Python –act1
Super Advanced Python –act1Super Advanced Python –act1
Super Advanced Python –act1
 
NoSql Day - Chiusura
NoSql Day - ChiusuraNoSql Day - Chiusura
NoSql Day - Chiusura
 
라이트닝 토크 2015 파이콘
라이트닝 토크 2015 파이콘라이트닝 토크 2015 파이콘
라이트닝 토크 2015 파이콘
 
2016 py con2016_lightingtalk_php to python
2016 py con2016_lightingtalk_php to python2016 py con2016_lightingtalk_php to python
2016 py con2016_lightingtalk_php to python
 
Load testing
Load testingLoad testing
Load testing
 
The Django Book Chapter 9 - Django Workshop - Taipei.py
The Django Book Chapter 9 - Django Workshop - Taipei.pyThe Django Book Chapter 9 - Django Workshop - Taipei.py
The Django Book Chapter 9 - Django Workshop - Taipei.py
 
Django - The Web framework for perfectionists with deadlines
Django - The Web framework  for perfectionists with deadlinesDjango - The Web framework  for perfectionists with deadlines
Django - The Web framework for perfectionists with deadlines
 
Authentication & Authorization in ASPdotNet MVC
Authentication & Authorization in ASPdotNet MVCAuthentication & Authorization in ASPdotNet MVC
Authentication & Authorization in ASPdotNet MVC
 
Django-Queryset
Django-QuerysetDjango-Queryset
Django-Queryset
 
Django mongodb -djangoday_
Django mongodb -djangoday_Django mongodb -djangoday_
Django mongodb -djangoday_
 
Vim for Mere Mortals
Vim for Mere MortalsVim for Mere Mortals
Vim for Mere Mortals
 
Bottle - Python Web Microframework
Bottle - Python Web MicroframeworkBottle - Python Web Microframework
Bottle - Python Web Microframework
 
Html5 History-API
Html5 History-APIHtml5 History-API
Html5 History-API
 
Overview of Testing Talks at Pycon
Overview of Testing Talks at PyconOverview of Testing Talks at Pycon
Overview of Testing Talks at Pycon
 
User-centered open source
User-centered open sourceUser-centered open source
User-centered open source
 

Similaire à Rabbitmq & Postgresql

Pulsar summit asia 2021 apache pulsar with mqtt for edge computing
Pulsar summit asia 2021   apache pulsar with mqtt for edge computingPulsar summit asia 2021   apache pulsar with mqtt for edge computing
Pulsar summit asia 2021 apache pulsar with mqtt for edge computingTimothy Spann
 
Apache Pulsar with MQTT for Edge Computing - Pulsar Summit Asia 2021
Apache Pulsar with MQTT for Edge Computing - Pulsar Summit Asia 2021Apache Pulsar with MQTT for Edge Computing - Pulsar Summit Asia 2021
Apache Pulsar with MQTT for Edge Computing - Pulsar Summit Asia 2021StreamNative
 
Inside OpenChange scalable architecture
Inside OpenChange scalable architectureInside OpenChange scalable architecture
Inside OpenChange scalable architectureJulien Kerihuel
 
Monitoring in Big Data Platform - Albert Lewandowski, GetInData
Monitoring in Big Data Platform - Albert Lewandowski, GetInDataMonitoring in Big Data Platform - Albert Lewandowski, GetInData
Monitoring in Big Data Platform - Albert Lewandowski, GetInDataGetInData
 
Powering your next IoT application with MQTT - JavaOne 2014 tutorial
Powering your next IoT application with MQTT - JavaOne 2014 tutorialPowering your next IoT application with MQTT - JavaOne 2014 tutorial
Powering your next IoT application with MQTT - JavaOne 2014 tutorialBenjamin Cabé
 
PyQt Application Development On Maemo
PyQt Application Development On MaemoPyQt Application Development On Maemo
PyQt Application Development On Maemoachipa
 
Functioning incessantly of Data Science Platform with Kubeflow - Albert Lewan...
Functioning incessantly of Data Science Platform with Kubeflow - Albert Lewan...Functioning incessantly of Data Science Platform with Kubeflow - Albert Lewan...
Functioning incessantly of Data Science Platform with Kubeflow - Albert Lewan...GetInData
 
Matteo Murgida - Monet: a NodeJS enterprise system for IoT and Energy Managem...
Matteo Murgida - Monet: a NodeJS enterprise system for IoT and Energy Managem...Matteo Murgida - Monet: a NodeJS enterprise system for IoT and Energy Managem...
Matteo Murgida - Monet: a NodeJS enterprise system for IoT and Energy Managem...Codemotion
 
MuleSoft Meetup Roma - Processi di Automazione su CloudHub
MuleSoft Meetup Roma - Processi di Automazione su CloudHubMuleSoft Meetup Roma - Processi di Automazione su CloudHub
MuleSoft Meetup Roma - Processi di Automazione su CloudHubAlfonso Martino
 
Network-Connected Development with ZeroMQ
Network-Connected Development with ZeroMQNetwork-Connected Development with ZeroMQ
Network-Connected Development with ZeroMQICS
 
MQTT and SensorThings API MQTT Extension
MQTT and SensorThings API MQTT ExtensionMQTT and SensorThings API MQTT Extension
MQTT and SensorThings API MQTT ExtensionSensorUp
 
IoT with Ruby/mruby - RubyWorld Conference 2015
IoT with Ruby/mruby - RubyWorld Conference 2015IoT with Ruby/mruby - RubyWorld Conference 2015
IoT with Ruby/mruby - RubyWorld Conference 2015哲也 廣田
 
Big mountain data and dev conference apache pulsar with mqtt for edge compu...
Big mountain data and dev conference   apache pulsar with mqtt for edge compu...Big mountain data and dev conference   apache pulsar with mqtt for edge compu...
Big mountain data and dev conference apache pulsar with mqtt for edge compu...Timothy Spann
 
Designing for Interoperability
Designing for InteroperabilityDesigning for Interoperability
Designing for InteroperabilityAllSeen Alliance
 
RTBkit Meetup - Developer Spotlight, Behind the Scenes of RTBkit and Intro to...
RTBkit Meetup - Developer Spotlight, Behind the Scenes of RTBkit and Intro to...RTBkit Meetup - Developer Spotlight, Behind the Scenes of RTBkit and Intro to...
RTBkit Meetup - Developer Spotlight, Behind the Scenes of RTBkit and Intro to...Datacratic
 
REST in Peace. Long live gRPC!
REST in Peace. Long live gRPC!REST in Peace. Long live gRPC!
REST in Peace. Long live gRPC!QAware GmbH
 
Industry 4.0: Building the Unified Namespace with Confluent, HiveMQ and Spark...
Industry 4.0: Building the Unified Namespace with Confluent, HiveMQ and Spark...Industry 4.0: Building the Unified Namespace with Confluent, HiveMQ and Spark...
Industry 4.0: Building the Unified Namespace with Confluent, HiveMQ and Spark...confluent
 
Fluent 2018: When third parties stop being polite... and start getting real
Fluent 2018: When third parties stop being polite... and start getting realFluent 2018: When third parties stop being polite... and start getting real
Fluent 2018: When third parties stop being polite... and start getting realAkamai Developers & Admins
 

Similaire à Rabbitmq & Postgresql (20)

Pulsar summit asia 2021 apache pulsar with mqtt for edge computing
Pulsar summit asia 2021   apache pulsar with mqtt for edge computingPulsar summit asia 2021   apache pulsar with mqtt for edge computing
Pulsar summit asia 2021 apache pulsar with mqtt for edge computing
 
Apache Pulsar with MQTT for Edge Computing - Pulsar Summit Asia 2021
Apache Pulsar with MQTT for Edge Computing - Pulsar Summit Asia 2021Apache Pulsar with MQTT for Edge Computing - Pulsar Summit Asia 2021
Apache Pulsar with MQTT for Edge Computing - Pulsar Summit Asia 2021
 
Inside OpenChange scalable architecture
Inside OpenChange scalable architectureInside OpenChange scalable architecture
Inside OpenChange scalable architecture
 
Monitoring in Big Data Platform - Albert Lewandowski, GetInData
Monitoring in Big Data Platform - Albert Lewandowski, GetInDataMonitoring in Big Data Platform - Albert Lewandowski, GetInData
Monitoring in Big Data Platform - Albert Lewandowski, GetInData
 
Powering your next IoT application with MQTT - JavaOne 2014 tutorial
Powering your next IoT application with MQTT - JavaOne 2014 tutorialPowering your next IoT application with MQTT - JavaOne 2014 tutorial
Powering your next IoT application with MQTT - JavaOne 2014 tutorial
 
PyQt Application Development On Maemo
PyQt Application Development On MaemoPyQt Application Development On Maemo
PyQt Application Development On Maemo
 
Functioning incessantly of Data Science Platform with Kubeflow - Albert Lewan...
Functioning incessantly of Data Science Platform with Kubeflow - Albert Lewan...Functioning incessantly of Data Science Platform with Kubeflow - Albert Lewan...
Functioning incessantly of Data Science Platform with Kubeflow - Albert Lewan...
 
Matteo Murgida - Monet: a NodeJS enterprise system for IoT and Energy Managem...
Matteo Murgida - Monet: a NodeJS enterprise system for IoT and Energy Managem...Matteo Murgida - Monet: a NodeJS enterprise system for IoT and Energy Managem...
Matteo Murgida - Monet: a NodeJS enterprise system for IoT and Energy Managem...
 
Docker Monitoring Webinar
Docker Monitoring  WebinarDocker Monitoring  Webinar
Docker Monitoring Webinar
 
MuleSoft Meetup Roma - Processi di Automazione su CloudHub
MuleSoft Meetup Roma - Processi di Automazione su CloudHubMuleSoft Meetup Roma - Processi di Automazione su CloudHub
MuleSoft Meetup Roma - Processi di Automazione su CloudHub
 
Network-Connected Development with ZeroMQ
Network-Connected Development with ZeroMQNetwork-Connected Development with ZeroMQ
Network-Connected Development with ZeroMQ
 
MQTT and SensorThings API MQTT Extension
MQTT and SensorThings API MQTT ExtensionMQTT and SensorThings API MQTT Extension
MQTT and SensorThings API MQTT Extension
 
IoT with Ruby/mruby - RubyWorld Conference 2015
IoT with Ruby/mruby - RubyWorld Conference 2015IoT with Ruby/mruby - RubyWorld Conference 2015
IoT with Ruby/mruby - RubyWorld Conference 2015
 
Deep dive into serverless on Google Cloud
Deep dive into serverless on Google CloudDeep dive into serverless on Google Cloud
Deep dive into serverless on Google Cloud
 
Big mountain data and dev conference apache pulsar with mqtt for edge compu...
Big mountain data and dev conference   apache pulsar with mqtt for edge compu...Big mountain data and dev conference   apache pulsar with mqtt for edge compu...
Big mountain data and dev conference apache pulsar with mqtt for edge compu...
 
Designing for Interoperability
Designing for InteroperabilityDesigning for Interoperability
Designing for Interoperability
 
RTBkit Meetup - Developer Spotlight, Behind the Scenes of RTBkit and Intro to...
RTBkit Meetup - Developer Spotlight, Behind the Scenes of RTBkit and Intro to...RTBkit Meetup - Developer Spotlight, Behind the Scenes of RTBkit and Intro to...
RTBkit Meetup - Developer Spotlight, Behind the Scenes of RTBkit and Intro to...
 
REST in Peace. Long live gRPC!
REST in Peace. Long live gRPC!REST in Peace. Long live gRPC!
REST in Peace. Long live gRPC!
 
Industry 4.0: Building the Unified Namespace with Confluent, HiveMQ and Spark...
Industry 4.0: Building the Unified Namespace with Confluent, HiveMQ and Spark...Industry 4.0: Building the Unified Namespace with Confluent, HiveMQ and Spark...
Industry 4.0: Building the Unified Namespace with Confluent, HiveMQ and Spark...
 
Fluent 2018: When third parties stop being polite... and start getting real
Fluent 2018: When third parties stop being polite... and start getting realFluent 2018: When third parties stop being polite... and start getting real
Fluent 2018: When third parties stop being polite... and start getting real
 

Plus de Lucio Grenzi

How to use Postgresql in order to handle Prometheus metrics storage
How to use Postgresql in order to handle Prometheus metrics storageHow to use Postgresql in order to handle Prometheus metrics storage
How to use Postgresql in order to handle Prometheus metrics storageLucio Grenzi
 
Building serverless application on the Apache Openwhisk platform
Building serverless application on the Apache Openwhisk platformBuilding serverless application on the Apache Openwhisk platform
Building serverless application on the Apache Openwhisk platformLucio Grenzi
 
Patroni: PostgreSQL HA in the cloud
Patroni: PostgreSQL HA in the cloudPatroni: PostgreSQL HA in the cloud
Patroni: PostgreSQL HA in the cloudLucio Grenzi
 
Postgrest: the REST API for PostgreSQL databases
Postgrest: the REST API for PostgreSQL databasesPostgrest: the REST API for PostgreSQL databases
Postgrest: the REST API for PostgreSQL databasesLucio Grenzi
 
Use Ionic Framework to develop mobile application
Use Ionic Framework to develop mobile applicationUse Ionic Framework to develop mobile application
Use Ionic Framework to develop mobile applicationLucio Grenzi
 
Jenkins djangovillage
Jenkins djangovillageJenkins djangovillage
Jenkins djangovillageLucio Grenzi
 
Geodjango and HTML 5
Geodjango and HTML 5Geodjango and HTML 5
Geodjango and HTML 5Lucio Grenzi
 
PLV8 - The PostgreSQL web side
PLV8 - The PostgreSQL web sidePLV8 - The PostgreSQL web side
PLV8 - The PostgreSQL web sideLucio Grenzi
 
node.js e Postgresql
node.js e Postgresqlnode.js e Postgresql
node.js e PostgresqlLucio Grenzi
 

Plus de Lucio Grenzi (13)

How to use Postgresql in order to handle Prometheus metrics storage
How to use Postgresql in order to handle Prometheus metrics storageHow to use Postgresql in order to handle Prometheus metrics storage
How to use Postgresql in order to handle Prometheus metrics storage
 
Building serverless application on the Apache Openwhisk platform
Building serverless application on the Apache Openwhisk platformBuilding serverless application on the Apache Openwhisk platform
Building serverless application on the Apache Openwhisk platform
 
Patroni: PostgreSQL HA in the cloud
Patroni: PostgreSQL HA in the cloudPatroni: PostgreSQL HA in the cloud
Patroni: PostgreSQL HA in the cloud
 
Postgrest: the REST API for PostgreSQL databases
Postgrest: the REST API for PostgreSQL databasesPostgrest: the REST API for PostgreSQL databases
Postgrest: the REST API for PostgreSQL databases
 
Full slidescr16
Full slidescr16Full slidescr16
Full slidescr16
 
Use Ionic Framework to develop mobile application
Use Ionic Framework to develop mobile applicationUse Ionic Framework to develop mobile application
Use Ionic Framework to develop mobile application
 
Jenkins djangovillage
Jenkins djangovillageJenkins djangovillage
Jenkins djangovillage
 
Geodjango and HTML 5
Geodjango and HTML 5Geodjango and HTML 5
Geodjango and HTML 5
 
PLV8 - The PostgreSQL web side
PLV8 - The PostgreSQL web sidePLV8 - The PostgreSQL web side
PLV8 - The PostgreSQL web side
 
Pg tap
Pg tapPg tap
Pg tap
 
Geodjango
GeodjangoGeodjango
Geodjango
 
Yui app-framework
Yui app-frameworkYui app-framework
Yui app-framework
 
node.js e Postgresql
node.js e Postgresqlnode.js e Postgresql
node.js e Postgresql
 

Dernier

Boost PC performance: How more available memory can improve productivity
Boost PC performance: How more available memory can improve productivityBoost PC performance: How more available memory can improve productivity
Boost PC performance: How more available memory can improve productivityPrincipled Technologies
 
Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...
Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...
Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...Drew Madelung
 
Scaling API-first – The story of a global engineering organization
Scaling API-first – The story of a global engineering organizationScaling API-first – The story of a global engineering organization
Scaling API-first – The story of a global engineering organizationRadu Cotescu
 
08448380779 Call Girls In Greater Kailash - I Women Seeking Men
08448380779 Call Girls In Greater Kailash - I Women Seeking Men08448380779 Call Girls In Greater Kailash - I Women Seeking Men
08448380779 Call Girls In Greater Kailash - I Women Seeking MenDelhi Call girls
 
[2024]Digital Global Overview Report 2024 Meltwater.pdf
[2024]Digital Global Overview Report 2024 Meltwater.pdf[2024]Digital Global Overview Report 2024 Meltwater.pdf
[2024]Digital Global Overview Report 2024 Meltwater.pdfhans926745
 
Top 5 Benefits OF Using Muvi Live Paywall For Live Streams
Top 5 Benefits OF Using Muvi Live Paywall For Live StreamsTop 5 Benefits OF Using Muvi Live Paywall For Live Streams
Top 5 Benefits OF Using Muvi Live Paywall For Live StreamsRoshan Dwivedi
 
A Call to Action for Generative AI in 2024
A Call to Action for Generative AI in 2024A Call to Action for Generative AI in 2024
A Call to Action for Generative AI in 2024Results
 
EIS-Webinar-Prompt-Knowledge-Eng-2024-04-08.pptx
EIS-Webinar-Prompt-Knowledge-Eng-2024-04-08.pptxEIS-Webinar-Prompt-Knowledge-Eng-2024-04-08.pptx
EIS-Webinar-Prompt-Knowledge-Eng-2024-04-08.pptxEarley Information Science
 
Slack Application Development 101 Slides
Slack Application Development 101 SlidesSlack Application Development 101 Slides
Slack Application Development 101 Slidespraypatel2
 
Tata AIG General Insurance Company - Insurer Innovation Award 2024
Tata AIG General Insurance Company - Insurer Innovation Award 2024Tata AIG General Insurance Company - Insurer Innovation Award 2024
Tata AIG General Insurance Company - Insurer Innovation Award 2024The Digital Insurer
 
The Role of Taxonomy and Ontology in Semantic Layers - Heather Hedden.pdf
The Role of Taxonomy and Ontology in Semantic Layers - Heather Hedden.pdfThe Role of Taxonomy and Ontology in Semantic Layers - Heather Hedden.pdf
The Role of Taxonomy and Ontology in Semantic Layers - Heather Hedden.pdfEnterprise Knowledge
 
A Domino Admins Adventures (Engage 2024)
A Domino Admins Adventures (Engage 2024)A Domino Admins Adventures (Engage 2024)
A Domino Admins Adventures (Engage 2024)Gabriella Davis
 
🐬 The future of MySQL is Postgres 🐘
🐬  The future of MySQL is Postgres   🐘🐬  The future of MySQL is Postgres   🐘
🐬 The future of MySQL is Postgres 🐘RTylerCroy
 
From Event to Action: Accelerate Your Decision Making with Real-Time Automation
From Event to Action: Accelerate Your Decision Making with Real-Time AutomationFrom Event to Action: Accelerate Your Decision Making with Real-Time Automation
From Event to Action: Accelerate Your Decision Making with Real-Time AutomationSafe Software
 
Salesforce Community Group Quito, Salesforce 101
Salesforce Community Group Quito, Salesforce 101Salesforce Community Group Quito, Salesforce 101
Salesforce Community Group Quito, Salesforce 101Paola De la Torre
 
Kalyanpur ) Call Girls in Lucknow Finest Escorts Service 🍸 8923113531 🎰 Avail...
Kalyanpur ) Call Girls in Lucknow Finest Escorts Service 🍸 8923113531 🎰 Avail...Kalyanpur ) Call Girls in Lucknow Finest Escorts Service 🍸 8923113531 🎰 Avail...
Kalyanpur ) Call Girls in Lucknow Finest Escorts Service 🍸 8923113531 🎰 Avail...gurkirankumar98700
 
How to Troubleshoot Apps for the Modern Connected Worker
How to Troubleshoot Apps for the Modern Connected WorkerHow to Troubleshoot Apps for the Modern Connected Worker
How to Troubleshoot Apps for the Modern Connected WorkerThousandEyes
 
WhatsApp 9892124323 ✓Call Girls In Kalyan ( Mumbai ) secure service
WhatsApp 9892124323 ✓Call Girls In Kalyan ( Mumbai ) secure serviceWhatsApp 9892124323 ✓Call Girls In Kalyan ( Mumbai ) secure service
WhatsApp 9892124323 ✓Call Girls In Kalyan ( Mumbai ) secure servicePooja Nehwal
 
Unblocking The Main Thread Solving ANRs and Frozen Frames
Unblocking The Main Thread Solving ANRs and Frozen FramesUnblocking The Main Thread Solving ANRs and Frozen Frames
Unblocking The Main Thread Solving ANRs and Frozen FramesSinan KOZAK
 
Exploring the Future Potential of AI-Enabled Smartphone Processors
Exploring the Future Potential of AI-Enabled Smartphone ProcessorsExploring the Future Potential of AI-Enabled Smartphone Processors
Exploring the Future Potential of AI-Enabled Smartphone Processorsdebabhi2
 

Dernier (20)

Boost PC performance: How more available memory can improve productivity
Boost PC performance: How more available memory can improve productivityBoost PC performance: How more available memory can improve productivity
Boost PC performance: How more available memory can improve productivity
 
Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...
Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...
Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...
 
Scaling API-first – The story of a global engineering organization
Scaling API-first – The story of a global engineering organizationScaling API-first – The story of a global engineering organization
Scaling API-first – The story of a global engineering organization
 
08448380779 Call Girls In Greater Kailash - I Women Seeking Men
08448380779 Call Girls In Greater Kailash - I Women Seeking Men08448380779 Call Girls In Greater Kailash - I Women Seeking Men
08448380779 Call Girls In Greater Kailash - I Women Seeking Men
 
[2024]Digital Global Overview Report 2024 Meltwater.pdf
[2024]Digital Global Overview Report 2024 Meltwater.pdf[2024]Digital Global Overview Report 2024 Meltwater.pdf
[2024]Digital Global Overview Report 2024 Meltwater.pdf
 
Top 5 Benefits OF Using Muvi Live Paywall For Live Streams
Top 5 Benefits OF Using Muvi Live Paywall For Live StreamsTop 5 Benefits OF Using Muvi Live Paywall For Live Streams
Top 5 Benefits OF Using Muvi Live Paywall For Live Streams
 
A Call to Action for Generative AI in 2024
A Call to Action for Generative AI in 2024A Call to Action for Generative AI in 2024
A Call to Action for Generative AI in 2024
 
EIS-Webinar-Prompt-Knowledge-Eng-2024-04-08.pptx
EIS-Webinar-Prompt-Knowledge-Eng-2024-04-08.pptxEIS-Webinar-Prompt-Knowledge-Eng-2024-04-08.pptx
EIS-Webinar-Prompt-Knowledge-Eng-2024-04-08.pptx
 
Slack Application Development 101 Slides
Slack Application Development 101 SlidesSlack Application Development 101 Slides
Slack Application Development 101 Slides
 
Tata AIG General Insurance Company - Insurer Innovation Award 2024
Tata AIG General Insurance Company - Insurer Innovation Award 2024Tata AIG General Insurance Company - Insurer Innovation Award 2024
Tata AIG General Insurance Company - Insurer Innovation Award 2024
 
The Role of Taxonomy and Ontology in Semantic Layers - Heather Hedden.pdf
The Role of Taxonomy and Ontology in Semantic Layers - Heather Hedden.pdfThe Role of Taxonomy and Ontology in Semantic Layers - Heather Hedden.pdf
The Role of Taxonomy and Ontology in Semantic Layers - Heather Hedden.pdf
 
A Domino Admins Adventures (Engage 2024)
A Domino Admins Adventures (Engage 2024)A Domino Admins Adventures (Engage 2024)
A Domino Admins Adventures (Engage 2024)
 
🐬 The future of MySQL is Postgres 🐘
🐬  The future of MySQL is Postgres   🐘🐬  The future of MySQL is Postgres   🐘
🐬 The future of MySQL is Postgres 🐘
 
From Event to Action: Accelerate Your Decision Making with Real-Time Automation
From Event to Action: Accelerate Your Decision Making with Real-Time AutomationFrom Event to Action: Accelerate Your Decision Making with Real-Time Automation
From Event to Action: Accelerate Your Decision Making with Real-Time Automation
 
Salesforce Community Group Quito, Salesforce 101
Salesforce Community Group Quito, Salesforce 101Salesforce Community Group Quito, Salesforce 101
Salesforce Community Group Quito, Salesforce 101
 
Kalyanpur ) Call Girls in Lucknow Finest Escorts Service 🍸 8923113531 🎰 Avail...
Kalyanpur ) Call Girls in Lucknow Finest Escorts Service 🍸 8923113531 🎰 Avail...Kalyanpur ) Call Girls in Lucknow Finest Escorts Service 🍸 8923113531 🎰 Avail...
Kalyanpur ) Call Girls in Lucknow Finest Escorts Service 🍸 8923113531 🎰 Avail...
 
How to Troubleshoot Apps for the Modern Connected Worker
How to Troubleshoot Apps for the Modern Connected WorkerHow to Troubleshoot Apps for the Modern Connected Worker
How to Troubleshoot Apps for the Modern Connected Worker
 
WhatsApp 9892124323 ✓Call Girls In Kalyan ( Mumbai ) secure service
WhatsApp 9892124323 ✓Call Girls In Kalyan ( Mumbai ) secure serviceWhatsApp 9892124323 ✓Call Girls In Kalyan ( Mumbai ) secure service
WhatsApp 9892124323 ✓Call Girls In Kalyan ( Mumbai ) secure service
 
Unblocking The Main Thread Solving ANRs and Frozen Frames
Unblocking The Main Thread Solving ANRs and Frozen FramesUnblocking The Main Thread Solving ANRs and Frozen Frames
Unblocking The Main Thread Solving ANRs and Frozen Frames
 
Exploring the Future Potential of AI-Enabled Smartphone Processors
Exploring the Future Potential of AI-Enabled Smartphone ProcessorsExploring the Future Potential of AI-Enabled Smartphone Processors
Exploring the Future Potential of AI-Enabled Smartphone Processors
 

Rabbitmq & Postgresql

  • 1. PGDay.IT 2015 – 23 Ottobre 2015 - Prato 1 di 33 Rabbitmq & Postgresql Lucio Grenzi l.grenzi@gmail.com
  • 2. PGDay.IT 2015 – 23 Ottobre 2015 - Prato 2 di 33 Who is this guy? Delphi developer since 1999 IT Consultant  Front end web developer Postgresql addicted       Nonantolando.blogspot.com       lucio.grenzi       lucio grenzi
  • 3. PGDay.IT 2015 – 23 Ottobre 2015 - Prato 3 di 33 AgendaAgenda  Messaging system  Rabbitmq introduction  Postgresql and pg_amqp  PostgreSQL Listen exchange
  • 4. PGDay.IT 2015 – 23 Ottobre 2015 - Prato 4 di 33 Message-oriented middlewareMessage-oriented middleware Message­oriented middleware (MOM) is software or hardware  infrastructure  supporting  sending  and  receiving  messages  between distributed systems. MOM allows application modules  to  be  distributed  over  heterogeneous  platforms  and  reduces  the  complexity  of  developing  applications  that  span  multiple  operating systems and network protocols ­ https://en.wikipedia.org/wiki/Message­oriented_middleware ­
  • 5. PGDay.IT 2015 – 23 Ottobre 2015 - Prato 5 di 33 Why Should I use MOM?Why Should I use MOM? Need to scale Monitoring data feeds Need things done in order Use the cloud Decoupling  applications  by  separating  sending  and  receiving  data Messaging is asynchronous
  • 6. PGDay.IT 2015 – 23 Ottobre 2015 - Prato 6 di 33 Different protocolsDifferent protocols Historically,  message  queuing  has  used  proprietary,  closed  protocols By the time three standards have emerged which are used in  open source message queue implementations: Advanced Message Queuing Protocol (AMQP) Streaming Text Oriented Messaging Protocol (STOMP) MQ Telemetry Transport (MQTT)
  • 7. PGDay.IT 2015 – 23 Ottobre 2015 - Prato 7 di 33 STOMPSTOMP Text based Like  AMQP,  STOMP  provides  a  message  header  with  properties, and a frame body Does not deal in queues and topics The  broker  must  map  onto  something  that  it  understands  internally such as a topic, queue, or exchange Destinations  are  not  mandated  in  the  specification,  different  brokers may support different flavours of destination
  • 8. PGDay.IT 2015 – 23 Ottobre 2015 - Prato 8 di 33 STOMP BrokerSTOMP Broker Apache ActiveMQ HornetQ Net::STOMP::Client  (an  open  source  client  implementation  in  Perl) Open Message Queue (OpenMQ) RabbitMQ (message broker, has support for STOMP) Ruby server, also known as stompserver http://stomp.github.io/implementations.html
  • 9. PGDay.IT 2015 – 23 Ottobre 2015 - Prato 9 di 33 AMQPAMQP Designed for interoperability between different vendors wide range of features related to messaging Lot of fine­grained control possible with such a rich feature set
  • 10. PGDay.IT 2015 – 23 Ottobre 2015 - Prato 10 di 33 Protocol implementationsProtocol implementations Amqp  :SwiftMQ,  Apache  Qpid,  Apache  MQ,  Apache Apollo, RabbitMQ Stomp:  Apache  MQ,  Apache  Apollo,  RabbitMQ,  HornetQ,  Stampy  (http://stomp.github.io/implementations.html#STOM P_Servers) MQTT:  Apache  MQ,  Apache  Apollo,  RabbitMQ,  mosquitto, WebSphereMQ, HiveMQ, IBM Message  Sight  (https://github.com/mqtt/mqtt.github.io/wiki/server­ support)
  • 11. PGDay.IT 2015 – 23 Ottobre 2015 - Prato 11 di 33 MQTTMQTT Originally developed out of IBM’s pervasive computing team Provides publish­and­subscribe messaging  Publish = data to topics  Subscribe = get data from topics Designed for resource­constrained devices and low bandwidth,  high latency networks (ideal for mobile and “Internet of Things”) MQTT’s strengths are simplicity (just five API methods)
  • 12. PGDay.IT 2015 – 23 Ottobre 2015 - Prato 12 di 33 MQTT BrokerMQTT Broker ActiveMQ,  Apollo JoramMQ Mosquitto RabbitMQ http://www.scalagent.com/IMG/pdf/Benchmark_MQTT_servers ­v1­1.pdf
  • 13. PGDay.IT 2015 – 23 Ottobre 2015 - Prato 13 di 33 RabbitmqRabbitmq open source message broker software (MPL) Actively developed and with commercial support by Pivotal written in Erlang Client libraries to interface with the broker are available for all  major programming languages. Gateways  for  HTTP,  Streaming  Text  Oriented  Messaging  Protocol (STOMP), and MQTT protocols
  • 14. PGDay.IT 2015 – 23 Ottobre 2015 - Prato 14 di 33 Amqp native clientsAmqp native clients .NET PHP Java Python C /C++ Node.js Go Erlang Javascript Ruby Perl Scala Delphi Groovy Cobol Clojure
  • 15. PGDay.IT 2015 – 23 Ottobre 2015 - Prato 15 di 33 Amqp packetAmqp packet Headers Properties Bytea [] data Headers: defined by the Amqp specification Properties: contain arbitrary, application – specific,  information
  • 16. PGDay.IT 2015 – 23 Ottobre 2015 - Prato 16 di 33 Amqp message propertiesAmqp message properties Content-type MIME content type Content-encoding MIME content encoding headers Message header field table Delivery-mode Non-persistent (1) or persistent (2) priority Message priority, 0 to 9 Correlation-id Application correlation identifier Reply-to Address to reply to expiration Message expiration specification Message-id Application message identifier timestamp Message timestamp type Message type name User-id Creating user id App-id Creating application id reserved Reserved, must be empty
  • 17. PGDay.IT 2015 – 23 Ottobre 2015 - Prato 17 di 33 Producer - ConsumerProducer - Consumer Producer: a program that sends messages Queus: a “buffer” where messages are stored Consumer: a program that waits to receive messages
  • 18. PGDay.IT 2015 – 23 Ottobre 2015 - Prato 18 di 33 Work queuesWork queues Work  Queue:  it  is  used  to  distribute  tasks  among  multiple  workers. Tasks will be shared between workers Useful  in  web  applications  where  it's  impossible  to  handle  a  complex task during a short HTTP request window
  • 19. PGDay.IT 2015 – 23 Ottobre 2015 - Prato 19 di 33 Publish/SubscribePublish/Subscribe Deliver a message to multiple consumers (messages are going  to be broadcast to all the receivers.) The exchange must know exactly what to do with a message it  receives (rules for that are defined by the exchange type)
  • 20. PGDay.IT 2015 – 23 Ottobre 2015 - Prato 20 di 33 Exchange typesExchange types Direct: the binding key must match the routing key exactly – no  wildcard support Fanout:  it  broadcasts  all  the  messages  it  receives  to  all  the  queues it knows Topic: same as Direct, but wildcards are allowed in the binding  key Headers:  no  routing  key,  string  matching  in  the  message  headers property
  • 21. PGDay.IT 2015 – 23 Ottobre 2015 - Prato 21 di 33 pg_amqppg_amqp Amqp client for Postgresql Allow Postgresql to communicate with other components in the  architecture Stable Suggested version 9.x, but it can works too with older versions http://pgxn.org/dist/pg_amqp/ https://github.com/omniti­labs/pg_amqp
  • 22. PGDay.IT 2015 – 23 Ottobre 2015 - Prato 22 di 33 How to install pg_ampq (v0.3.0)How to install pg_ampq (v0.3.0) Wget http://api.pgxn.org/dist/pg_amqp/0.3.0/pg_amqp­0.3.0.zip  Cd pg_ampq­0.3.0 Make Make install env PG_CONFIG=/path/to/pg_config make && make install shared_preload_libraries = 'pg_amqp.so'   postgresql.conf→ CREATE EXTENSION amqp; (Postgresql >= 9.1) psql  ­d  mydb  ­f  /path/to/pgsql/share/contrib/amqp.sql  (Postgresql < 9.1)
  • 23. PGDay.IT 2015 – 23 Ottobre 2015 - Prato 23 di 33 pg_amqp (v 0.4.0)pg_amqp (v 0.4.0) Only supported as a PostgreSQL Extension PG  versions  prior  to  9.1  and  means  to  install  it  without  the  extension system are no longer officially supported. Added support for upgrading extension installation from 0.3.0  to 0.4.0 Add  support  for  amqp  message  properties  (delivery_mode,  content_type, reply_to and correlation_id)
  • 24. PGDay.IT 2015 – 23 Ottobre 2015 - Prato 24 di 33 SetupSetup Insert AMQP broker information into the`amqp.broker` table Insert  into  ampq.broker(host,port,vhost,username,password)  values (localhost,'5432',null,'myuser','mypassword')
  • 25. PGDay.IT 2015 – 23 Ottobre 2015 - Prato 25 di 33 How it worksHow it works A process starts and connects to PostgreSQL and runs: SELECT  amqp.publish(broker_id,  'amqp.direct',  'routing­key',  'message'); snprintf(sql, sizeof(sql), "  SELECT host, port, vhost, username, password "  "  FROM amqp.broker "  " WHERE broker_id = %d "  " ORDER BY host DESC, port", broker_id);
  • 26. PGDay.IT 2015 – 23 Ottobre 2015 - Prato 26 di 33 DisconnectDisconnect In case of needing to disconnect from a specific broker select amqp.disconnect(broker_id); do nothing if it is already disconnected
  • 27. PGDay.IT 2015 – 23 Ottobre 2015 - Prato 27 di 33 PostgreSQL LISTEN ExchangePostgreSQL LISTEN Exchange A  RabbitMQ  exchange  type  that  translates  PostgreSQL  NOTIFY messages to AMQP messages and publishes them to  bound queues Require Postgresql >= 9.0 Rabbitmq plugin so unobtrusive to Postgresql environment https://github.com/aweber/pgsql­listen­exchange
  • 28. PGDay.IT 2015 – 23 Ottobre 2015 - Prato 28 di 33 Installation & configurationInstallation & configuration Unzip file into your RabbitMQ plugins directory rabbitmq­plugins enable pgsql_listen_exchange To  connect  to  PostgreSQL  using  the  default  pgsql://postgres@localhost:5432/postgres Edit rabbitmq.properties [{pgsql_listen_exchange, [ {host, "localhost"}, {port, 5432}, {dbname, "postgres"}, {user, "postgres"}, {password, ""} ]} ].
  • 29. PGDay.IT 2015 – 23 Ottobre 2015 - Prato 29 di 33 Send a notifcationSend a notifcation Psql (9.4.1) postgres=# NOTIFY channel_name, 'This is a test';
  • 30. PGDay.IT 2015 – 23 Ottobre 2015 - Prato 30 di 33 Receive a notificationReceive a notification Psql (9.4.1) Postgresl=# listen channel_name
  • 31. PGDay.IT 2015 – 23 Ottobre 2015 - Prato 31 di 33 ResourcesResources http://www.rabbitmq.com http://blogs.vmware.com/vfabric/2013/02/choosing­your­m http://interlinked.org/tutorials/postgresql.html
  • 32. PGDay.IT 2015 – 23 Ottobre 2015 - Prato 32 di 33 Questions?Questions?
  • 33. PGDay.IT 2015 – 23 Ottobre 2015 - Prato 33 di 33