gss: tidy up FQAN-extraction

The SRM interface and the dcap door extract a list of FQANs from a
certificate chain.  In the past, the caller was responsible for
supplying the objects used to achieve this; but, some time ago, this
changed and these objects are created within GSSUtils, independent of
the caller.

The interface was not updated to reflect this, so callers were forced
to create objects that were then not used.  Also, methods marked
themselves as throwing an Exception that they never do.

These wrinkles are fixed with this patch.

Target: master
Patch: http://rb.dcache.org/r/6656/
Acked-by: Gerd Behrmann
srm: simply job.setState

There are currently two setState methods in Job.  The two-arg version calls the 3-arg
version will the 'save' argument hard-coded to true.  The 'save' argument provides
some control over whether the updated job is saved to some JobStorage.

Currently, all calls to setState use the 2-arg version (with 'save' as true),
except for Scheduler, which explicitly calls job.saveJob, so has the same
effect as calling the 2-arg version.

This patch simplifies the process by removing the 3-arg signature method
and always calling the zero-arg saveJob method.

Target: master
Patch: http://rb.dcache.org/r/6651/
Acked-by: Gerd Behrmann
Acked-by: Dmitry Litvintsev
packaging: remove '-1' from tarball

Currently, tarballs are built with a '-1' in the filename and their
corresponding initial (containing) directory.  This is both unusual
and disconcerting.  This patch removes the '-1' from both the package
name and the initial directory.

Target: master
Request: 2.8
Request: 2.7
Request: 2.6
Request: 2.2
Patch: http://rb.dcache.org/r/6580/
Acked-by: Tigran Mkrtchyan
chimera: fix create link on existing object

throw FileExistsChimeraFsException is object with the same name already exists

Acked-by: Albert Rossi
Target: master
Require-book: no
Require-notes: no
srm: Take root path into account when selecting protocol

Changes the door selection logic such that the root path of a door is taken
into account when selecting a transfer protocol.

Also refactors the Storage interface such that the decision to reuse a door is
done in the Storage implementation rather than in the generic SRM code (which
shouldn't know about dcap).

Target: trunk
Require-notes: yes
Require-book: no
Acked-by: Paul Millar <paul.millar@desy.de>
Patch: http://rb.dcache.org/r/6645/
srm: Various minor refactorings

These things were originally part of the unique TURL patch, but are
not directly a consequence of using unique TURLs.

Target: trunk
Require-notes: no
Require-book: no
Acked-by: Paul Millar <paul.millar@desy.de>
Patch: http://rb.dcache.org/r/6646/
srm: Add SRM status code to SRMException

Makes it easier to translate exceptions to an SRM reply. Unused
in this patch, but is used in subsequent patches.

Target: trunk
Require-notes: no
Require-book: no
Acked-by: Tigran Mkrtchyan <tigran.mkrtchyan@desy.de>
Patch: http://rb.dcache.org/r/6659/
xrootd: Upgrade to xrootd4j 1.3.1

Fixes problems with null-termination of string in xrootd messages.

Target: trunk
Require-notes: yes
Require-book: no
Acked-by: Tigran Mkrtchyan <tigran.mkrtchyan@desy.de>
Patch: http://rb.dcache.org/r/6669/
Upgrade to HikariCP 1.3.2

Solves a problem with JMX releated warning messages being logged.

Target: trunk
Require-notes: no
Require-book: no
Acked-by: Tigran Mkrtchyan <tigran.mkrtchyan@desy.de>
Patch: http://rb.dcache.org/r/6670/
Add missing newline when quitting shell applications

Target: trunk
Require-notes: no
Require-book: no
Acked-by: Tigran Mkrtchyan <tigran.mkrtchyan@desy.de>
Patch: http://rb.dcache.org/r/6671/
srm: Include failed or unprocessed surls in list response

Otherwise the status of such files isn't reported back to the client.

Target: trunk
Require-notes: yes
Require-book: no
Acked-by: Tigran Mkrtchyan <tigran.mkrtchyan@desy.de>
Patch: http://rb.dcache.org/r/6673
chimera: fix inode type detection

types socket and directory have an overlapping bit.
this makes checks like

(X & IFDIR) == IFDIR

to evaluate as true for sockets and process them a directory.

Use a type mask and change check to
(X & TYPE) == IFDIR

Acked-by: Gerd Behrmann
Target: master
Require-book: no
Require-notes: no
pool: Use FireAndForgetTask instead of custom class

Target: trunk
Require-notes: no
Require-book: no
Acked-by: Tigran Mkrtchyan <tigran.mkrtchyan@desy.de>
Patch: http://rb.dcache.org/r/6676/
pool: Fix logging context for thread pool

Fixes the logging context in a thread pool used by migration tasks,
pool to pool tasks, and sticky bit expiration.

Target: trunk
Request: 2.8
Request: 2.7
Request: 2.6
Acked-by: Tigran Mkrtchyan <tigran.mkrtchyan@desy.de>
Patch: http://rb.dcache.org/r/6675/
billing: Initialize all fields in billing records

Plenty of billing records have fields that are logged as 'unknown' due to
missing values. This patch injects those missing values.

I added file path to PoolIoFileMessage to allow the pool to inject the path
into the billing record. Although the paht is known as part of StorageInfo,
StorageInfo is the wrong place to store the path: The path is not an attribute
of a file. A file can have many paths pointing to it.  A path is rather an
attribute of a particular access (the file is accessed through a path) and thus
the path should be part of the request messages. For the same reason a path
should not become an attribute in FileAttributes.

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

Patch: none
srm-client: Improve startup time

The patch cleans up the srm script and adds the '-XX:+TieredCompilation
-XX:TieredStopAtLevel=1' java options for improved startup speed. On my laptop
this has reduced the time required to run test --srm against system-test with
approximately 40 seconds.

Target: trunk
Require-notes: yes
Require-book: no
Acked-by: Tigran Mkrtchyan <tigran.mkrtchyan@desy.de>
Patch: http://rb.dcache.org/r/6692/
Improve startup speed of tools

The options for client utilities defaulted to running the JVM in interpreted
mode. This patch steps up the compilation level to allow simple JIT
compilation. This removes more than 1 second from starting the chimera utility
on my laptop, and more than 35 seconds from the build time of the system-test
module.

Target: trunk
Require-notes: yes
Require-book: no
Acked-by: Paul Millar <paul.millar@desy.de>
Patch: http://rb.dcache.org/r/6693/
system-test: Enabled tiered compilation

This change improves startup speed for the dCacheDomain in system-test setups.
Although dCache in general is not sensitive to startup speed, system-test is
restarted many times during development and startup has an effect on developer
productivity.

Since the process isn't necessarily short lived like our client tools, I did
not limit the compilation level.

On my laptop this cut about 5 seconds from process start to the last pool being
enabled.

Target: trunk
Require-notes: no
Require-book: no
Acked-by: Paul Millar <paul.millar@desy.de>
Patch: http://rb.dcache.org/r/6694/
ftp: add support for the CREATE fact

Now that dCache supports querying the creation time of a file, we
can support the CREATE fact in FTP door.

Target: master
Patch: http://rb.dcache.org/r/6695/
Acked-by: Gerd Behrmann