cells: Fix login manager login limit interpretation

Addresses an issue in FTP and DCAP doors in which the login limit
was would allow n + 1 logins when n was given as a limit. Also
addresses an issue in which a limit of zero was considered to
be no limit at all. The correct value for disabling the limit is
-1.

Target: trunk
Request: 2.6
Require-notes: yes
Require-book: no
Acked-by: Christian Bernardt <christian.bernardt@desy.de>
Patch: http://rb.dcache.org/r/5676/
info-provider: Escape percent sign in entity values

Percent signs are the only characters not allowed literally
in entity values, thus these must be escaped when exporting
the dCache configuration to an XML DTD.

The patch addresses the problem that info-provider is broken
by a recent patch adding logback formatting strings as
configuration values.

Target: trunk
Request: 2.6
Require-book: no
Require-notes: yes
Acked-by: Christian Bernardt <christian.bernardt@desy.de>
Patch: http://rb.dcache.org/r/5673/
poolmanager, doors: Don't retry stage requests on the same pool

Addresses a regression introduced between 1.9.12 and 2.2. The regression
means that poolmanager would not remember the previously tried stage pool
and thus could select the same pool twice in a row when retrying failed
stage requests.

The patches addresses this problem. To be effective, both pool manager
and doors have to be updated, although the patch does not break any
version compatibility.

Target: trunk
Request: 2.6
Request: 2.2
Require-notes: yes
Require-book: no
Acked-by: Albert Rossi <arossi@fnal.gov>
Patch: http://rb.dcache.org/r/5678/
srm: Implement SRM_FILE_BUSY response

Addresses the issue, that the SRM is ignorant to other SRM requests
it may have on the same SURL. This leads to the dreaded "Already have 1
record" error in space management, as two concurrent puts on the same
file will be allowed by the SRM, but fail in space manager. More over,
there is currently no way for the user to abort the earlier requests if
they do not have the request number.

The SRM spec says that an upload operation should cause most other
operations on that SURL to fail with SRM_FILE_BUSY. srmRm should cause
existing get and put operations on the SURL to be aborted. This patch
implements those aspects of the SRM spec.

The patch does not implement this logic for srmCopy. This will be done
in a separate patch.

Since the patch addresses a real world issue we (and probably other
sites) suffer from, I request this to be merged into 2.6. Given the
change in observable behaviour, I am reluctant to merge this into 2.2
at this point.

Target: trunk
Request: 2.6
Require-notes: yes
Require-book: no
Acked-by: Dmitry Litvintsev <litvinse@fnal.gov>
Patch: http://rb.dcache.org/r/5677/
dcache-webadmin: avoid rrd4j timestep error statement

module: dcache-webadmin (pool queue plots)

Under certain restart conditions, the rrd4j utility will report that the call to write is doing so with a timestamp which is less than 1 second since the last update.  While this error is not fatal, it is annoying to see in the log.

The extra check simply avoids writing the data under these conditions and waits till the next iteration.

TESTING DONE:

Without the patch, rapid multiple restarts of the webadmin service/httpd domain will probably produce a trace similar to this:

26 Jun 2013 09:32:47 (System) [] problem running collectPoolSeclectionUnit
java.lang.IllegalArgumentException: Bad sample time: 1372257000. Last update time was 1372257000, at least one second step is required
        at org.rrd4j.core.RrdDb.store(RrdDb.java:553) ~[rrd4j-2.1.1.jar:na]
        at org.rrd4j.core.Sample.update(Sample.java:197) ~[rrd4j-2.1.1.jar:na]
        at org.dcache.webadmin.model.dataaccess.util.RrdPoolInfoAgent.storeToRRD(RrdPoolInfoAgent.java:331) ~[classes/:na]
        at org.dcache.webadmin.model.dataaccess.util.RrdPoolInfoAgent.processPools(RrdPoolInfoAgent.java:291) ~[classes/:na]
        at org.dcache.webadmin.model.dataaccess.util.RrdPoolInfoAgent.run(RrdPoolInfoAgent.java:138) ~[classes/:na]
        at java.lang.Thread.run(Thread.java:722) [na:1.7.0]

