Commits on Mar 24, 2017
  1. Test: Check that parsing SearchHit without _type/_id works (#23715)

    The hit object can be very small e.g. when using "stored_fields": ["_none_"],
    this adds a test that checks that we can still parse back the object.
    * also check type/id null
    cbuescher committed on GitHub Mar 24, 2017
  2. Tests: Use local clone build of 5.x with bwc tests (#22946)

    The current rest backcompat tests, which run against a mixed cluster of
    5.x and 6.0 nodes, depend on snapshot builds of 5.x. However, this has
    the potential for inconsistency that results in CI failures, and happens
    quite often, whenever some backcompat logic is added to 5.x, but the bwc
    test on master fails because the 5.x code has not yet been published as
    a snapshot.
    This change creates a git clone of the 5.x branch,
    builds the zip distribution, and ties that into gradle substitutions for
    the 5.x version.
    rjernst committed on GitHub Mar 24, 2017
Commits on Mar 23, 2017
  1. Use ParseField for aggs CommonFields rather than String (#23717)

    With this change we remove a TODO from CommonFields. Also this will be useful when parsing aggs response for the high level REST client.
    javanna committed on GitHub Mar 23, 2017
  2. Remove DocumentMapper#parse(String index, String type, String id, Byt…

    …esReference source) (#23706)
    Removed `parse(String index, String type, String id, BytesReference source)` in and replaced all of its use in Test files with `parse(SourceToParse source)`.
    `parse(String index, String type, String id, BytesReference source)` was only used in test files and never in the main code so it was removed. All of the test files that used it was then modified to use `parse(SourceToParse source)` method that existing in
    AdityaJNair committed with nik9000 Mar 23, 2017
  3. Fix line-length violations in gce/util/Access

    This commit addresses all 100-column line-length violations in
    gce/util/ and removes this file from the suppressions list.
    jasontedor committed Mar 23, 2017
  4. Fixes snapshot deletion handling on in-progress snapshot failure (#23703

    This commit fixes an issue manifested in the
    SharedClusterSnapshotRestoreIT#testGetSnapshotsRequest where a delete
    request on a snapshot encounters an in-progress snapshot, so it first
    tries to abort the snapshot.  During the aborting process, an exception
    is thrown which is handled by the snapshot listener's onSnapshotFailure
    method.  This method retries the delete snapshot request, only to
    encounter that the snapshot is missing, throwing an exception.  It is
    possible that the snapshot failure resulted in the snapshot never having
    been written to the repository, and hence, there is nothing to delete.
    This commit handles the SnapshotMissingException by logging it and
    notifying the listener of the missing snapshot.
    Closes #23663
    abeyad committed on GitHub Mar 23, 2017
Commits on Mar 22, 2017
  1. CONSOLEify some more docs

    And expand on the `stemmer_override` examples, including the
    file on disk and an example of specifying the rules inline.
    Relates to #18160
    nik9000 committed Mar 22, 2017
  2. Make it possible to validate a query on all shards instead of a singl…

    …e random shard (#23697)
    This is especially useful when we rewrite the query because the result of the rewrite can be very different on different shards. See #18254 for example.
    imotov committed on GitHub Mar 22, 2017
  3. CONSOLEify some more docs

    Relates to #18160
    nik9000 committed Mar 22, 2017
  4. Docs: CONSOLEify synonym tokenfiler docs

    Relates to #18160
    nik9000 committed Mar 22, 2017
  5. Docs: Fix language on a few snippets

    They aren't `js`, they are their own thing.
    Relates to #18160
    nik9000 committed Mar 22, 2017
  6. Painless: Fix regex lexer and error messages (#23634)

    Without this change, if write a script with multiple regexes
    *sometimes* the lexer will decide to look at them like one
    big regex and then some trailing garbage. Like this discuss post:
    def val = /\\\\/.split(ctx._source.event_data.param17);
    if (val[2] =~ /\\./) {
      def val2 = /\\./.split(val[2]);
      ctx._source['user_crash'] = val2[0]
    } else {
      ctx._source['user_crash'] = val[2]
    The error message you get from the lexer is `lexer_no_viable_alt_exception`
    right after the *second* regex.
    With this change each regex is just a single regex like it ought to be.
    As a bonus, while looking into this issue I found that the error
    reporting for regexes wasn't very nice. If you specify an invalid
    pattern then you get an error marker on the start of the pattern
    with the JVM's regex error message which attempts to point you to the
    location in the regex but is totally unreadable in the JSON response.
    This change fixes the location to point to the appropriate spot
    inside the pattern and removes the portion of the JVM's error message
    that doesn't render well. It is no longer needed now that we point
    users to the appropriate spot in the pattern.
    nik9000 committed on GitHub Mar 22, 2017
  7. Skip 5.4 bwc test for new name for now

    We have to wait for a clean snapshot build.
    nik9000 committed Mar 22, 2017
  8. Count through the primary in list of strings test

    A previous attempt to address a race condition in this test set wait for
    active shards to all. However, there might not be any replicas if the
    test is only running with one node so we end up waiting
    forever. Instead, to address the intial race condition, we just count
    through the primary.
    jasontedor committed Mar 22, 2017
  9. Skip testing new name if it isn't known

    In #23638 we renamed `request_cache` to `request` in the
    `_cache/clear` API. But it is only going to be committed back to
    5.x so we can't test with the new name in a mixed version
    nik9000 committed Mar 22, 2017
  10. Wait for all shards in list of strings test

    This test executes a bulk indexing operation with two documents. If this
    test is running against multiple nodes, there are no guarantees that all
    shards are green before we execute a search operation which might hit a
    replica shard. This commit creates the index in advance, and waits for
    all shards to be active before proceeding with the indexing request.
    jasontedor committed Mar 22, 2017
  11. Deprecate request_cache for clear-cache (#23638)

    It is called `request` now.
    StefanGor committed with nik9000 Mar 22, 2017
  12. Share XContent rendering code in terms aggs (#23680)

    The output of the different implementations of terms aggs is always very similar. The toXContent methods for each of those classes though was duplicating almost the same code multiple times. This commit centralizes the code for rendering XContent to a single place, which can be reused from the different terms aggs implementations.
    javanna committed on GitHub Mar 22, 2017
  13. Update ingest-node.asciidoc

    Fixed docs typo
    clintongormley committed on GitHub Mar 22, 2017
  14. [DOCS] Update the docs about the fact that global ordinals for _paren…

    …t field are loaded eagerly instead of lazily by default.
    Relates to #8053
    martijnvg committed Mar 22, 2017
  15. Build: remove progress logger hack for gradle 2.13 (#23679)

    We are now on minimum gradle 3.3, so we no longer need the groovy/gradle
    hacks used to support both 2.13 and 2.14+.
    rjernst committed on GitHub Mar 22, 2017
  16. Test: Add dump of integ test cluster logs on failure (#23688)

    This commit adds a build listener to the integ test runner which will
    print out an excerpt of the logs from the integ test cluster if the test
    run fails.  There are future improvements that can be made (for example,
    to dump excerpts from dependent clusters like in tribe node tests), but
    this is a start, and would help with simple rest tests failures that we
    currently don't know what actually happened on the node.
    rjernst committed on GitHub Mar 22, 2017
Commits on Mar 21, 2017
  1. Plugins: Add plugin cli specific exit codes (#23599)

    We currently use POSIX exit codes in all of our CLIs. However, posix
    only suggests these exit codes are standard across tools. It does not
    prescribe particular uses for codes outside of that range. This commit
    adds 2 exit codes specific to plugin installation to make distinguishing
    an incorrectly built plugin and a plugin already existing easier.
    closes #15295
    rjernst committed on GitHub Mar 21, 2017
  2. Plugins: Output better error message when existing plugin is incompat…

    …ible (#23562)
    This commit catches the underlying failure when trying to list plugin
    information when a plugin is incompatible with the current version of
    elasticsearch. This could happen when elasticsearch is upgraded but old
    plugins still exist. With this change, all plugins will be output,
    instead of failing at the first out of date plugin.
    closes #20691
    rjernst committed on GitHub Mar 21, 2017
  3. Reindex: wait for cleanup before responding (#23677)

    Changes reindex and friends to wait until the entire request has
    been "cleaned up" before responding. "Clean up" in this context
    is clearing the scroll and (for reindex-from-remote) shutting
    down the client. Failures to clean up are still only logged, not
    returned to the user.
    Closes #23653
    nik9000 committed on GitHub Mar 21, 2017
  4. Packaging: Remove classpath ordering hack (#23596)

    After the removal of the joda time hack we used to have, we can cleanup
    the codebase handling in security, jarhell and plugins to be more picky
    about uniqueness. This was originally in #18959 which was never merged.
    closes #18959
    rjernst committed on GitHub Mar 21, 2017
  5. Build: Make plugin list for smoke tester dynamic (#23601)

    This commit removes the hardcoded list of plugins used by the smoke
    tester and instead loads this list the same way the build does: by
    looking for directories under the `plugins` dir.
    closes #13096
    rjernst committed on GitHub Mar 21, 2017
  6. [TEST] Propertly cleans up failing restore test

    The SharedClusterSnapshotRestoreIT#testDataFileCorruptionDuringRestore
    would fail sporadically because it tried to simulate restoring a
    corrupted index.  The test would wait until the restore is finished (and
    marked as failed) before exiting.  However, in the background, the
    cluster still continues to retry allocation of the failed shards,
    despite the restore operation being marked as completed, which in turn
    generates cluster states to process.  The end of every ESIntegTestCase
    verifies that none of the nodes have any pending cluster states to
    process.  Hence, this check sometimes fails on this particular test.
    This commit solves the issue by ensuring the index is deleted before
    exiting the test.
    abeyad committed Mar 21, 2017
  7. Fix typo in allocation explain API docs

    This commit addresses a simple typo in the application explain API docs.
    Relates #23669
    fhopf committed with jasontedor Mar 21, 2017