[TEST] Allow to disable randomization of shards and replicas via system property

Needed for REST backwards compatibility tests, since we need to run older tests with the latest runner, which randomizes shards and replicas, but the tests rely on defaults (5,1).

Done in a generic way based on compatibility versions e.g. `-Dtests.compatibility=1.0.0` allows to run tests in a special manner that is compatibile with 1.0.0 version.

Also moved back randomIndexTemplate to ElasticsearchIntegrationTest (from ImmutableCluster) where all the randomized aspects should be.

Closes #5897
Send Lucene's IndexWriter infoStream messages to Logger lucene.iw, level=TRACE

Lucene's IndexWriter logs many low-level details to its infoStream
which can be helpful for diagnosing; with this change, if you enable
TRACE logging for the "lucene.iw" logger name then IndexWriter's
infoStream output will be captured and can later be scrutinized
e.g. using https://code.google.com/a/apache-extras.org/p/luceneutil/source/browse/src/python/iwLogToGraphs.py
to generate graphs like http://people.apache.org/~mikemccand/lucenebench/iw.html

Closes #5891
Remove java6ism in FSTBytesAtomicFieldData.
[TEST] Fix typo in DateHistogramTests that fails the test since it expects dates to be rounded by day.
[TEST] Use assertAllSuccessful instead of assertNoFailures in CompletionSuggestSearchTests.
Fix TemplateQueryParser swallows additional parameters

Request parameters such as "size" and "fields" were ignored when
placed after the template query in the reqest.

closes #5933
Throw exception if an additional field was placed inside the "query" body

Currently the parser accepts queries like

```
"query" : {
     "any_query": {
         ...
     },
     "any_field_name":...
}
```

The "any_field_name" is silently ignored. However, this also causes the parser
not to move to the next closing bracket which in turn can lead to additional query
paremters being ignored such as "fields", "highlight",...
This was the case in issue #4895

closes issue #4895
[TEST] Expect all shards failed in SearchWithRandomExceptionsTests
[TEST] Prevent deletion of the second document by using different ids
temporarily mute this test on Java 8 until we fix getFiniteStrings
Make Create/Update/Delete classes less mutable

Today we use a builder pattern / setters to set relevant information
to Engine#Delete|Create|Index. Yet almost all the values are required
but they are not passed via ctor arguments but via an error prone builder
pattern. If we add a required argument we should see compile errors on that
level to make sure we don't miss any place to set them.

Prerequisite for #5917
[TEST] Logger names differ based on the classpath, inside the IDE the package name is used as a prefix
Don't lookup version for auto generated id and create
When a create document is executed, and its an auto generated id (based on UUID), we know that the document will not exists in the index, so there is no need to try and lookup the version from the index.
For many cases, like logging, where ids are auto generated, this can improve the indexing performance, specifically for lightweight documents where analysis is not a big part of the execution.
closes #5917
Use segment ordinals as global ordinals if a segment contains all values for a field on a shard level.

Relates to #5854
Closes #5873
Don't create docCounts equal to maxOrd for the GlobalOrdinalsStringTermsAggregator.WithHash impl.

Relates #5873
Update setup repositories documentation

Update doc so
http://www.elasticsearch.org/guide/en/elasticsearch/reference/current/setup-repositories.html
example is going to 1.1 instead of 0.90
Fix typo
Version types `EXTERNAL` & `EXTERNAL_GTE` test for version equality in read operation & disallow them in the Update API

Separate version check logic for reads and writes for all version types, which allows different behavior in these cases.
Change `VersionType.EXTERNAL` & `VersionType.EXTERNAL_GTE` to behave the same as `VersionType.INTERNAL` for read operations.
The previous behavior was fit for writes but is useless in reads.

This commit also makes the usage of `EXTERNAL` & `EXTERNAL_GTE` in the update api raise a validation error as it make cause data to
be lost.

Closes #5663 , Closes #5661, Closes #5929
Disable dynamic scripting by default

Closes #5853
_cat/allocation to return no value for `disk.total` when not available (e.g. non data nodes) instead of `-1b`

Closes #5948