make sure we add the _uid as the first field in a doc
this will improve early termination loading times, but requires potential improvements in Lucene in terms of decompression
Simplified checks
Use DiscoveryModule instead of ClusterService to obtain local node id

The ClusterService might not see the latest cluster state and therefore
might not contain the local node id. Discovery will always see the local
node id since it's set on startup.
Catch RejectedExecutionException on node shutdown
Expose 'index.compound_on_flush' via engine settings

Lucene 4.4 shipped with a fundamental change in how the decision
on when to write compound files is made. During segment flush the
compound files are written by default which solely relies on a flag
in the IndexWriterConfig. The merge policy has been factored out to
only make decisions on merges and not on IW flushes. The default now
is always writing CFS on flush to reduce resource usage like open files
etc. if segments are flushed regularly. While providing a senseable
default certain users / usecases might need to change this setting if
re-packing flushed segments into CFS is not desired.

Closes #3461
Create mapping ahead of time and don't rely on index request in test
In case ttl has passed, then just check the delete count
ttl can be as lower than 0 (purge interval)
Use nonzero status code to signal abnormal termination

We currently return with status code 0 when an IOException occurs.
The plugin manager should in any case return a nonzero status if
the operation was not successful. Now the PluginManager uses the
following reponse codes based on 'sysexists.sh':
 * '0' on success
 * '64' command line usage error
 * '70' internal software error
 * '74' input/output

Closes #3463
Introducing Aggregations Module

Initial commit for the aggregation module. There are four main constructs for each aggregation:

 * aggregation - represents the outcome of the aggregation
 * aggregator - the request scope construct that computes the aggregation
 * aggregator factory - creates an aggregator of a specific type (can be configured for that type)
 * aggregator parser - parses the request xcontent and creates the appropriate aggregator factory

 There are two types of aggregations (and therefore, there are two types of aggregators):

  * Calc - an aggregation that computes counts/stats across a set of documents (eg. avg, sum, min, max,...)
  * Bucket - an aggregation that creates buckets over a set of documents, where each buckets effectively defines a set of documents (eg. terms, range, histogram, missing, filter, ...)

  The bucket aggregators can be seen as compound aggregators which can contain other aggregators. The aggregators contained in a bucket aggregator will be applied for each of the buckets that are created byt he bucket aggregator.
initial commit of the value source based implementation
second commit
third commit
cleanup & refactoring 1
cleanup & refactoring 2
cleanup & refactoring 3 - remove most of the date histogram classes and kept it minimal by reusing all the normal histogram constructs
- introducing numeric value source and value parser
- made aggregator search context aware
- api cleanup
introduced the field values context & factory
added nested aggregation support
cleanup & documentation