With the patch, the log remains clean during multiple successive attempts to restart.

Target: master
Patch: http://rb.dcache.org/r/5680
Require-notes: yes
Require-book: no
Request: 2.6
Acked-by: Gerd

RELEASE NOTES:  The cause of the stack trace occasionally seen in the webadmin log file (on restart of the service) has been addressed.
pinmanager, other: Make pinmanager configuration comply with new policy

Addresses the issue that pin manager properties follow inconsistent
naming conventions.

This patch applies the naming conventions agreed to at the 2013 developers
workshop, with a few personal additions. The patch also affects most other
services, as some changed properties are used by most of them.

Guiding principals:

- All properties used by a service are prefixed by the service name (pinmanager
  in this case).

- All properties are lower case

- Properties are structured hierarchically

- A dash is used as a word separator

- Time units are made explicit by adding a property suffixes with .unit

- Properties that are used by many services have an equivalent property with
  the dcache. prefix.

- Old properties are kept during a trandition period, but marked deprecated.

- Eventually the scoping operator will be removed, but during a transition period
  it is still used. This is to avoid chaging all properties in one big bang.

New configuration families introduced:

service.<service> defines properties for communicating with other cells. Available
in both the shared dcache. hierarchy and in a per service hierarchy (currently only
pinmanager). Not for properties belonging to that service. This is only for properties
other services use to talk to <service>.

cell.threads. for properties related to threading of cell (in particular threads for
message delivery).

cell.queue. for properties related to message queueing.

authz. for authorization related properties.

Properties introduced:

dcache.service.pnfsmanager
dcache.service.poolmanager
dcache.service.billing
dcache.service.gplazma
dcache.service.spacemanager
dcache.service.pinmanager
dcache.service.replica
dcache.service.loginbroker
dcache.authz.staging
dcache.authz.staging.pep
pinmanager.cell.name
pinmanager.cell.threads.min
pinmanager.cell.threads.max
pinmanager.cell.threads.max-idle-time
pinmanager.cell.threads.max-idle-time.unit
pinmanager.cell.queue.max
pinmanager.service.poolmanager
pinmanager.service.poolmanager.timeout
pinmanager.service.poolmanager.timeout.unit
pinmanager.service.pnfsmanager
pinmanager.service.pnfsmanager.timeout
pinmanager.service.pnfsmanager.timeout.unit
pinmanager.service.pool.timeout
pinmanager.service.pool.timeout.unit
pinmanager.db.host
pinmanager.db.name
pinmanager.db.user
pinmanager.db.password
pinmanager.db.password.file
pinmanager.db.driver
pinmanager.db.url
pinmanager.db.schema.changelog
pinmanager.db.connections.max-per-partition
pinmanager.db.connections.min-per-partition
pinmanager.expiration-period
pinmanager.expiration-period.unit
pinmanager.max-pin-duration
pinmanager.max-pin-duration.unit
pinmanager.authz.staging
pinmanager.authz.staging.pep

Properties deprecated:

pnfsmanager
poolmanager
billing
gplazma
spacemanager
loginBroker
stageConfigurationFilePath
stagePolicyEnforcementPoint
pinManagerDbHost
pinManagerDbName
pinManagerDbUser
pinManagerDbPassword
pinManagerPasswordFile
pinManagerMaxActiveJdbcConnections
pinManagerMaxPinDuration

Target: trunk
Require-notes: yes
Require-book: yes
Merge branch 'master' of https://github.com/dCache/dcache
xrootd: Make xrootd configuration comply with new policy

Changes spill over to other services too, but the main focus of
the patch is to rename all xrootd properties.

Introduces:

