introducing mq light - ibm interconnect 2015 session ame4181
TRANSCRIPT
© 2015 IBM Corporation
AME-4181: Introducing MQ LightRob Nicholson
Alan Chat
Please Note:
• IBM’s statements regarding its plans, directions, and intent are subject to change or
withdrawal without notice at IBM’s sole discretion.
• Information regarding potential future products is intended to outline our general product direction and it should not be relied on in making a purchasing decision.
• The information mentioned regarding potential future products is not a commitment, promise, or legal obligation to deliver any material, code or functionality. Information about potential future products may not be incorporated into any contract.
• The development, release, and timing of any future features or functionality described for our products remains at our sole discretion.
Performance is based on measurements and projections using standard IBM benchmarks in a controlled environment. The actual throughput or performance that any user will experience will vary depending upon many factors, including considerations such as the amount of multiprogramming in the user’s job stream, the I/O configuration, the storage configuration, and the workload processed. Therefore, no assurance can be given that an individual user will achieve results similar to those stated here.
1
Agenda
• High level overview & Positioning.
• MQ Light software
• First Five Minute Experience
• Developer Centric Tooling
• Programming Language Support
• Demo
2
IBM Messaging
Deliver Messaging Backbone for Enterprise
Focus on traditional MQ values, rock-solid enterprise-class service, ease-of-operation, breadth of platform coverage, availability, z/OS exploitation
Enable developers to build more scalable, responsive applications
Focus on app use cases, breadth of languages, ease-of-deployment, micro services, integration with developer frameworks
MQ Light : Software and Cloud
• Messaging that application developers
will love to use, helping them make
responsive applications that scale easily
• 3 ways to get it:
• MQ Light software download
• Bluemix service• Statement of Direction for support in MQ
Version 8.
• Open APIs crafted to feel natural in a
growing range of popular languages
• Tooling that makes modular app
development easy
4
The journey that got us here
5
Andy
Developer
Iain
Infrastructure
Guy
I want to execute code
without taxing my
Web app processes
My job is run a
communications service
for my customers’ apps
Some
Thing
My Apps WorkersMessaging
Backbone
My Customers’ Apps
The journey that got us here…
6
Ruby
Node.js
Python
C
C++
Java
C#
Perl
Go
Clojure
Lua
Erlang Scala
PHP
Use cases
7
Connecting external
systems
Event driven
Worker offload
• Posting video to multiple social
sites after transcoding
• Respond to external events
• Updating external booking app
• Posting updates to twitter
• Image processing
• Text analytics
Trend in Cloud Application Architecture
Moving towards…Delivering global scale applications with
unprecedented agility by de-composing
apps into a microservices architecture
Challenges developing microservices :Agility come from “2 pizza” teams operating completely
independently, owning the whole technology stack,
deploying on their own schedules, writing services
that will scale when demand dictates
8
Large monolithic Applications
Moving away from…Large applications with single develop,
test, deploy cycles using single
technology stacks
Deployment Options
9
MQ Light Service
for Bluemix
WebSphere MQ[open Beta]
“MQ Light”
Agenda
• High level overview & Positioning.
• MQ Light software
• First Five Minute Experience
• Developer Centric Tooling
• Programming Language Support
• Demo
10
First Five minute experience
• Download and get coding within 5 minutes
• Linux-x86-64, Windows7 64 bit, Mac OSX
• Unzip install
• Unlimited time developer license (unsupported).
• No administration; just code and go
• API client libraries installed using language package manager
• Tutorials and examples in their languages, relevant to actual use
11
MQ Light Image DockerHub Registry
12
13
Docker
• A Docker image for MQ Light is now available on Docker
Hub.
• https://registry.hub.docker.com/u/ibmimages/mqlight/
• MQ Light runs inside a container, isolated from the rest of
your system:
• Process isolation – all the processes associated
with MQ Light are run in their own process space,
and can’t see any other processes running on your
server
• Resource isolation – you can limit the amount of
memory and CPU you allocate to a container
• Dependency isolation - all software which MQ
Light depends on is included in the MQ Light image,
except the Linux kernel itself.
Source: If applicable, describe source origin
IBM Presentation Template Full Version
Docker also helps with fast, reliable deployments in cloud environments
One command to download and run MQ Light:
– docker run –e LICENSE=accept –P ibmimages/mqlight
Tooling to assist development
• Used to answer questions like :
• Where did this message come from?
• Where did that message go?
• What messages has my app consumed?
14
Programming Language Support.
A. Simple Messaging Model
B. Idiomatic clients in fully supported languages
• IBM Design Thinking applied here.
C.Compatibility with open source AMQP 1.0 clients for other
languages.
• Apache Qpid Proton
15
Programming Language Support.
A. Simple Messaging Model
B. Idiomatic clients in fully supported languages
• IBM Design Thinking applied here.
C.Compatibility with open source AMQP 1.0 clients for other
languages.
• Apache Qpid Proton
16
17
MQ Light Messaging Model – Send Messages
Applications send messages to a topic.
A topic is an address in the topic space
either flat or arranged hierarchically.
1. Send (‘/test/a’, “Hello”);
2. Send (‘/test/a’, “World!”);
Topic Address Space
Sender application
18
MQ Light Messaging Model – Simple Receive
•Applications receive messages by creating a destination with a pattern
which matches the topics they are interested in.
•Pattern matching scheme based on WMQ.
1. Send (‘/test/a’, “Hello”);
2. Send (‘/test/a’, “World!”);
1. Hello
2. World!
Topic Address Space
Sender application
DESTINATION
Pattern=/test/a
19
MQ Light Messaging Model – Pub/Sub
•Multiple destinations can be created which match the same topic
•Pub/Sub style.
DESTINATION
1. Send (‘/test/a’, “Hello”);
2. Send (‘/test/a’, “World!”);
1. Hello
2. World!
1. Hello
2. World!
Topic Address Space
Sender application
DESTINATION
Pattern=/test/a
Pattern=/test/#
Client 1
Client 2
20
MQ Light Messaging Model – Persistent destinations
•Destinations persist for a defined “time to live” after receiver detaches.
1. Send (‘/test/a’, “Hello”);
2. Send (‘/test/a’, “World!”);
Topic Address Space
Sender application
Hello
World!
DESTINATION
Pattern=/test/a
Disconnected client
21
MQ Light Messaging Model – Sharing
•Clients attaching to the same topic pattern and share name attach to the
same shared destination.
DESTINATION1. Send (‘/test/a’, “Hello”);
2. Send (‘/test/a’, “World!”);
1. Hello
2. World!
1. Hello
2. World!
SHARING
Topic Address Space
Sender application
DESTINATION
Pattern=/test/#
Pattern=/test/#
Share=myshare
Client 1
Client 2
Client 3
22
MQ Light Messaging Model – Client takeover
1. Send (‘/test/a’, “Hello”);
Hello
Topic Address Space
Sender application
DESTINATION
Pattern=/test/#
Client 1
World!
Client 1
2. Send (‘/test/a’, “World!”);
•Applications connect to MQ Light service specify (optional) client ID.
•Re-using the same client ID pre-empts the original connection.
•Ideal for worker takeover in the cloud.
MQ Light Messaging Model
• Messages
• Payload is either Text or Binary.
• Content-type is used by clients to transfer JSON
• Per message time to live.
• Message delivery model
• At most once delivery (QoS 0)
• At least once delivery (QoS 1)
• Acknowledge & Reject messages
• Control over the number of unacknowledged messages
delivered. (link credit)
23
Programming Language Support.
A. Simple Messaging Model
B. Idiomatic clients in fully supported languages
• IBM Design Thinking applied here.
C.Compatibility with open source AMQP 1.0 clients for other
languages.
• Apache Qpid Proton
24
Programming languages
Language Availability Notes
Node.js Supported IBM Client.
Ruby IBM Client in Beta
Java (Non Blocking) IBM Client in Beta
Python IBM Client in Beta
PHP Qpid Proton
Scala Can use Java non
Blocking client.
Forum users report this
working.
C/C++ Qpid Proton
Perl Qpid Proton
25
MQ Light Node.JS API
• Installable from NPM
• Fully non blocking – Node.JS style
• Fluent programming style - wrappable into promises.
• Focussed on code simplicity.
• Client seamlessly retries across cloud endpoints
26
# Receive:
var mqlight = require('mqlight');
var recvClient = mqlight.createClient({service: 'amqp://localhost'});
recvClient.on('started', function() {
recvClient.subscribe('news/technology');
recvClient.on('message', function(data, delivery) {
console.log(data);
});
});
# Send:
var mqlight = require('mqlight');
var sendClient = mqlight.createClient({service: 'amqp://localhost'});
sendClient.on('started', function() {
sendClient.send('news/technology', 'Hello World!');
});
MQ Light Ruby API (Beta)
• Installable from rubygems.org
• Synchronous/blocking client.
• Bluemix connection support
• Backlog• Auto reconnect.
• Asynchronous non blocking
• TLS
27
# Receive:
require 'mqlight'
client = Mqlight::BlockingClient.new('amqp://localhost')
client.subscribe('news/technology')
delivery = client.receive('news/technology')
puts delivery.data
# Send:
require 'mqlight'
client = Mqlight::BlockingClient.new('amqp://localhost')
client.send('news/technology', 'Hello World!')
MQ Light Python API (Beta)
• Installable from rubygems.org
• Non blocking
• Client seemlessly retries across cloud endpoints
• Backlog• TLS
28
# Receive:
require 'mqlight'
client = Mqlight::BlockingClient.new('amqp://localhost')
client.subscribe('news/technology')
delivery = client.receive('news/technology')
puts delivery.data
# Send:
require 'mqlight'
client = Mqlight::BlockingClient.new('amqp://localhost')
client.send('news/technology', 'Hello World!')
MQ Light Non Blocking Java API (beta)
• Installable using Maven
• Code is opensource on github.
• Non blocking
• Client seemlessly retries across cloud endpoints
• Backlog
• TLS
29
void send() {
NonBlockingClient.create("amqp://localhost", new NonBlockingClientAdapter<Void>() {
public void onStarted(NonBlockingClient client, Void context) {
client.send("news/technology", "Hello World!", null);
}
}, null);
}
void receive() {
NonBlockingClient.create("amqp://localhost", new NonBlockingClientAdapter<Void>() {
public void onStarted(NonBlockingClient client, Void context) {
client.subscribe("news/technology", new DestinationAdapter<Void>() {
public void onMessage(NonBlockingClient client, Void context, Delivery delivery) {
if (delivery.getType() == Delivery.Type.STRING)
System.out.println(((StringDelivery)delivery).getData());
}
}, null, null);
}
}, null);
}
Programming Language Support.
A. Simple Messaging Model
B. Idiomatic clients in fully supported languages
• IBM Design Thinking applied here.
C.Compatibility with open source AMQP 1.0 clients for other
languages.
• Apache Qpid Proton
30
Agenda
• High level overview & Positioning.
• MQ Light software
• First Five Minute Experience
• Developer Centric Tooling
• Programming Language Support
• Demo
31
Summary
• MQ Light : https://developer.ibm.com/messaging/mq-light/
• MQ Light for Bluemix : www.bluemix.net
• Messaging designed for developers to create responsive and
scalable applications
• Simplified messaging API
• Easy to acquire and incorporate into applications
• Development focused tooling
• Range of application deployment options
• MQ Light
• IBM MQ [Statement of Direction]
• MQ Light cloud service in BlueMix
32
IBM MQ Sessions this week
10:30 - 12:00 13:15 - 14:15 14:30 - 15:30 16:00 - 17:00 17:15 - 18:15
Mo
nd
ay
9:00 - 10:00 10:30 - 11:30 11:45 - 12:45 14:00 - 15:00 15:15 - 16:15 16:45 - 17:45
Tu
es
da
yW
ed
ne
sd
ay
Th
urs
da
y
For Additional Information
• IBM Training
• http://www.ibm.com/training
• IBM WebSphere
• http://www.ibm.com/software/websphere/
• http://www.ibm.com/software/products/ibm-mq
• IBM developerWorks
• http://www.ibm.com/developerworks/websphere
• https://www.ibm.com/developerworks/community/blogs/messaging
• WebSphere forums and community
• http://www.ibm.com/developerworks/websphere/community/
Thank YouYour Feedback is
Important!
Access the InterConnect 2015
Conference CONNECT Attendee
Portal to complete your session
surveys from your smartphone,
laptop or conference kiosk.
Notices and Disclaimers
Copyright © 2015 by International Business Machines Corporation (IBM). No part of this document may be reproduced or
transmitted in any form without written permission from IBM.
U.S. Government Users Restricted Rights - Use, duplication or disclosure restricted by GSA ADP Schedule Contract with
IBM.
Information in these presentations (including information relating to products that have not yet been announced by IBM) has been
reviewed for accuracy as of the date of initial publication and could include unintentional technical or typographical errors. IBM
shall have no responsibility to update this information. THIS DOCUMENT IS DISTRIBUTED "AS IS" WITHOUT ANY WARRANTY,
EITHER EXPRESS OR IMPLIED. IN NO EVENT SHALL IBM BE LIABLE FOR ANY DAMAGE ARISING FROM THE USE OF
THIS INFORMATION, INCLUDING BUT NOT LIMITED TO, LOSS OF DATA, BUSINESS INTERRUPTION, LOSS OF PROFIT
OR LOSS OF OPPORTUNITY. IBM products and services are warranted according to the terms and conditions of the
agreements under which they are provided.
Any statements regarding IBM's future direction, intent or product plans are subject to change or withdrawal without
notice.
Performance data contained herein was generally obtained in a controlled, isolated environments. Customer examples are
presented as illustrations of how those customers have used IBM products and the results they may have achieved. Actual
performance, cost, savings or other results in other operating environments may vary.
References in this document to IBM products, programs, or services does not imply that IBM intends to make such products,
programs or services available in all countries in which IBM operates or does business.
Workshops, sessions and associated materials may have been prepared by independent session speakers, and do not
necessarily reflect the views of IBM. All materials and discussions are provided for informational purposes only, and are neither
intended to, nor shall constitute legal or other guidance or advice to any individual participant or their specific situation.
It is the customer’s responsibility to insure its own compliance with legal requirements and to obtain advice of competent legal
counsel as to the identification and interpretation of any relevant laws and regulatory requirements that may affect the customer’s
business and any actions the customer may need to take to comply with such laws. IBM does not provide legal advice or
represent or warrant that its services or products will ensure that the customer is in compliance with any law.
Notices and Disclaimers (con’t)
Information concerning non-IBM products was obtained from the suppliers of those products, their published
announcements or other publicly available sources. IBM has not tested those products in connection with this
publication and cannot confirm the accuracy of performance, compatibility or any other claims related to non-IBM
products. Questions on the capabilities of non-IBM products should be addressed to the suppliers of those products.
IBM does not warrant the quality of any third-party products, or the ability of any such third-party products to
interoperate with IBM’s products. IBM EXPRESSLY DISCLAIMS ALL WARRANTIES, EXPRESSED OR IMPLIED,
INCLUDING BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A
PARTICULAR PURPOSE.
The provision of the information contained herein is not intended to, and does not, grant any right or license under any
IBM patents, copyrights, trademarks or other intellectual property right.
• IBM, the IBM logo, ibm.com, Bluemix, Blueworks Live, CICS, Clearcase, DOORS®, Enterprise Document
Management System™, Global Business Services ®, Global Technology Services ®, Information on Demand,
ILOG, Maximo®, MQIntegrator®, MQSeries®, Netcool®, OMEGAMON, OpenPower, PureAnalytics™,
PureApplication®, pureCluster™, PureCoverage®, PureData®, PureExperience®, PureFlex®, pureQuery®,
pureScale®, PureSystems®, QRadar®, Rational®, Rhapsody®, SoDA, SPSS, StoredIQ, Tivoli®, Trusteer®,
urban{code}®, Watson, WebSphere®, Worklight®, X-Force® and System z® Z/OS, are trademarks of
International Business Machines Corporation, registered in many jurisdictions worldwide. Other product and
service names might be trademarks of IBM or other companies. A current list of IBM trademarks is available on
the Web at "Copyright and trademark information" at: www.ibm.com/legal/copytrade.shtml.