Over a million developers have joined DZone.
{{announcement.body}}
{{announcement.title}}

Coming in ActiveMQ v5.11: In-Memory Scheduler Store

DZone's Guide to

Coming in ActiveMQ v5.11: In-Memory Scheduler Store

· Integration Zone
Free Resource

Modernize your application architectures with microservices and APIs with best practices from this free virtual summit series. Brought to you in partnership with CA Technologies.

 Up to this point your only option for doing scheduled message delivery in ActiveMQ required that you start a broker with persistence enabled.  Well, that's not entirely true, if you wanted to apply some configuration magic and start a broker in non-persistent mode and add an instantiated version of the KahaDB based JobSchedulerStore you could but that's not really ideal when you don't really need or want full persistence such as during unit tests or in some embedded cases. 

So from here on out if you want to use scheduled message dispatch but don't require the overhead of offline storage for your broker then just create a Broker instance that has persistence disabled and scheduler support enabled.

Here's an example of an embedded Broker that will use an in-memory scheduler:

  BrokerService answer = new BrokerService();
  answer.setPersistent(false);
  answer.setSchedulerSupport(true);

There's a lot more changes under the hood in the scheduled message bits coming in ActiveMQ 5.11.0 but I'll cover that in another post.

The Integration Zone is proudly sponsored by CA Technologies. Learn from expert microservices and API presentations at the Modernizing Application Architectures Virtual Summit Series.

Topics:

Published at DZone with permission of Timothy Bish, DZone MVB. See the original article here.

Opinions expressed by DZone contributors are their own.

THE DZONE NEWSLETTER

Dev Resources & Solutions Straight to Your Inbox

Thanks for subscribing!

Awesome! Check your inbox to verify your email so you can start receiving the latest in tech news and resources.

X

{{ parent.title || parent.header.title}}

{{ parent.tldr }}

{{ parent.urlSource.name }}