dcache.service.loginbroker.update-period
dcache.service.loginbroker.update-period.unit
dcache.service.loginbroker.update-threshold
pool.mover.xrootd.timeout.idle
xrootd.cell.name
xrootd.net.port
xrootd.net.backlog
xrootd.net.listen
xrootd.threads
xrootd.max-total-memory-size
xrootd.max-channel-memory-size
xrootd.service.poolmanager
xrootd.service.poolmanager.timeout
xrootd.service.poolmanager.timeout.unit
xrootd.service.pnfsmanager
xrootd.service.gplazma
xrootd.service.gplazma.timeout
xrootd.service.gplazma.timeout.unit
xrootd.service.billing
xrootd.service.loginbroker
xrootd.service.loginbroker.update-period
xrootd.service.loginbroker.update-period.unit
xrootd.service.loginbroker.update-threshold
xrootd.service.loginbroker.family
xrootd.service.loginbroker.version
xrootd.service.pool.timeout
xrootd.service.pool.timeout.unit
xrootd.root
xrootd.authz.read-paths
xrootd.authz.write-paths
xrootd.authz.user
xrootd.plugins
xrootd.mover.queue
xrootd.mover.timeout
xrootd.mover.timeout.unit
admin.net.listen
dcache.net.listen
dcap.net.listen
gsidcap.net.listen
kerberosdcap.net.listen
authdcap.net.listen
dcap.service.loginbroker
dcap.service.loginbroker.update-period
dcap.service.loginbroker.update-period.unit
dcap.service.loginbroker.update-threshold
authdcap.service.loginbroker
authdcap.service.loginbroker.update-period
authdcap.service.loginbroker.update-period.unit
authdcap.service.loginbroker.update-threshold
kerberosdcap.service.loginbroker
kerberosdcap.service.loginbroker.update-period
kerberosdcap.service.loginbroker.update-period.unit
kerberosdcap.service.loginbroker.update-threshold
gsidcap.service.loginbroker
gsidcap.service.loginbroker.update-period
gsidcap.service.loginbroker.update-period.unit
gsidcap.service.loginbroker.update-threshold
ftp.net.listen
gridftp.net.listen
kerberosftp.net.listen
ftp.service.loginbroker
ftp.service.loginbroker.update-period
ftp.service.loginbroker.update-period.unit
ftp.service.loginbroker.update-threshold
gridftp.service.loginbroker
gridftp.service.loginbroker.update-period
gridftp.service.loginbroker.update-period.unit
gridftp.service.loginbroker.update-threshold
kerberosftp.service.loginbroker
kerberosftp.service.loginbroker.update-period
kerberosftp.service.loginbroker.update-period.unit
kerberosftp.service.loginbroker.update-threshold
nfsv41.service.loginbroker
nfsv41.service.loginbroker.update-period
nfsv41.service.loginbroker.update-period.unit
nfsv41.service.loginbroker.update-threshold
srm.net.listen
srm.service.loginbroker
srm.service.loginbroker.update-period
srm.service.loginbroker.update-period.unit
srm.service.loginbroker.update-threshold
webdav.net.listen
webdav.service.loginbroker
webdav.service.loginbroker.update-period
webdav.service.loginbroker.update-period.unit
webdav.service.loginbroker.update-threshold

Deprecated:

loginBrokerUpdateTime
loginBrokerUpdateThreshold
xrootdPort
xrootd/port
xrootdBacklog
xrootdThreads
xrootdMaxTotalMemorySize
xrootdMaxChannelMemorySize
xrootdPoolManagerTimeout
xrootdPoolTimeout
xrootdRootPath
xrootdAllowedWritePaths
xrootdAllowedReadPaths
xrootdPlugins
xrootdUser
xrootdIoQueue
xrootdMoverTimeout
listen
srm.loginbroker
srm.loginbroker.period
srm.loginbroker.threshold

Removed (previously deprecated):

xrootdAuthNPlugin
xrootdAuthzPlugin

Target: trunk
Require-notes: yes
Require-book: yes
Acked-by: Tigran Mkrtchyan <tigran.mkrtchyan@desy.de>
Patch: http://rb.dcache.org/r/5642/