Support empty properties array in mappings
closes #5887
function_score parser throws exception if both functions:[] and single function given

In addition, add a special warning if the misplaced function is a "boost_factor"
function to avoid confusion of "boost" and "boost_function".

closes #5995
Update JNA to latest version

Updating to this version allows to configure a special JNA directory,
in case the /tmp directory is mounted with the noexec option, as JNA
extracts some data and tries to execute parts of it.

Also updated documentation to clarify mlockall and memory settings as well
as pointing to the new jna.tmpdir system property.

Closes #5493
[DOCS] Added Twitter Storehaus client

Added Twitter Storehaus client
Fix behavior on default boost factor for More Like This.

A boost terms factor of 1.0 is not the same as no boosting of terms.
The desired behavior is to deactivate boosting by default. If the user
specifies any value other than 0, then boosting is activated.

Closes #6021
Do not start a recovery process if the primary shard is currently allocated on a node which is not part of the cluster state

If a source node disconnect during recover, the target node will respond by canceling the recovery. Typically the master will respond by removing the disconnected node from the cluster state, promoting another shard to become primary. This is sent it to all nodes and the target node will start recovering from the new primary. However, if the drop of a node caused the node count to go bellow min_master_node, the master will step down and will not promote shard immediately. When a new master is elected we may publish a new cluster state (who's point is to notify of a new master) which is not yet updated. This caused the node to start a recovery to a non existent node. Before we aborted the recovery without cleaning up the shard, causing subsequent correct cluster states to be ignored. We should not start the recovery process but wait for another cluster state to come in.

Closes #6024
[DOC] Fix typo in function score query documentation.
[TEST] Replace folded blocks with literal blocks

The regex tests are formatted with blocks for readability.  Previously,
they were formatted using folded style blocks (e.g. using `>`). Folded
blocks convert newlines into spaces.  This is problematic for our regex,
since comments can only be terminated with a newline.

Effectively, anything after a comment will be commented out, making many
of the regex "silently pass".

This commit replaces them with scalar-style blocks (e.g. using `|`), which
treats newlines as significant, and thus correctly terminates comments
inside the regex.

Also fixes a regex test (`cat.thread_pool/10_basic.yaml`) that started
to fail after the block was fixed.  The test was missing a `\s+` before
the closing newline.