<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:wfw="http://wellformedweb.org/CommentAPI/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
	xmlns:slash="http://purl.org/rss/1.0/modules/slash/"
	>

<channel>
	<title>sensatic</title>
	<atom:link href="http://sensatic.net/feed" rel="self" type="application/rss+xml" />
	<link>http://sensatic.net</link>
	<description></description>
	<lastBuildDate>Tue, 14 May 2013 14:11:39 +0000</lastBuildDate>
	<language>en-US</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.4.2</generator>
		<item>
		<title>Lightweight Messaging For Web And Mobile With Apache ActiveMQ</title>
		<link>http://sensatic.net/talks/lightweight-messaging-for-web-and-mobile-with-apache-activemq.html</link>
		<comments>http://sensatic.net/talks/lightweight-messaging-for-web-and-mobile-with-apache-activemq.html#comments</comments>
		<pubDate>Tue, 14 May 2013 14:11:39 +0000</pubDate>
		<dc:creator>Dejan Bosanac</dc:creator>
				<category><![CDATA[Talks]]></category>

		<guid isPermaLink="false">http://sensatic.net/?p=447</guid>
		<description><![CDATA[Messaging once was a thing of &#8220;enterprises&#8221; but times are changing fast and devs now want to use it from virtually any environment. I thought it&#8217;s important to talk about messaging technologies available for web and mobile, so I&#8217;ll give a talk about it at CamelOne and OSCON. If you&#8217;re attending one of those give [...]]]></description>
			<content:encoded><![CDATA[<p>Messaging once was a thing of &#8220;enterprises&#8221; but times are changing fast and devs now want to use it from virtually any environment. I thought it&#8217;s important to talk about messaging technologies available for web and mobile, so I&#8217;ll give a talk about it at <a href="http://www.camelone.com/apache-camel-conference-2013/camelone_agenda_2013">CamelOne</a> and <a href="http://www.oscon.com/oscon2013/public/schedule/detail/28103">OSCON</a>. If you&#8217;re attending one of those give me a ping, so we can have a chat over some beers.</p>
]]></content:encoded>
			<wfw:commentRss>http://sensatic.net/talks/lightweight-messaging-for-web-and-mobile-with-apache-activemq.html/feed</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Apache ActiveMQ 5.7.0 released</title>
		<link>http://sensatic.net/talks/apache-activemq-5-7-0-released.html</link>
		<comments>http://sensatic.net/talks/apache-activemq-5-7-0-released.html#comments</comments>
		<pubDate>Mon, 08 Oct 2012 12:36:22 +0000</pubDate>
		<dc:creator>Dejan Bosanac</dc:creator>
				<category><![CDATA[ActiveMQ]]></category>
		<category><![CDATA[Talks]]></category>

		<guid isPermaLink="false">http://sensatic.net/?p=434</guid>
		<description><![CDATA[We managed to keep our goal of making more frequent releases and today we&#8217;re happy to announce Apache ActiveMQ 5.7.0. The main goal of this release was Java 7 compatibility. The project is built using JDK 6, but it&#8217;s tested to work properly with Java 7. This was needed as we now use Camel 2.10, [...]]]></description>
			<content:encoded><![CDATA[<p>We managed to keep our goal of making more frequent releases and today we&#8217;re happy to announce <a href="http://activemq.apache.org/activemq-570-release.html">Apache ActiveMQ 5.7.0</a>. The main goal of this release was Java 7 compatibility. The project is built using JDK 6, but it&#8217;s tested to work properly with Java 7. This was needed as we now use <a href="http://camel.apache.org/camel-2100-release.html">Camel 2.10</a>, which also added support for Java 7.</p>
<p>Besides this, there&#8217;s a couple of new features and close to two hundred bug fixes in this release. Some of the prominent new features are:</p>
<ul>
<li>Secure WebSocket (wss) transport &#8211; which means that you can now securely connect to the broker directly from your browser. You can find more information about it <a href="http://activemq.apache.org/websockets.html#WebSockets-SecureWebSockets">here</a></li>
<li>Broker Redelivery &#8211; which allows you to define redelivery policy such that broker will resend a message to a different consumer in case that processing fails. <a href="http://activemq.apache.org/message-redelivery-and-dlq-handling.html#MessageRedeliveryandDLQHandling-BrokerRedelivery%2528v5.7%2529">Here</a> you can find more information on when you&#8217;d want to use this feature and how.</li>
</ul>
<p>We also improved our storage locking mechanism, so now it&#8217;s <a href="http://activemq.apache.org/pluggable-storage-lockers.html">completely pluggable</a>. This means that locking is not tied to the store itself, but it&#8217;s separately configured. And also you can tune it or implement new locking strategies to suit your environment. We also provided a new database locker, called <a href="http://activemq.apache.org/pluggable-storage-lockers.html#Pluggablestoragelockers-LeaseDatabaseLocker">Lease Database Locker</a>, which should do much better job for JDBC master slave scenarios.</p>
<p>So, that&#8217;s about it. Give 5.7.0 a try and let us know what do you want to see in 5.8.0.</p>
<p>And while I have your attention, there&#8217;re two upcoming sessions where you can learn more about ActiveMQ:</p>
<ul>
<li>I&#8217;ll be talking about <em>ActiveMQ in the cloud</em> at <a href="http://www.redhat.com/promo/jboss_integration_week/">Red Hat Integration and BPM Week</a> on October 15th</li>
<li>and about <em>Apollo and the future of ActiveMQ</em> at <a href="http://www.apachecon.eu/">ApacheCon EU</a> on November 8th</li>
</ul>
]]></content:encoded>
			<wfw:commentRss>http://sensatic.net/talks/apache-activemq-5-7-0-released.html/feed</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
		<item>
		<title>Pluggable ActiveMQ Storage Lockers</title>
		<link>http://sensatic.net/activemq/pluggable-activemq-storage-lockers.html</link>
		<comments>http://sensatic.net/activemq/pluggable-activemq-storage-lockers.html#comments</comments>
		<pubDate>Thu, 13 Sep 2012 09:49:07 +0000</pubDate>
		<dc:creator>Dejan Bosanac</dc:creator>
				<category><![CDATA[ActiveMQ]]></category>

		<guid isPermaLink="false">http://sensatic.net/?p=425</guid>
		<description><![CDATA[Shared storage master slave broker topologies depend on successful storage locking. Meaning that only a single broker (the master) is active and use the message database. So far locking was tied to a specific message store, so KahaDB was using shared file locking while JDBC store was using a specialized database table to keep slaves [...]]]></description>
			<content:encoded><![CDATA[<p>Shared storage master slave broker topologies depend on successful storage locking. Meaning that only a single broker (the master) is active and use the message database. So far locking was tied to a specific message store, so KahaDB was using shared file locking while JDBC store was using a specialized database table to keep slaves from starting. This work fine for the most use cases, but sometimes folks need to use a custom locker (like when the standard file locking doesn&#8217;t work on their NFS) or tune existing solutions.</p>
<p>For the upcoming 5.7.0 release we introduced pluggable storage lockers, which means that message storage locking is totally separated from the store itself. That means that you can now use any locking strategy with any store. An example configuration is shown below:</p>
<pre><code>&lt;persistenceAdapter&gt;
    &lt;kahaDB directory = "target/activemq-data"&gt;
        &lt;locker&gt;
            &lt;shared-file-locker lockAcquireSleepInterval="5000"/&gt;
        &lt;/locker&gt;
    &lt;/kahaDB&gt;
&lt;/persistenceAdapter&gt;
</code></pre>
<p>You can find more details on this new feature <a href="http://activemq.apache.org/pluggable-storage-lockers.html">here</a>. It will also allow us to implement new locking strategies, based on ZooKeeper for example, which will make high-availability setups even easier. So stay tuned.</p>
]]></content:encoded>
			<wfw:commentRss>http://sensatic.net/activemq/pluggable-activemq-storage-lockers.html/feed</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
		<item>
		<title>Messaging Anti-Patterns: Part 3</title>
		<link>http://sensatic.net/messaging/messaging-anti-patterns-part-3.html</link>
		<comments>http://sensatic.net/messaging/messaging-anti-patterns-part-3.html#comments</comments>
		<pubDate>Wed, 05 Sep 2012 16:21:14 +0000</pubDate>
		<dc:creator>Dejan Bosanac</dc:creator>
				<category><![CDATA[Messaging]]></category>

		<guid isPermaLink="false">http://sensatic.net/?p=419</guid>
		<description><![CDATA[OK, after basic anti-patterns discussed in part 1 and 2 of this series, it&#8217;s time to discuss a bit more sophisticated messaging anti-patterns and how to write better messaging-oriented applications. Using appropriate message type So let&#8217;s start with the first principles of messaging. Why we want to use a message broker in our architecture? The [...]]]></description>
			<content:encoded><![CDATA[<p>OK, after basic anti-patterns discussed in <a href="http://sensatic.net/messaging/messaging-anti-patterns-part-1.html">part 1</a> and <a href="http://sensatic.net/messaging/messaging-anti-patterns-part-2.html">2</a> of this series, it&#8217;s time to discuss a bit more sophisticated messaging anti-patterns and how to write better messaging-oriented applications.</p>
<h1>Using appropriate message type</h1>
<p>So let&#8217;s start with the first principles of messaging. Why we want to use a message broker in our architecture? The most probable answer is to exchange <strong>data</strong> in <strong>asynchronous</strong> and <strong>lously-coupled</strong> way between our systems. In that terms we should see how our data are best represented in terms of messages. JMS specification defines a few types of message types to be used which I&#8217;d classify in two groups. In the first group I&#8217;ll put <code>TextMessages</code> and <code>ByteMessages</code> which provides a kind of a plain-sheet in terms of what kind of data is carried in the message body. I think that you should strongly consider using only these message types as they provide a framework for loosely-coupled data exchange without introducing unnecessary complexity. Let&#8217;s cover briefly other message types and discuss what they bring to the picture:</p>
<h2>ObjectMessages</h2>
<p>If you haven&#8217;t already, be sure to read a <a href="http://www.jmesnil.net/weblog/2012/07/27/on-jms-objectmessage-and-its-pitfalls/">post Jeff Mesnil wrote on this subject</a>. It sums up pretty well what&#8217;s wrong <code>ObjectMessage</code> type. In the nutshell:</p>
<ul>
<li>
<p>You can get into a classloading mess as your systems need to <strong>share a classpath information</strong> as they need to be able to (de)serialize same objects. This increases coupling between the systems which we wanted to avoid in the first place.</p>
</li>
<li>
<p>It adds unnecessary performance penalties for serializing and transferring the <strong>whole objects</strong>, instead of only valuable data</p>
</li>
</ul>
<h2>StreamMessages</h2>
<p>In a similar fashion, <code>StreamMessage</code> adds some semantics over the basic ByteMessages. Instead of treating all bytes equally, you can now write and read strings, integers, objects, etc. This was very valuable in times when JMS API was designed, but today in the age of all these advanced serialization frameworks, both binary (<a href="http://code.google.com/p/protobuf/">Protobuf</a> and co) and text-based ones (<a href="http://jackson.codehaus.org/">Jackson</a> and co.), I think you&#8217;ll better forget about it. Encode your data with the some of the tools you&#8217;re probably already using in your applications and transfer them using ByteMessages or TextMessages.</p>
<h2>MapMessages</h2>
<p><code>MapMessages</code> are just one more example of a too specialized interface. It&#8217;s true that map (properties) collection format is commonly used, but it&#8217;s just one of many, so why depend and couple your application to it.</p>
<p>Additionally usage of ObjectMessages, StreamMessages and MapMessage ties your solution to the JMS land and prevents you to exchange messages with <a href="http://stomp.github.com/">Stomp-based clients</a> for example.</p>
<h1>Avoid fat-messages (Blobs)</h1>
<p>While it&#8217;s certainly possible to move large messages through message brokers, you should think twice if you want to do that. And when I say large messages, I mean gigabytes and gigabytes of data in a single message. If you find yourself with the requirement like that, ask yourself do you really need a messaging service to move this data. Broker internals are optimized to move large amount of messages and adding big blobs in the combination can cause various side effects (connection controls kicking in, blocking other clients, exhausting resources, etc).</p>
<p>The usual pattern suggested for this use case is that you should use some <strong>traditional transport, like FTP</strong>, for moving large data; and use <strong>messaging service to notify clients</strong> when data is ready for download (and where to find it). ActiveMQ even provides and [API which will do this for you under the cover of JMS API] (http://activemq.apache.org/blob-messages.html)</p>
<p>That&#8217;s it for today, choose your message type and size wisely so you don&#8217;t end up with tightly coupled systems and brokers/clients struggling with oversized messages.</p>
]]></content:encoded>
			<wfw:commentRss>http://sensatic.net/messaging/messaging-anti-patterns-part-3.html/feed</wfw:commentRss>
		<slash:comments>2</slash:comments>
		</item>
		<item>
		<title>Messaging Anti-Patterns: Part 2</title>
		<link>http://sensatic.net/messaging/messaging-anti-patterns-part-2.html</link>
		<comments>http://sensatic.net/messaging/messaging-anti-patterns-part-2.html#comments</comments>
		<pubDate>Fri, 17 Aug 2012 10:05:42 +0000</pubDate>
		<dc:creator>Dejan Bosanac</dc:creator>
				<category><![CDATA[Messaging]]></category>

		<guid isPermaLink="false">http://sensatic.net/?p=407</guid>
		<description><![CDATA[OK, now that you promised that you won&#8217;t store your messages in the broker (see part one of this post series), let&#8217;s consider one more thing that you should avoid when dealing with messaging systems. Short-lived connections One thing that reoccur regularly is folks (knowingly or unknowingly) creating and tearing connections to the broker for [...]]]></description>
			<content:encoded><![CDATA[<p>OK, now that you promised that you won&#8217;t <strong>store</strong> your messages in the broker (<a href="http://sensatic.net/messaging/messaging-anti-patterns-part-1.html">see part one of this post series</a>), let&#8217;s consider one more thing that you should avoid when dealing with messaging systems.</p>
<h1>Short-lived connections</h1>
<p>One thing that reoccur regularly is folks (knowingly or unknowingly) creating and tearing connections to the broker for every message they produce and consume.</p>
<p>This <em>anti-pattern</em> is especially common in two environments: Stomp and Spring. <strong>Stomp</strong> is very lightweight text-oriented messaging protocol. Which makes it really easy to write clients in almost any programming language available. This is one of the main strengths of Stomp and if you&#8217;re not JVM-exclusive shop I strongly recommend you to take a detailed look at it. But this impose a problem of course; large number of clients are poorly written and/or used inappropriately. For example, you can have a script which when ran will send or consume some messages from the broker. So if you don&#8217;t care much, you&#8217;ll open a new connection every time, send and consume messages and (hopefully) disconnect from the broker. Then you&#8217;ll put your script under load which will then transfer that load to the broker.</p>
<p><strong>Spring</strong>, on the other hand, uses nice abstractions for dealing with JMS brokers, but the <em>problem</em> is that it was designed to be ran in a container of some kind and it is expected that container will manage resources for it. So when you write your <em>standalone</em> Java application and don&#8217;t care about this you end up with messaging clients behaving badly. A new connection, session, producer, consumer objects will be created for every message exchange and that far from optimal.</p>
<p>Why is all this such a problem? Well, first of all opening and closing connections requires from broker to do some work and having large number of clients opening and closing connections to exchange a single message produces a huge overhead and steals resources broker could use to do some other useful work. This is not specific to messaging and broker. You don&#8217;t open and close a database connection for every query (hopefully) for the same reasons.  And also a spike in load in this case can spike in number of sockets used (as they need some time shutdown on the system) and eventual <strong>system resources exhaustion</strong>.</p>
<p>Besides this, messaging services are all about long lasting connections and clients. ActiveMQ implements various concepts, like <a href="http://activemq.apache.org/producer-flow-control.html">producer flow control</a> and <a href="http://activemq.apache.org/what-is-the-prefetch-limit-for.html">consumer message prefetch</a>, which are aimed to improve messaging experience and performance of the whole system. Not only that these <strong>messaging mechanisms are meaningless in a short-lived connections scenario</strong>, but can also introduce additional overhead in the system.</p>
<p>Finally if you have network brokers, information on large number of message consumers coming and going will be <strong>propagated through the network</strong>. This can significantly increase a broker to broker traffic and even impact the stability of remote brokers.</p>
<p>So what&#8217;s to be done? In <strong>Spring</strong> it&#8217;s easy, just use some kind of a <strong>cached connection factory</strong> and you&#8217;ll be sorted. There&#8217;ll be no more a new connection, session, producer, consumer for every message exchanged. More resources on ActiveMQ Spring support can be found <a href="http://activemq.apache.org/spring-support.html">here</a> so please give it read if you&#8217;re using JMS Spring clients in your applications.</p>
<p>For <strong>Stomp</strong>, there&#8217;s no silver bullet. But for starters <strong>be aware of what you&#8217;re doing</strong> and try to <strong>reuse your resources smartly</strong>. If you do it, messages will flow smoothly and you&#8217;ll have a stable system.</p>
]]></content:encoded>
			<wfw:commentRss>http://sensatic.net/messaging/messaging-anti-patterns-part-2.html/feed</wfw:commentRss>
		<slash:comments>7</slash:comments>
		</item>
		<item>
		<title>Messaging Anti-Patterns: Part 1</title>
		<link>http://sensatic.net/messaging/messaging-anti-patterns-part-1.html</link>
		<comments>http://sensatic.net/messaging/messaging-anti-patterns-part-1.html#comments</comments>
		<pubDate>Tue, 31 Jul 2012 14:31:39 +0000</pubDate>
		<dc:creator>Dejan Bosanac</dc:creator>
				<category><![CDATA[Messaging]]></category>

		<guid isPermaLink="false">http://sensatic.net/?p=397</guid>
		<description><![CDATA[If you have a hammer everything looks like a nail, right? So we all witnessed that people sometimes try to solve the problem with wrong technology. Heck we probably all did it at one point or another. Common reasons are familiarity with an exiting technology stack we have at hand or perception that some of [...]]]></description>
			<content:encoded><![CDATA[<p>If you have a hammer everything looks like a nail, right? So we all witnessed that people sometimes try to solve the problem with wrong technology. Heck we probably all did it at one point or another. Common reasons are familiarity with an exiting technology stack we have at hand or perception that some of the features will justify it all. But using any technology in a way it&#8217;s not designed for, will lead to all kind of problems and you&#8217;ll eventually be forced to do it properly (probably cursing at the project in question because it hasn&#8217;t met you wrong expectations).</p>
<p>In this and couple of follow-up posts I&#8217;ll try sum up some things we saw in mailing lists, Jiras, etc related to improper usage of messaging systems (ActiveMQ in particular). Hopefully, it will help people that consider using messaging in their architecture, see if it is the right tool for solving their particular problem.</p>
<p>So let&#8217;s kick off with one common mistake people make</p>
<h1>Using message queue as a database</h1>
<p>Messaging systems are built to asynchronously connect multiple systems, by <strong>passing</strong> messages between them. So everything is designed with that in mind; how to most efficiently pass messages from producers to consumers. This means that messages are expected to be reasonably short-lived, and not <strong>stored</strong> in a queue.</p>
<p>From time to time we see people trying keep application state in the broker. Put some messages in a queue, than browse them, cherry-pick just some of them, delete others and similar stuff. While most of the messaging systems have some kind of support to do this it&#8217;s not what they&#8217;re designed to support primarily. Client APIs, internal storage system, client-server contracts, etc. are optimized for entirely different set of tasks.</p>
<p>An example could be a system that wants to keep a single most-recent data as a queue message (timestamped or versioned somehow). So that application can find that message (usually by browsing) and do the house keeping by deleting stale data. People are sometimes inclined to do this as brokers provide high-availability, reconnection logic, can be geographically distributed which is all fine and well. But brokers are a poor choice for maintaining application state.</p>
<p>A workaround is not to keep any state in the broker, of course. Either use a centralized high-availability database or a local copy of data and use messaging system to propagate changes.</p>
<p>So if you find yourself wanting to <strong>store</strong> some messages in a queue and then later <strong>browse</strong> them, <strong>query</strong> them or <strong>maintain</strong> them, <strong>please don&#8217;t</strong>. Get yourself a database of some kind (relational or not) and manipulate data there. Queues (and topics) are for data that should be consumed as they come and moved from one system to another as fast as possible. They should live in the broker only as long as it takes to consume them or if something has gone wrong and they cannot be consumed. Which should be an exceptional situation rather than what we design for.</p>
<p>If there&#8217;s any messaging anti-patterns you observed (or designed yourself &#8211; c&#8217;mon don&#8217;t be ashamed), send them to me. I&#8217;ll gladly put them on my list and document them in coming days.</p>
]]></content:encoded>
			<wfw:commentRss>http://sensatic.net/messaging/messaging-anti-patterns-part-1.html/feed</wfw:commentRss>
		<slash:comments>7</slash:comments>
		</item>
		<item>
		<title>Conference week wrap-up</title>
		<link>http://sensatic.net/talks/conference-week-wrap-up.html</link>
		<comments>http://sensatic.net/talks/conference-week-wrap-up.html#comments</comments>
		<pubDate>Sat, 19 May 2012 14:16:43 +0000</pubDate>
		<dc:creator>Dejan Bosanac</dc:creator>
				<category><![CDATA[Talks]]></category>

		<guid isPermaLink="false">http://www.nighttale.net/talks/conference-week-wrap-up.html</guid>
		<description><![CDATA[I had a blast of a week at CamelOne and JEEConf. Both organized perfectly and awesome crowd all around. CamelOne was packed with FuseSource customers and users with a great feedback on the things we do. There were a lot of interest in Fuse Fabric which should help folks provision their integration infrastructure with ease. [...]]]></description>
			<content:encoded><![CDATA[<p>I had a blast of a week at <a href="http://www.camelone.com">CamelOne</a> and <a href="http://www.jeeconf.com">JEEConf</a>. Both organized perfectly and awesome crowd all around.</p>
<p><a href="http://www.flickr.com/photos/54898272@N07/7216436854/" title="davidfoxphotographer-196 by FuseSource, on Flickr"><img src="http://farm8.staticflickr.com/7211/7216436854_c0fd95c8a0.jpg" width="500" height="333" alt="davidfoxphotographer-196"></a></p>
<p>CamelOne was packed with FuseSource customers and users with a great feedback on the things we do. There were a lot of interest in <a href="http://fuse.fusesource.org/fabric/">Fuse Fabric</a> which should help folks provision their integration infrastructure with ease. I covered how Fabric can help with complex ActiveMQ deployments and you can find the slides embedded below.</p>
<div style="width:425px" id="__ss_12992098"> <strong style="display:block;margin:12px 0 4px"><a href="http://www.slideshare.net/dejanb/deploying-fusemq-with-fuse-fabric" title="Deploying FuseMQ with Fuse Fabric" target="_blank">Deploying FuseMQ with Fuse Fabric</a></strong> <iframe src="http://www.slideshare.net/slideshow/embed_code/12992098" width="425" height="355" frameborder="0" marginwidth="0" marginheight="0" scrolling="no"></iframe>
<div style="padding:5px 0 12px"> View more <a href="http://www.slideshare.net/thecroaker/death-by-powerpoint" target="_blank">PowerPoint</a> from <a href="http://www.slideshare.net/dejanb" target="_blank">dejanb</a> </div>
</p></div>
<p>If you have to deploy and manage more than one broker I strongly recommend you taking a look at Fabric and <a href="http://fusesource.com/products/fuse-esb-enterprise/">FuseESB Enterprise 7.0</a> which incorporates it.</p>
<p>JEEConf was a more general Java conference; a quite larger than last year. Although most of the sessions were in Russian so I couldn&#8217;t actually follow, at least I had time to write this blog post <img src='http://sensatic.net/wp-includes/images/smilies/icon_smile.gif' alt=':)' class='wp-smiley' /><br />
I gave a talk on <a href="http://activemq.apache.org/apollo/">ActiveMQ Apollo</a> subproject, which is packed with cool new stuff that should bring open source messaging to the next level. Take a look at the slides here</p>
<div style="width:425px" id="__ss_12992210"> <strong style="display:block;margin:12px 0 4px"><a href="http://www.slideshare.net/dejanb/introduction-to-activemq-apollo-12992210" title="Introduction to ActiveMQ Apollo" target="_blank">Introduction to ActiveMQ Apollo</a></strong> <iframe src="http://www.slideshare.net/slideshow/embed_code/12992210" width="425" height="355" frameborder="0" marginwidth="0" marginheight="0" scrolling="no"></iframe>
<div style="padding:5px 0 12px"> View more <a href="http://www.slideshare.net/" target="_blank">presentations</a> from <a href="http://www.slideshare.net/dejanb" target="_blank">dejanb</a> </div>
</p></div>
<p>It was well received and I&#8217;m looking forward to more feedback as people start playing with it more.<br />
All in all, it was a great week and it&#8217;s always a pleasure to present and get a feedback on the our projects. Can&#8217;t wait for Monday when the new cycle of development begins.</p>
]]></content:encoded>
			<wfw:commentRss>http://sensatic.net/talks/conference-week-wrap-up.html/feed</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>ActiveMQ 5.6.0 and other news</title>
		<link>http://sensatic.net/activemq/activemq-560-and-other-news.html</link>
		<comments>http://sensatic.net/activemq/activemq-560-and-other-news.html#comments</comments>
		<pubDate>Tue, 08 May 2012 15:22:45 +0000</pubDate>
		<dc:creator>Dejan Bosanac</dc:creator>
				<category><![CDATA[ActiveMQ]]></category>

		<guid isPermaLink="false">http://www.nighttale.net/activemq/activemq-560-and-other-news.html</guid>
		<description><![CDATA[We just released Apache ActiveMQ 5.6.0. It was a long-awaited maintenance release, but however there are a few very significant new features that was worth waiting for. Those include a new LevelDB store, MQTT and Stomp 1.1 protocols support and self-balancing cluster clients, to name a few. I already written about clustering here and there [...]]]></description>
			<content:encoded><![CDATA[<p>We just released Apache ActiveMQ 5.6.0. It was a long-awaited maintenance release, but however there are a few very significant new features that was worth waiting for. Those include a new <a href="https://github.com/fusesource/fuse-extra/tree/master/fusemq-leveldb">LevelDB store</a>, MQTT and Stomp 1.1 protocols support and self-balancing cluster clients, to name a few. I already written about clustering <a href="http://www.nighttale.net/activemq/new-activemq-failover-and-clustering-goodies.html">here</a> and there sure will be a lot of things to write about these other features as well in coming days.</p>
<p>Also, next week I&#8217;ll be at <a href="http://fusesource.com/apache-camel-conference-2012/">CamelOne</a> in Boston and <a href="http://jeeconf.com/">JEEConf</a> In Kiev (a bit too much traveling for my taste, but there you go). I&#8217;ll talk about Enterprise deployment of ActiveMQ using Fuse Fabric (a topic already covered <a href="http://www.nighttale.net/activemq/activemq-in-cloud.html">here</a> in a nutshell) and <a href="http://activemq.apache.org/apollo/">Apache Apollo</a>, the next generation of the broker. All these projects that are coming in the pipeline are pushing the possibilities of our integration infrastructure one step further. It will allow people to do complex deployments easier and connect to the infrastructure from virtually everywhere. It was a very exciting first half of the year, and it looks like things are going to be even more interesting going forward. </p>
]]></content:encoded>
			<wfw:commentRss>http://sensatic.net/activemq/activemq-560-and-other-news.html/feed</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>ActiveMQ in the cloud</title>
		<link>http://sensatic.net/activemq/activemq-in-cloud.html</link>
		<comments>http://sensatic.net/activemq/activemq-in-cloud.html#comments</comments>
		<pubDate>Tue, 10 Apr 2012 10:24:27 +0000</pubDate>
		<dc:creator>Dejan Bosanac</dc:creator>
				<category><![CDATA[ActiveMQ]]></category>

		<guid isPermaLink="false">http://www.nighttale.net/activemq/activemq-in-cloud.html</guid>
		<description><![CDATA[FuseSource just announced a public beta of new Enterprise products (Read more about it in Rob&#8217;s post). So it&#8217;s time to give you a bit more details on what we were working on for the past few months. One thing I want to emphasize in this post is how this project improves the experience of [...]]]></description>
			<content:encoded><![CDATA[<p><a href="http://fusesource.com/">FuseSource</a> just announced a public beta of new Enterprise products (<a href="http://rajdavies.blogspot.com/2012/04/beta-release-of-fusesource-enteprise.html">Read more about it in Rob&#8217;s post</a>). So it&#8217;s time to give you a bit more details on what we were working on for the past few months. One thing I want to emphasize in this post is how this project improves the experience of deploying and managing ActiveMQ brokers. <a href="http://fuse.fusesource.org/fabric/index">Fuse Fabric</a> (the central engine behind Fuse Enterprise) can help you provision and manage your brokers better and additionally help with cloud deployments.</p>
<h3>Provisioning</h3>
<p>While classic server software (ActiveMQ included) deployment scenarios, which include unpacking a distro, setting a config and starting/stopping software, works OK for small deployments, there are a lot of challenges people encounter when trying to set and manage a large number of instances. Here are some of them:</p>
<ul>
<li>Enormous amount of work needed to set everything &#8211; imagine a large cluster you need to set, ssh-ing, unpacking, copying and tweaking config files is very tedious and error-prone process
<li>Changing configuration during runtime &#8211; you need again to manually tweak every file and restart the server, which is all but fun
<li>Upgrading &#8211; can also be a challenge and time consuming
</ul>
<p>Some of the things folks usually do to make their life easier is to:</p>
<ul>
<li>Keep XML config part of the spec as a template and in version control system and tweak as much things as possible with properties &#8211;  this makes it easier to keep things under control and minimize the potential of an error when managing a configuration on large number of instances.
<li>Keep configuration separate from distribution to make it all easier to upgrade
<li>Use tools like <a href="http://puppetlabs.com/">Puppet</a> or <a href="http://www.opscode.com/chef/">Chef</a> to even further make things easier in these scenarios
</ul>
<p>One of the things where Fabric excels is centralized configuration management. In Fabric it&#8217;s really easy to spin new <b>container</b> instances on your servers (using ssh) or to the public cloud. Additionally it&#8217;s really easy to deploy ActiveMQ broker to those containers,<br />
by simply applying appropriate <b>profile</b> to them. So generally, you can predefine a template for your broker, like XML configuration template and all necessary properties in a profile<br />
and then with a simple Karaf command (or even mouse click in our tools, like <a href="http://fusesource.com/products/fuse-ide/#beta">FuseIDE</a> and <a href="http://fusesource.com/products/fuse-management-console/">Fuse Management Console</a>) deploy as many instances as you like of that broker (no matter if it&#8217;s a physical box in your data center or a VM at the public could provider).</p>
<h3>Discovery</h3>
<p>Fabric uses <a href="http://zookeeper.apache.org/">Apache ZooKeeper</a> as it&#8217;s central registry of container instances running. This same registry is used to keep track of all brokers running inside a Fabric instance. This means that we can use this registry to discover all brokers inside a certain group. Therefore we created a new discovery protocol (called <b>fabric</b> of course) that can do that. So clients can connect to the broker group (think of it as a cluster) without any need to know exact location of the brokers. So now you can see how Fabric helps deploying your brokers to the cloud. First, you can use its ability to start containers (and deploy brokers on them) on any server or cloud provider available. And than clients can use Fabric to discover brokers and connect to them, all location agnostic.</p>
<h3>Topologies</h3>
<p>ZooKeeper as a central registry allows us to do some more nice things in domain of broker topologies. For example, currently the master-slave topology of ActiveMQ brokers depends on shared storage (either shared file system or enterprise JDBC database). In this scenario the master election and slave locking depends on the locking ability of the shared storage, limiting it to certain type of hardware. With ZooKeeper as a distributed registry, battle-proven for this kind of use cases, it&#8217;s easy to create a master-slave topologies with master election done on ZooKeeper locks. If you want to have a persistent master-slave, you still gonna need to store your messages in a some kind of a shared storage, but locking is not store&#8217;s job any more. And on the other hand it&#8217;s really easy to create non-persistent cluster of brokers with shared-nothing philosophy. Creating a master-slave is as simple as creating a multiple brokers with the same name in the group. The first one started will become a master, while others will be slaves waiting for the master to fail.</p>
<p>Another example of enhanced topology possibilities with ActiveMQ and Fabric is new ways you can set networks of brokers. Just as clients can use ZooKeeper registry to discover brokers, network connectors can use the same discovery protocol to connect the broker with all other brokers in the certain group. Again, brokers are mutually totally location agnostic, which is something desired in deployment scenarios with modern infrastructure. Could it be done any easier? Finally, you might want to mix these two topologies and create connected networks of master/slave broker, which with Fabric, is just easy to do as those basic topologies.</p>
<h3>Upgrades and Patching</h3>
<p>And now you say you need to upgrade all of the dozen brokers you have? No problem, with Fabric you can centrally update any bundle you&#8217;re using in your profile and that change will be propagated to all brokers. Now it&#8217;s time to talk about risk management of upgrades and this is where profile <b>versions</b> come into play. Instead of messing with profiles that are used in production at the moment, you can create a new version of it with updated versions of all bundles you plan to use. Once you have that profile ready, you can test it out on one or a few instances. And only after you&#8217;re certain that everything is OK, you can apply a new profile to all brokers. Of course, it&#8217;s easy to rollback to the previous version if anything goes wrong.</p>
<p>Fabric also provides you with the mechanism to provide a simple incremental patch jar with only certain classes modified (a single bug-fix). These classes will be then used instead of old ones and will allow us to provide a fix for a critical bug without need to upgrade the project version. This can be useful for dealing with critical production bugs, where waiting for the next release is not an option.</p>
<h3>More resources</h3>
<p>This post was just meant to give you a glance view of what&#8217;s coming from FuseSource regarding easier deployment, provisioning and managing of your messaging (and generally integration) infrastructure. You can check some more docs on the projects. Especially, there&#8217;s some more info <a href="http://fuse.fusesource.org/fabric/docs/mq.html">that explains ActiveMQ concepts explained here</a> in more details and shows how to run examples. You will definitely hear more from us on this topic in coming days, so stay tuned.</p>
]]></content:encoded>
			<wfw:commentRss>http://sensatic.net/activemq/activemq-in-cloud.html/feed</wfw:commentRss>
		<slash:comments>6</slash:comments>
		</item>
		<item>
		<title>New ActiveMQ failover and clustering goodies</title>
		<link>http://sensatic.net/activemq/new-activemq-failover-and-clustering-goodies.html</link>
		<comments>http://sensatic.net/activemq/new-activemq-failover-and-clustering-goodies.html#comments</comments>
		<pubDate>Tue, 14 Feb 2012 21:57:41 +0000</pubDate>
		<dc:creator>Dejan Bosanac</dc:creator>
				<category><![CDATA[ActiveMQ]]></category>

		<guid isPermaLink="false">http://www.nighttale.net/activemq/new-activemq-failover-and-clustering-goodies.html</guid>
		<description><![CDATA[For the last two weeks I&#8217;ve been working on some interesting use cases for the good ol&#8217; failover transport. I finally have some time at my hands, so here&#8217;s a brief recap of what&#8217;s coming in 5.6 release in this area. First there&#8217;s a new feature, called Priority Backup. It&#8217;s described in details here, but [...]]]></description>
			<content:encoded><![CDATA[<p>For the last two weeks I&#8217;ve been working on some interesting use cases for the good ol&#8217; failover transport. I finally have some time at my hands, so here&#8217;s a brief recap of what&#8217;s coming in 5.6 release in this area.</p>
<p>First there&#8217;s a new feature, called <i>Priority Backup</i>. It&#8217;s described in details <a href="http://activemq.apache.org/failover-transport-reference.html#FailoverTransportReference-PriorityBackup">here</a>, but in a nutshell it provides you with the mechanism of prioritizing your failover urls and keep your clients connected to them as soon as they are available. The most obvious use case for this is to keep your clients connected to the broker in local data center whenever you can. By doing this, you can both have better performances and stability of your clients, but also save on your bandwidth bills.</p>
<p>Another improvement is coming for <a href="http://activemq.apache.org/failover-transport-reference.html#FailoverTransportReference-BrokersideOptionsforFailover">automatic broker cluster</a> feature. Although this feature is not new, I spent some time hardening it and thought to share some more insight in how (and when) to use it in your projects.</p>
<p>In search of high availability, people often default to master-slave architecture. This makes sense in most use cases, but if your flow is purely non-persistent you can probably come up with more optimal architecture. Instead of having one broker at the time handling all your load, and other one just waiting for it to fail, you&#8217;ll get more efficient system with some kind of active-active configuration where (possibly multiple) brokers share the load all the time. Ideally clients would be evenly distributed and would rebalance if anything changes. Brokers don&#8217;t need to share any messages as clients are distributed and messages are non-persistent so they will be lost if broker fails. So can you achieve this kind of architecture with ActiveMQ?</p>
<p>Sure you do. That&#8217;s where <a href="http://activemq.apache.org/failover-transport-reference.html#FailoverTransportReference-BrokersideOptionsforFailover">automatic rebalance and clustering</a> shines. First of all, brokers should be networked but only so they can exchange information on their availability. They shouldn&#8217;t exchange the messages (but of course can if your use case needs it). In 5.6 you do that with <a href="http://activemq.apache.org/networks-of-brokers.html#NetworksofBrokers-Purestaticnetworks">pure static networks</a>, using configuration like</p>
<pre><code>&lt;networkConnector uri="static:(tcp://host)" staticBridge="true"/&gt;</code></pre>
<p>So now imagine three brokers A,B and C forming a full mesh. In addition every broker uses rebalance options on their transport connectors</p>
<pre><code>&lt;transportConnector name="openwire" uri="tcp://localhost:61616"
                    updateClusterClients="true" updateClusterClientsOnRemove="true"
                    rebalanceClusterClients="true"
/&gt;</code></pre>
<p>All that is left for the client to do is connect to one of the brokers it knows like</p>
<pre><code>failover:(brokerA)</code></pre>
<p>and the broker will fill it with all information on other brokers in the cluster and whether it should reconnect to one of them or not. So having a large number of clients connecting like this, very soon they&#8217;ll rebalance over available brokers. You can stop one of the brokers in the cluster for updates and clients will rebalance over remaining ones. You can even add a new broker to the cluster and everything will get rebalanced without any need for you to touch your clients.</p>
<p>So, basically in this way you have both load balancing and high availability for your non-persistent messages. Additionally, your clients are automatically updated with all information they need, and no manual intervention is needed.</p>
<p>Although the basic support for clustering was there since 5.4, I did some more hardening and better rebalancing, so it&#8217;s coming in the Apache ActiveMQ 5.6 (and the next <a href="http://fusesource.com/">Fuse</a> 5.5.1) release. Also, there are some more great stuff regarding broker clustering coming soon, so stay tuned and happy messaging.</p>
]]></content:encoded>
			<wfw:commentRss>http://sensatic.net/activemq/new-activemq-failover-and-clustering-goodies.html/feed</wfw:commentRss>
		<slash:comments>6</slash:comments>
		</item>
	</channel>
</rss>
