Simple auto plugin to run activemq from sbt
These are the features of this small plugin:
- Register multiple broker URIs
- Start / Stop / Restart brokers
- List registered URI
The plugin is written as a
Add this to your `plugins.sbt'
addSbtPlugin("com.edc4it" % "sbt-activemq" % "1.0.0-SNAPSHOT")
And this to your `build.sbt' (or similar in your build definition)
val root = (project in file(".")).enablePlugins(SbtActiveMQ) amqBrokers += ("sample" -> "broker:tcp://localhost:17171")
You can add multiple Broker URIs.
Once you start the sbt console you can the following
- List the registered Broker URIs:
default STOPPED broker:tcp://localhost:61616 sample STOPPED broker:tcp://localhost:17171 [success] Total time: 0 s, ...
- Start a broker (using completion for the names)
amqStart default [success] Total time: 0 s,
- Stop a broker
amqStop default [success] Total time: 0 s,
Some important notes (some will need to be
- The broker starts a random port for the JMX use
netstatto see which one
- The data directory is set to