hsm scripts: fix command and options order

the order of command and options as they are used currently, breaks the
use of several hsm scripts.
This patch reorders the components to be

<command> put|get -si=... [-o1=.., ...]

Ticket: 8317
Acked-by:
Target: trunk
Target: 2.9
Require-book: no
Require-notes: no
srm: Fix transition ordering for restored requests

The transition time isn't precise enough to serve as a key or sorting.
Instead we use the element id which we know is allocated sequentially.

Target: trunk
Request: 2.9
Request: 2.8
Request: 2.7
Request: 2.6
Require-notes: yes
Require-book: no
Acked-by: Tigran Mkrtchyan <tigran.mkrtchyan@desy.de>
Patch: http://rb.dcache.org/r/6972/
info: add JSON serialisation

This patch adds support for JSON serialisation of the information gathered by the info service.

Along with the existing methods for obtaining output in different formats, the web interface has been
improved to support the client choosing which format.  The default format remains XML, but the query
parameter 'format' and Accept HTTP request header are both consulted to allow an alternative format,
with the query parameter taking precedence.

httpd-side caching has been restructured to use a Guava cache and now applies to all requests,
keeping the last ten distict queries in memory.

Target: master
Patch: http://rb.dcache.org/r/6974/
Acked-by: Tigran Mkrtchyan
pool: Log P2P fatal errors with stack trace

We have observed class initialization errors at NDGF, but the code
doesn't log a stack trace for subclasses of Error. This patch solves
that problem.

Target: trunk
Request: 2.9
Request: 2.8
Request: 2.7
Request: 2.6
Require-notes: yes
Require-book: no
Acked-by: Paul Millar <paul.millar@desy.de>
Patch: http://rb.dcache.org/r/6988/
system-test: Pick up DN of dCache user cert if available

If the system-test user cert is installed, that DN is authorized in addition
to the DN of your primary cert.

Target: trunk
Require-notes: no
Require-book: no
Acked-by: Paul Millar <paul.millar@desy.de>
Patch: http://rb.dcache.org/r/6989/
pool: Fix error handling in staging code

A regression in 2.9. Causes pools to disable in case of staging
an existing file.

Target: trunk
Request: 2.9
Require-notes: yes
Require-book: no
Acked-by: Paul Millar <paul.millar@desy.de>
Patch: http://rb.dcache.org/r/6990/
pool: Improve how we deal with unexpected files in pools

We recently observed all kinds of weird behaviour related to whether
some files did or did not exist on a pool. We don't quite know how
we got into that mess, but we do know that dCache was not particularly
good at recoverying from the situation.

Essentially, an unexpefted file in the data directory or an unexpected
entry in the pool would cause pools to disable themselves or go into
retry loops, respectively.

This patch implements a number of defensive moves. MetaDataCache now
deletes replicas it didn't load during startup and didn't create itself,
eg files that got injected by staging after dCache timed out. If dCache
receives a request to create an entry that already exists, we now
defensively register the pool location; this mirrors the opposite situation
in which somebody tries to open a file that does not exist on a pool - in
that situation we already defensively deregistered the pool location.

Target: trunk
Request: 2.9
Request: 2.8
Request: 2.7
Request: 2.6
Require-notes: yes
Require-book: no
Acked-by: Paul Millar <paul.millar@desy.de>
Patch: http://rb.dcache.org/r/6991/
cells: Fix message counting in case of queue overflow

In case of message queue overflow, the message counters were not
decremented as they should.

Target: trunk
Request: 2.9
Request: 2.8
Request: 2.7
Request: 2.6
Require-notes: yes
Require-book: no
Acked-by: Paul Millar <paul.millar@desy.de>
Patch: http://rb.dcache.org/r/6992/
Drop messages when TTL is exceeded

The purpose of having a message TTL is to allow messages to be
discarded when the TTL is exceeded. We have used this sparingly
in a couple of services, but there is no reason why we cannot
apply this logic to all services.

We have often observed that dCache doesn't recover well from
an overload situation and I hope this change improves on that.

Target: trunk
Require-notes: yes
Require-book: no
Acked-by: Paul Millar <paul.millar@desy.de>
Patch: http://rb.dcache.org/r/6994/
fix type in gplazma ldap default value

gplazma.ldap.organization default value contains a typo

This patch fixes the typo and changes the default values to strings that
make clear that these have to be changed on order to use the ldap
plugin.

Acked-by:
Target: trunk
Require-book: no
Require-notes: no
nfs: make cell export configurable

make door well known

Acked-by: Paul Millar
Target: master
Require-book: no
Require-notes: no