activemq-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Albert Strasheim" <>
Subject ActiveMQ as a Windows Service
Date Mon, 18 Sep 2006 15:31:20 GMT
Hello all

I've set up ActiveMQ to run as a Windows Service using Java Service Wrapper.
I thought I'd share the wrapper configuration here to make it easier for
others that want to do the same.

You can find out more about Java Service Wrapper here:

It can run Java applications as Windows Services and UNIX daemons (I haven't
tried the latter yet).

I followed Method 1 on the Integration Methods page:

Follow these instructions to put the bits of JSW in the right places in the
ActiveMQ tree.

Put the stuff at the end of this message in ./conf/wrapper.conf in your
ActiveMQ tree (watch out for line breaks). Note that we only put run.jar and
wrapper.jar in the classpath. ActiveMQ's org.apache.activemq.console.Main
class has a addExtensionDirectory method that takes care of the rest.

That's it. Use the JSW batch files to register your service.



P.S. I'd like to put this on the wiki, but I ran into the following error
from Confluence:

This installation of Confluence is not licensed to add any more users.
Please contact the site administrators for more information.

---# start of wrapper.conf for ActiveMQ #---

# Apache ActiveMQ Wrapper Properties
# Java Application\Program Files\Java\jdk1.5.0_07\bin\java.exe

# Java Main class.  This class must implement the WrapperListener interface
#  or guarantee that the WrapperManager class is initialized.  Helper
#  classes are provided to do this for you.  See the Integration section
#  of the documentation for details.

# Java Classpath (include wrapper.jar)  Add class path elements as
#  needed starting from 1

# Java Library Path (location of Wrapper.DLL or

# Java Additional Parameters"C:\Program Files\Apache Software

# Initial Java Heap Size (in MB)

# Maximum Java Heap Size (in MB)

# Application parameters.  Add parameters as needed starting from 1

# Wrapper Logging Properties
# Format of output for the console.  (See docs for formats)

# Log Level for console output.  (See docs for log levels)

# Log file to use for wrapper output logging.

# Format of output for the log file.  (See docs for formats)

# Log Level for log file output.  (See docs for log levels)

# Maximum size that the log file will be allowed to grow to before
#  the log is rolled. Size is specified in bytes.  The default value
#  of 0, disables log rolling.  May abbreviate with the 'k' (kb) or
#  'm' (mb) suffix.  For example: 10m = 10 megabytes.

# Maximum number of rolled log files which will be allowed before old
#  files are deleted.  The default value of 0 implies no limit.

# Log Level for sys/event log output.  (See docs for log levels)

# Wrapper Windows Properties
# Title to use when running as a console
wrapper.console.title=Apache ActiveMQ

# Wrapper Windows NT/2000/XP Service Properties
# WARNING - Do not modify any of these properties when an application
#  using this configuration file has been installed as a service.
#  Please uninstall the service before modifying this section.  The
#  service can then be reinstalled.

# Name of the service ActiveMQ

# Display name of the service
wrapper.ntservice.displayname=Apache ActiveMQ

# Description of the service
wrapper.ntservice.description=Apache ActiveMQ is a fast open source JMS 1.1
Message Fabric which supports clustering, peer networks, discovery, TCP,
SSL, multicast, persistence, XA and integrates seamlessly into J2EE 1.4
containers, light weight containers and any Java Virtual Machine together
with having a host of Cross Language Clients.

# Service dependencies.  Add dependencies as needed starting from 1

# Mode in which the service is installed.  AUTO_START or DEMAND_START

# Allow the service to interact with the desktop.

View raw message