Description of problem:
Need a place to store broker data: not just rhm store but files from other qpid
components, e.g. management identity, cluster roles etc.
It should be
- collected: all data for a broker in one directory.
- locked: can't be used by 2 brokers simultaneously.
- open: new services can add their own files.
Changes for qpid:
--data-dir DIR (/var/lib/qpidd) Directory to contain persistent data generated
by the broker.
On startup: qpidd creates <data-dir>/lock, startup fails if data-dir does not
exist, has wrong permissions or is already locked.
--data-dir="" is allowed - it means "disable all features that need data-dir"
Provides an easy way to run a transient broker for tests etc.
Features that can use the data-dir may run with reduced functionality e.g.
management works but wont give history over restarts, can join a cluster but
cant resume a previous cluster identity etc.
Changes for RHM:
Store dir defaults to <data-dir>/rhm_store.
We can keep a --store-dir override since store is high-volume data that a user
might want to put on special disk partitions.
- Why default to /var/lib/qpidd?
This is the sane default for qpidd running as a system service, we want qpidd to
run properly as a system service by default.
Why not /var/lib if run as root, something else otherwise?
It's common to run system services as a non-root special user, so root isn't
always the special case.
Why not default to something convenient for developers like ~/.qpidd?
1. We want to default to deployed behavior not developer behavior.
2. The default will always be overridden if there is an /etc/qpidd.conf with a
data-dir setting. Thats more confusing than helpful.
For clarity & sanity you *must* to specify something on the command line if you
are not running the default deployed broker. Note that it's very easy though. 3
1. Transient broker for demos/tests: qpidd --data-dir=
2. Broker with own storage, but use /etc/qpidd.conf & defaults for everything
else: qpidd --data-dir=mydata
3. Broker with a private config file: qpidd --config=myconf
qpidd-0.2-24.el5, qpidc-0.2-24.el5, and rhm-0.2-18.el5 have been pushed to the staging repo for testing