Commit Graph

865 Commits

Author SHA1 Message Date
Tanguy Leroux 703a88f95f Monitoring: Fix MarvelTemplateUtilsTests.java on Windows (attempt elastic/elasticsearch#2)
Original commit: elastic/x-pack-elasticsearch@10df1b26b9
2016-04-08 15:56:39 +02:00
Tanguy Leroux bc744e27c3 Monitoring: Fix MarvelTemplateUtilsTests.java on Windows
This is due to line ending differences.

Original commit: elastic/x-pack-elasticsearch@a5327cd3e6
2016-04-08 14:24:02 +02:00
Tanguy Leroux 98fc26c614 Monitoring: Manage multiple index templates
Original commit: elastic/x-pack-elasticsearch@fef9dcc5d1
2016-04-08 11:44:03 +02:00
Nik Everett 29263637c0 React to registration changes in core
Original commit: elastic/x-pack-elasticsearch@f5961dc410
2016-04-07 18:48:00 -04:00
Chris Earle daa875db11 Remove hostname from NetworkAddress.format (x-plugins side)
This removes the old usage of NetworkAddress.formatAddress in favor of the updated version, which is just
the method renamed to NetworkAddress.format (replacing the old version of that method).

There is no impact to x-plugins beyond making the build work because all places were currently using that
method variant already.

Original commit: elastic/x-pack-elasticsearch@05f0dcfa90
2016-04-07 17:29:14 -04:00
jaymode 52b6fc54b8 test: explicitly initialize anonymous user in ReservedRealmTests
Original commit: elastic/x-pack-elasticsearch@46ce5c03a1
2016-04-07 10:54:47 -04:00
jaymode 8049a82953 security: add support for main action
This commit adds support for the change in elasticsearch where the `/` rest
endpoint now delegates to an action and can be authorized.

Original commit: elastic/x-pack-elasticsearch@8ef38ce50f
2016-04-07 09:25:21 -04:00
jaymode b56e2f3bca test: reset anonymous after test to avoid messing with other tests
Closes elastic/elasticsearch#1956

Original commit: elastic/x-pack-elasticsearch@9b57d295c8
2016-04-07 06:12:02 -04:00
jaymode 931c67b49c security: add type argument to fix compile
Original commit: elastic/x-pack-elasticsearch@81acbd2e29
2016-04-06 19:09:29 -04:00
jaymode d08446e221 security: add reserved roles and users
This commit adds reserved or built-in user and role support to x-pack. The reserved roles
cannot be modified by users. The reserved users also cannot be modified with the exception
of changing the password for a user.

In order to change the password for a user, a new API has been added. This API only supports
changing passwords for native and reserved users.

To support allowing a user to change their own password, a default role has been added to grant
access. This default role only grants access to user operations that pertain to the user that is
being authorized. In other words, the default role grants `joe` the ability to change their own password
but does not allow them to change the password of a different user.

Additionally, the authenticate API was made a transport action and is granted by the default role.

Closes elastic/elasticsearch#1727
Closes elastic/elasticsearch#1185
Closes elastic/elasticsearch#1158

Original commit: elastic/x-pack-elasticsearch@1a6689d90f
2016-04-06 18:23:18 -04:00
jaymode f888082ce6 security: remove the use of shield in settings
This commit migrates all of the `shield.` settings to `xpack.security.` and makes changes to
use the new Settings infrastructure in core.

As a cleanup, this commit also renames Shield to Security since this class is only in master
and will not affect 2.x.

See elastic/elasticsearch#1441

Original commit: elastic/x-pack-elasticsearch@a5a9798b1b
2016-04-06 14:00:46 -04:00
jaymode 9031cee432 security: allow indices monitor actions to access the security index
This commit allows authorized users to monitor the security index. This fixes an issue
with the _cat/indices api, which resolves the concrete indices using the cluster state
and then makes a indices stats request. Without this change, the api fails with an
authorization exception because it is specifically requesting the security index and the
user is not the internal user.

Closes elastic/elasticsearch#1895

Original commit: elastic/x-pack-elasticsearch@070a389833
2016-04-06 12:59:15 -04:00
Tanguy Leroux 3c65f38fbe Monitoring: Update exporter & bulk in ExportersTests
Since elastic/elasticsearch#1832 exporters are created once, but the inner exporting bulks must be instanciated for each export. The CountingExporter and CountingBulk have not been updated to reflect this change.

Original commit: elastic/x-pack-elasticsearch@bbbde22363
2016-04-06 11:35:39 +02:00
Martijn van Groningen 1e3c56ce97 test: wait only for the index test_1
(there are other indices too, montoring indices and waiting for green fails there because these indices have replica shards)

Original commit: elastic/x-pack-elasticsearch@63dd3e6ebb
2016-04-06 10:52:50 +02:00
Tanguy Leroux 4df6f0f701 Monitoring: Change ExportBulk so that it has states
Original commit: elastic/x-pack-elasticsearch@8dc55dc0d2
2016-04-06 10:21:55 +02:00
Tanguy Leroux b65787f7dd Monitoring: Add segments stats to Index Stats
Original commit: elastic/x-pack-elasticsearch@e42dab0971
2016-04-06 10:05:40 +02:00
javanna 0a9b72233e Adapt to "Switch to ParseField for query names"
A ParseField object is now required to register queries against the SearchModule rather than the QueryParser#names method. ParseField handles camel case automatically. Also this allows us to log deprecation warnings (or fail in strict mode) when deprecated names are used for queries (e.g. "in", "mlt", "fuzzy_match" etc.)

Original commit: elastic/x-pack-elasticsearch@b0146e6e3d
2016-04-05 15:39:22 +02:00
Alexander Reelsen 9a5e60b58f Watcher: Add SMTP default timeouts
This adds default timeouts to the SMTP configuration to prevent infinite timeouts, that can lead to stuck watches.
This also requires to use time values instead of just milliseconds.

Closes elastic/elasticsearch#1830

Original commit: elastic/x-pack-elasticsearch@c886da7bff
2016-04-05 14:28:15 +02:00
Alexander Reelsen 366498eca4 Tests: Fix systemkeytool tests
One test was missing the check if posix permissions are supported by the file system.
As it does not make sense to not run 50% of the tests in 50% of the cases, the
logic to configure which capabilities a in-memory FS should have has been moved
into each test.

Original commit: elastic/x-pack-elasticsearch@59a32ea26d
2016-04-05 14:08:03 +02:00
Alexander Reelsen 323f80216d Security: Fix systemkey CLI tool
When called without arguments, systemkey tool returned with an AIOOE.
This fixes the issue, but also ports over the tests to jimfs, so they
can actually run, as the security manager is always enabled and thus the
tests never ran before.

Closes elastic/elasticsearch#1926

Original commit: elastic/x-pack-elasticsearch@887b681607
2016-04-05 11:46:20 +02:00
Chris Earle aa9f516655 Fix deserializing license response
Original commit: elastic/x-pack-elasticsearch@dae5e6f545
2016-04-04 18:45:15 -04:00
Tanguy Leroux 192e0cd582 Cancel cleaner future in doClose() rather than doStop()
Original commit: elastic/x-pack-elasticsearch@39ca253b31
2016-04-04 19:11:12 +02:00
Tanguy Leroux 3672e06343 Merge pull request elastic/elasticsearch#1902 from tlrx/catch-rejected-exception
Monitoring: Catch EsRejectedExecutionException when rescheduling the cleaner

Original commit: elastic/x-pack-elasticsearch@6ba20d5b8a
2016-04-04 09:24:14 -07:00
Tanguy Leroux 2ae6dec8e1 Rename RestExecuteWatchActionTest to RestExecuteWatchActionTests
Original commit: elastic/x-pack-elasticsearch@c9d8de10b2
2016-04-04 18:22:28 +02:00
Tanguy Leroux 115b037f06 Monitoring: Catch EsRejectedExecutionException when rescheduling the cleaner
closes elastic/elasticsearch#1900

Original commit: elastic/x-pack-elasticsearch@87efb135b4
2016-04-04 18:19:08 +02:00
Tanguy Leroux 652b69ad7f Monitoring: Ship segment stats with node stats
This commit adds all the following segments stats to the current node_stats document:
 - memory_in_bytes
- terms_memory_in_bytes
- stored_fields_memory_in_bytes
- term_vectors_memory_in_bytes
- norms_memory_in_bytes
- doc_values_memory_in_bytes
- index_writer_memory_in_bytes
- version_map_memory_in_bytes
- fixed_bit_set_memory_in_bytes

Original commit: elastic/x-pack-elasticsearch@ea4b8034ba
2016-04-04 18:13:24 +02:00
Alexander Reelsen 25f06bb5c1 Build: Fix packaging to not include test in artifact
A rest test was accidentally moved into the src/main/plugin-metadata
directory, which resulted the test being put into the plugin distribution
zip.

Closes elastic/elasticsearch#1907

Original commit: elastic/x-pack-elasticsearch@fbdf62b1d8
2016-04-04 17:10:07 +02:00
jaymode 4036ce97c1 shield: do not use ThreadPool#scheduleWithFixedDelay for pollers
This commit makes the user and roles poller use a self rescheduling runnable to schedule the
next run of the poller rather than using scheduleWithFixedDelay. This is done because the
pollers perform blocking I/O operations and everything using that thread pool method runs on
the schedule thread and because of this, in certain situations this can lead to a deadlock which
will prevent the cluster from forming.

Original commit: elastic/x-pack-elasticsearch@9fd0748c8c
2016-04-01 21:25:16 -04:00
Chris Earle 3126fcb856 Improved tests with better error message
Original commit: elastic/x-pack-elasticsearch@cb79988dc3
2016-04-01 14:20:03 -04:00
Chris Earle 9f41a99e37 Modifying Monitoring cleanup acknowledgement message.
Original commit: elastic/x-pack-elasticsearch@1c5e1a3175
2016-04-01 12:49:05 -04:00
Chris Earle 86ed96b83b Adding support for STANDARD license
Original commit: elastic/x-pack-elasticsearch@1671d8ade3
2016-04-01 12:49:05 -04:00
Chris Earle 55b9569f7b Removing isPaid, allFeaturesEnabled, and isActive methods from enums.
Original commit: elastic/x-pack-elasticsearch@8b8c7792c7
2016-04-01 12:49:05 -04:00
Chris Earle 5e81beabf9 Simplifying License Checks
Too many places are checking for enumerations when they're really more interested in a "higher" level of
information. This will help with the forthcoming addition of the STANDARD operation mode as well.

Original commit: elastic/x-pack-elasticsearch@2799c27e19
2016-04-01 12:49:05 -04:00
jaymode d6cab8b9f1 security: read correct file when listing users
Original commit: elastic/x-pack-elasticsearch@dca906abba
2016-04-01 06:30:34 -04:00
Tanguy Leroux 1d72eb2b61 Monitoring: Check for source_node only for assigned shard in test
Original commit: elastic/x-pack-elasticsearch@f0d5bccecd
2016-04-01 10:34:40 +02:00
Tanguy Leroux 2c1dbf3eb6 Monitoring: Clean log messages in exporters
This commit adds the node name and the exporter name as log message prefixes.

Original commit: elastic/x-pack-elasticsearch@085b2ecf3c
2016-04-01 09:48:22 +02:00
Tanguy Leroux 8a15a17442 Monitoring: Simplify bulk REST test
Original commit: elastic/x-pack-elasticsearch@0a02d3f3be
2016-03-31 17:49:27 +02:00
Tanguy Leroux 4007ff44b7 Monitoring: Fix synchronization in Exporters
This commit fixes an issue in synchronization in Exporters class. The export() method is synchronized and when used with LocalExport can provoke a deadlock. LocalExporter exports data locally using bulk requests that can trigger cluster state updates for mapping updates. If a exporters settings update sneaks in, the settings update waits for the export to terminate but the export waits for the settings to be updated... and boom.

This commit removes the synchronized and refactor Exporters/LocalExporter to use state and dedicated instance of LocalBulk for each export so that synchronizing methods is not necessary anymore.

It also lower down some random settings in MonitoringBulkTests because the previous settings almost always fill the bulk thread pool.

closes elastic/elasticsearch#1769

Original commit: elastic/x-pack-elasticsearch@f50c916f8b
2016-03-31 13:47:53 +02:00
javanna dc998764e8 Merge branch 'master' into enhancement/discovery_node_one_getter
Original commit: elastic/x-pack-elasticsearch@5a7ed8aafd
2016-03-31 10:50:21 +02:00
javanna 770de79a92 Remove DiscoveryNode#id in favour of existing DiscoveryNode#getId
Original commit: elastic/x-pack-elasticsearch@69bd4a9640
2016-03-31 10:49:45 +02:00
Tanguy Leroux b056fed38b Monitoring: Add REST test for monitoring bulk endpoint
Original commit: elastic/x-pack-elasticsearch@52166aec1f
2016-03-31 10:44:08 +02:00
javanna 02751ffff8 Merge branch 'master' into enhancement/discovery_node_one_getter
Original commit: elastic/x-pack-elasticsearch@cf4c5bc630
2016-03-30 17:26:02 +02:00
javanna 52ad574827 Remove DiscoveryNode#id in favour of existing DiscoveryNode#getId
Original commit: elastic/x-pack-elasticsearch@64951de2f9
2016-03-30 17:22:59 +02:00
javanna 83bf15494b fix checkstyle line lenght issue
Original commit: elastic/x-pack-elasticsearch@3ddbde1922
2016-03-30 16:20:22 +02:00
javanna 126383439a Rename DiscoveryNodes#localNodeMaster to isLocalNodeElectedMaster
Original commit: elastic/x-pack-elasticsearch@ccb685fe9a
2016-03-30 15:40:32 +02:00
javanna 9461dde896 Remove DiscoveryNodes#masterNode in favour of existing DiscoveryNodes#getMasterNode
Original commit: elastic/x-pack-elasticsearch@070850c49f
2016-03-30 15:40:23 +02:00
javanna 716a3e743e Remove DiscoveryNodes#masterNodeId in favour of existing DiscoveryNodes#getMasterNodeId
Original commit: elastic/x-pack-elasticsearch@acbedb87fd
2016-03-30 15:40:03 +02:00
javanna be01a18b35 Rename static DiscoveryNode#masterNode(Settings) to isMasterNode
Original commit: elastic/x-pack-elasticsearch@7b9ec10675
2016-03-30 15:39:39 +02:00
Adrien Grand ffb70f3011 IndexActionTests: Always map `foo` as a keyword.
Original commit: elastic/x-pack-elasticsearch@de2ad22c57
2016-03-30 15:21:22 +02:00
Nik Everett 0531dd8b88 Switch from getRandom to random
This is a reaction to
https://github.com/elastic/elasticsearch/pull/17394
which handled a long standing TODO in core.

Original commit: elastic/x-pack-elasticsearch@76425300a2
2016-03-30 08:58:31 -04:00
Simon Willnauer a39433ab48 prefix node attribute with node.attr
Original commit: elastic/x-pack-elasticsearch@44a0ef8fc6
2016-03-30 14:55:13 +02:00
javanna bd6775e0da Remove DiscoveryNode#masterNode in favour of existing DiscoveryNode#isMasterNode
Original commit: elastic/x-pack-elasticsearch@0bd29df7ea
2016-03-30 14:52:53 +02:00
javanna 9842e649f7 Remove DiscoveryNode#name in favour of existing DiscoveryNode#getName
Original commit: elastic/x-pack-elasticsearch@5907a80818
2016-03-30 14:47:50 +02:00
javanna 7689141909 Remove DiscoveryNode#id in favour of existing DiscoveryNode#getId
Original commit: elastic/x-pack-elasticsearch@a498f45e4a
2016-03-30 14:43:03 +02:00
javanna c8ea0758e9 Remove DiscoveryNode#id in favour of existing DiscoveryNode#getId
Original commit: elastic/x-pack-elasticsearch@44b835ae38
2016-03-30 14:42:13 +02:00
Adrien Grand 216874881f Don't rely on fielddata being enabled by default.
See elastic/elasticsearchelastic/elasticsearch#17386.

Original commit: elastic/x-pack-elasticsearch@361af3931a
2016-03-30 14:34:54 +02:00
Jim Ferenczi 2f627f6a50 Merge pull request elastic/elasticsearch#1847 from jimferenczi/drop_conf_file
Remove CONF_FILE from scripts

Original commit: elastic/x-pack-elasticsearch@4cfdc339de
2016-03-30 14:34:43 +02:00
Boaz Leskes 15e9edc2f4 Make AgentService.stopCollection wait till things are stopped
Closes elastic/elasticsearch#1848

Original commit: elastic/x-pack-elasticsearch@bc1f9b203f
2016-03-30 14:25:48 +02:00
jaymode c41fc7dc1d change xpack -> x-pack in in.bat
Leftover from elastic/elasticsearch#1799

Original commit: elastic/x-pack-elasticsearch@00d8bfea4e
2016-03-30 07:34:54 -04:00
Boaz Leskes 32dfa07dd1 MonitoringBulkTests to log in DEBUG
Original commit: elastic/x-pack-elasticsearch@04aca6c654
2016-03-30 11:39:23 +02:00
Jim Ferenczi d0c0a9efc4 Remove CONF_FILE from scripts
Support for it has been dropped in es

Original commit: elastic/x-pack-elasticsearch@d5a17a61d5
2016-03-30 11:17:15 +02:00
Boaz Leskes ec34163b01 Marvel integ test should stop and start exporters between tests. The ongoing activity messes with ESIntegTest level clean ups
Original commit: elastic/x-pack-elasticsearch@474ed7080a
2016-03-30 10:21:13 +02:00
Alexander Reelsen e0fcbcbb51 Elasticsearch: Rename plugin from 'xpack' to 'x-pack'
This is just to be consistent with out naming, which is
supposed to be `x-pack`.

Closes elastic/elasticsearch#1759

Original commit: elastic/x-pack-elasticsearch@0697f70855
2016-03-30 09:48:46 +02:00
Chris Earle 9b7feb25ca Adding type to generic call
Original commit: elastic/x-pack-elasticsearch@ec1cb8be55
2016-03-29 17:42:25 -04:00
javanna 99af2d60d3 Merge branch 'enhancement/node_client_setting_removal'
Original commit: elastic/x-pack-elasticsearch@31af38c4c9
2016-03-29 21:56:04 +02:00
jaymode fcbbb43425 shield: index metadata privilege allows shard actions
The view index metadata privilege did not grant access to the shard level field mapping
action or the shard level validate query action. This caused the apis to restrict access to
the data when it should have been allowed.

Closes elastic/elasticsearch#1827

Original commit: elastic/x-pack-elasticsearch@7832699cb6
2016-03-29 15:19:43 -04:00
jaymode 0a7b4257f5 add type parameters to fix compilation
Original commit: elastic/x-pack-elasticsearch@0a8a16f9a0
2016-03-29 15:00:53 -04:00
javanna ac1ec748a6 use TransportClient.CLIENT_TYPE constants for comparisons
Original commit: elastic/x-pack-elasticsearch@d2556e8d3d
2016-03-29 18:36:59 +02:00
jaymode c34598a3cd test: wait until threads are ready in MonitoringBulkTests#testConcurrentRequests
This commit synchronizes the start of the threads that are executing monitoring bulk requests concurrently
to ensure all threads are ready before starting. Without this some threads will execute requests while
other threads are still being constructed.

Original commit: elastic/x-pack-elasticsearch@e777fb5c28
2016-03-29 07:18:47 -04:00
javanna a5ed623251 Merge branch 'master' into enhancement/node_client_setting_removal
Original commit: elastic/x-pack-elasticsearch@af74045e0c
2016-03-29 12:34:31 +02:00
javanna d31983d6b6 adapt to additional changes, attributes is now a regular map in DiscoveryNode
Original commit: elastic/x-pack-elasticsearch@0ba590ed9b
2016-03-29 12:34:14 +02:00
Tanguy Leroux b8e8d7d246 Rename bin/xpack/esusers to /bin/xpack/users
Original commit: elastic/x-pack-elasticsearch@388eda9f24
2016-03-29 10:36:38 +02:00
Lee Hinman c62ba37759 Add API endpoints for the cluster allocation explain API
Relates to https://github.com/elastic/elasticsearch/pull/17305

Original commit: elastic/x-pack-elasticsearch@839d8dc53c
2016-03-28 17:29:01 -06:00
jaymode 2550548a44 shield: handle merging granted and non-granted indices acls
This commit changes the handling in the merge method of the IndexAccessControl class to
properly handle merging IndexAccessControl objects with differing values for the granted
flag. Prior to this commit, in a scenario where the flag differed, one IndexAccessControl granted
no access to an index, and the other granted access with DLS/FLS resulted in full access
being granted to the index.

Closes elastic/elasticsearch#1821

Original commit: elastic/x-pack-elasticsearch@e403e43689
2016-03-28 12:27:50 -04:00
jaymode 77e6622179 shield: remove the ability to specify username in request body
This commit removes the parsing of the username in the request body of a put user
request. Additionally, we use the name passed into the put role request builder rather
than the name from the parsed role descriptor.

Original commit: elastic/x-pack-elasticsearch@0a085d5844
2016-03-28 12:08:27 -04:00
jaymode 0d1f3da353 security: rename ESUsersRealm to FileRealm
This commit is the forward port of renaming the type for esusers to file. There is no
backwards compatibility maintained here. Additionally, a few other renames and
cleanups have been made:

* `esusers` commands is now `users`
* org.elasticsearch.shield.authc.esusers -> org.elasticsearch.shield.authc.file
* Validation.ESUsers -> Validation.Users
* ESUsersTool -> UsersTool
* ESUsersToolTests -> UsersToolTests
* ESNativeUsersStore -> NativeUsersStore
* ESNativeRolesStore -> NativeRolesStore.
* org.elasticsearch.shield.authz.esnative collapsed to org.elasticsearch.shield.authz.store
*  ESNativeTests -> NativeRealmIntegTests

Closes elastic/elasticsearch#1793

Original commit: elastic/x-pack-elasticsearch@d2a0c136f3
2016-03-28 06:18:57 -04:00
Chris Earle 7d481aab94 Making Watcher disabled by default for Monitoring Integration tests
Some tests [reasonably] fail due to unexpected indices appearing in the cluster due to Watcher.

- Also had to reset shieldEnabled as a static field, which makes no sense, but tests were failing unpredictably without it
    - Now they're passing unpredictably with it... will investigate

Original commit: elastic/x-pack-elasticsearch@9b6ce681d8
2016-03-25 18:45:24 -04:00
javanna 257ae2cb44 Merge branch 'master' into enhancement/node_client_setting_removal
Original commit: elastic/x-pack-elasticsearch@d3522628d4
2016-03-25 22:28:40 +01:00
Chris Earle 5d3a608786 Fix checkstyle overrun
Original commit: elastic/x-pack-elasticsearch@c965dde2e1
2016-03-25 16:54:00 -04:00
Chris Earle aacbeb2a81 Randomly Enable Watcher while running Monitoring Tests
This is required to make sure that the integration for monitoring the Watcher Threadpool is actually working.

- Also added the full property name when the assertContains check fails
- Made shieldEnabled an instance level field rather than a static one
- Added watcherEnabled field in the same fashion (including enableWatcher method that by default randomly enables it)
- Added method to locally filter the expected field names based on watcher being enabled for the failing test

Original commit: elastic/x-pack-elasticsearch@2c56e2f26f
2016-03-25 16:17:02 -04:00
javanna 622193ca40 separated attributes from node roles in DiscoveryNode
Node roles are now serialized as well, they are not part of the node attributes anymore. DiscoveryNodeService takes care of dividing settings into attributes and roles. DiscoveryNode always requires to pass in attributes and roles separately.

Original commit: elastic/x-pack-elasticsearch@32a4eb0fb4
2016-03-25 20:15:07 +01:00
Tanguy Leroux ea2be5d4d9 Merge pull request elastic/elasticsearch#1807 from tlrx/add-more-threadpool-stats
Monitoring: Add more thread pool stats

Original commit: elastic/x-pack-elasticsearch@b9e533b25d
2016-03-25 16:43:05 +01:00
Tanguy Leroux 2397158d20 Fix ClusterStateTests
Original commit: elastic/x-pack-elasticsearch@7bca8abe67
2016-03-25 16:40:38 +01:00
jaymode 1bf3a93e4f test: fix IndexPrivilegeTests after removal of predefined privileges
Original commit: elastic/x-pack-elasticsearch@6b913449b3
2016-03-25 10:43:30 -04:00
Tanguy Leroux a3807b078d Monitoring: Add more thread pool stats
This commit adds stats for generic/get/management/watcher thread pools.

Related to elastic/elasticsearch#1750

Original commit: elastic/x-pack-elasticsearch@8b001b50c6
2016-03-25 15:40:06 +01:00
javanna fc2ece87bd Merge branch 'master' into enhancement/node_client_setting_removal
Original commit: elastic/x-pack-elasticsearch@4276ae3192
2016-03-25 15:21:11 +01:00
javanna c1414b9f86 adapt to upstream changes
Original commit: elastic/x-pack-elasticsearch@7f281d6f29
2016-03-25 15:20:49 +01:00
jaymode 6fab4680a2 security: roles store poller should only update existing entries
Original commit: elastic/x-pack-elasticsearch@6573f4d689
2016-03-25 07:24:26 -04:00
jaymode 929e179150 shield: put user should validate password length
This changes the put user request builder to validate password length when a
password is provided. The validation is the same as what we use in the file
based realm.

Closes elastic/elasticsearch#1800

Original commit: elastic/x-pack-elasticsearch@fde1d6c685
2016-03-24 15:25:22 -04:00
Alexander Reelsen cf6cadf19f Build: Move xpack to plugin group
This is needed in order to make `bin/elasticsearch-plugin install xpack`
work, as it expects the plugin in a certain path.

Original commit: elastic/x-pack-elasticsearch@252c55e5a8
2016-03-24 18:38:58 +01:00
jaymode ca9ebf5351 security: refresh before searching in pollers
This commit is the forward port of fixes made in 2.3 for the roles and users
pollers. The pollers now refresh since not all operations are guaranteed to
refresh.

The clear roles tests are also made more evil since the poller runs at different
intervals on each node and can sometimes run almost continuously. The
modification requests now randomize if they refresh or not as well.

Original commit: elastic/x-pack-elasticsearch@f61159c40a
2016-03-24 12:55:35 -04:00
Chris Earle ac6b5b7c25 Modifying based on review comments
Original commit: elastic/x-pack-elasticsearch@8e3b5f4c17
2016-03-24 11:47:49 -04:00
Chris Earle 87c3730244 Removing unnecessary JavaDoc
Original commit: elastic/x-pack-elasticsearch@083f5529ac
2016-03-24 11:47:49 -04:00
Chris Earle 43de1ff8da Modify the CleanerService to use a minimum
Users running the `CleanerService` should not be able to disable it (via a `-1` as the time setting) because they'll just shoot themselves in the foot. This PR changes the behavior to allow extensive amounts via the setting (e.g., they could set it to 2 years). By doing this via the `Setting`, we can avoid a lot of boilerplate code for verification as well. If we decide to allow it to be disabled, then the setting should be explicit. I've found that users tend to not understand setting times to `-1`.

With the internal `IndicesCleaner` runnable, I have also moved the rescheduling code to `onAfter` so that it always happens, even if the license makes it temporarily invalid.

I also think that we should allow the user to dynamically set the setting regardless of it being allowed -- and warn on it. This way they can set it when it's expired or during the trial, but it will take effect when they apply the paid license. I think that this will provide a better user experience so that they do not have to remember to re-set it later.

This also removes the `LocalExporter`-specific setting that allowed it to override the global retention. If we ever add another listener, then we should add exporter-specific settings to support this kind of functionality.

Adds some tests for the settings as well as for the service, while also removing now unneeded ones.

Original commit: elastic/x-pack-elasticsearch@3abd41807e
2016-03-24 11:47:49 -04:00
Nik Everett 8e3e19d8c6 Handle method rename in core
Original commit: elastic/x-pack-elasticsearch@43b5edbff0
2016-03-24 10:42:41 -04:00
Alexander Reelsen 2f267530a6 Set version 5.0.0-alpha1
Helping commit for changes in the core

Original commit: elastic/x-pack-elasticsearch@73c8e19a29
2016-03-24 08:36:43 +01:00
Areek Zillur 84d27b52be fix for removing suggest transport action in core elasticsearchelastic/elasticsearch#17198
Original commit: elastic/x-pack-elasticsearch@c8a742c9e4
2016-03-23 16:19:36 -04:00
javanna 57114ae4f0 Merge branch 'master' into enhancement/node_client_setting_removal
Original commit: elastic/x-pack-elasticsearch@c8a896b7e3
2016-03-23 17:51:54 +01:00
Adrien Grand 71542594e6 ShieldIndexSearcherWrapper should create the scorer only once. elastic/elasticsearch#1725
Currently it first creates a scorer, then checks if the role bits are sparse,
and falls back to the bulk scorer if they are dense. The issue is that creating
scorers and bulk scorers is very expensive on some queries such as ranges,
prefix and terms queries. So it should rather check whether bits are sparse
first in order to decide whether to use the scorer or bulk scorer.

Original commit: elastic/x-pack-elasticsearch@067d630099
2016-03-23 11:38:30 +01:00
Adrien Grand 52a91d7c6f Fix compilation.
Original commit: elastic/x-pack-elasticsearch@83e6882b10
2016-03-23 11:10:45 +01:00
Tanguy Leroux fe97d2ba51 Monitoring: Add REST endpoint to allow external systems to index monitoring data
Original commit: elastic/x-pack-elasticsearch@04aa96a228
2016-03-23 10:12:00 +01:00
Tanguy Leroux 40dc747968 Monitoring: Add MonitoringClientProxy
Similar to WatcherClientProxy, the elasticsearch client used in exporters must be proxied to avoid circular dependencies at Guice's injection time. This commit add a MonitoringClientProxy as well as a MonitoringClient to be used later in monitoring's transport actions.
(cherry picked from commit b70c095)

Original commit: elastic/x-pack-elasticsearch@17327cffe5
2016-03-23 09:21:33 +01:00
Jim Ferenczi a56a5dd193 Merge pull request elastic/elasticsearch#1766 from jimferenczi/xpack_isolation
xpack plugin can be isolated now that we have xpack extension support

Original commit: elastic/x-pack-elasticsearch@933f4acf23
2016-03-22 15:58:17 +01:00
Jim Ferenczi 1fa22c921a xpack plugin can be isolated now that we have xpack extension support
Original commit: elastic/x-pack-elasticsearch@9f742c754f
2016-03-22 15:27:30 +01:00
Jim Ferenczi cc152a867a Remove sigar from the x-pack windows script classpath
Original commit: elastic/x-pack-elasticsearch@247e945ff5
2016-03-22 15:07:03 +01:00
Jim Ferenczi 0f8f70a404 Fix windows build
Avoid empty elements in x-pack bat script classpath to make JarHell happy

Original commit: elastic/x-pack-elasticsearch@06dd95b8ca
2016-03-22 14:13:33 +01:00
Jim Ferenczi 9c6aa6353e Make xpack extensible:
* Add XPackExtension: an api class (like Plugin in core) for what a x-pack extension can do.
* Add XPackExtensionCli: a cli tool for adding, removing and listing extensions for x-pack.
* Add XPackExtensionService: loading of jars from pluginsdir/x-pack/extensions, into child classloader.
* Add bin/x-pack/extension script, similar to plugin cli, which installs an extension into pluginsdir/x-pack/extensions.
* Add XPack extension integration test.

Fixed elastic/elasticsearch#1515

Original commit: elastic/x-pack-elasticsearch@130ba03270
2016-03-22 11:41:38 +01:00
javanna 25847038ee Merge branch 'master' into enhancement/node_client_setting_removal
Original commit: elastic/x-pack-elasticsearch@b36411e98f
2016-03-21 17:22:47 +01:00
jaymode c5d155efe9 security: always serialize the version with the user
This change always serializes the version with the user so that we have this information
for times when we need to make changes and deal with serialization changes. We do this
in the authentication service because the user object is also serialized as part of the get
users response and the StreamInput there will have the appropriate version set on it already
and we do not need to add it in that case.

Closes elastic/elasticsearch#1747

Original commit: elastic/x-pack-elasticsearch@a7ceece09c
2016-03-21 09:50:35 -04:00
Boaz Leskes d939289825 Change ClusterService package
As a result of ESelastic/elasticsearch#17183

Closes elastic/elasticsearch#1751

Original commit: elastic/x-pack-elasticsearch@1e553855f0
2016-03-21 13:55:48 +01:00
Martijn van Groningen 51a69c5814 Fixes for upstream percolator changes
Original commit: elastic/x-pack-elasticsearch@b31f9ff62b
2016-03-21 12:37:16 +01:00
markharwood d6df27a3ac Graph rest test fix - can time out waiting for green so trying with only 1 shard
Original commit: elastic/x-pack-elasticsearch@0e7391eb92
2016-03-21 09:33:19 +00:00
Alexander Reelsen fc99174b48 Testing: Removing AwaitsFix annotation as tests pass again
Tests had been muted in elastic/x-pack@0ba4d7ead8,
but several local runs passed.

Original commit: elastic/x-pack-elasticsearch@6bf0dfa4e3
2016-03-18 15:28:50 +01:00
jaymode 67c6cf4055 test: add debug logging and cleanup stopping of servers
Adds debug logging to try to get more information about random failures in these
tests. Also cleans up some potential issues with the code that handled the stopping
of random ldap servers to test failure cases.

See elastic/elasticsearch#1542

Original commit: elastic/x-pack-elasticsearch@573b4161dd
2016-03-18 07:34:32 -04:00
jaymode 2872acd742 remove watcher and graph privileges. manage does not include security
Original commit: elastic/x-pack-elasticsearch@da250ed842
2016-03-17 14:31:03 -04:00
jaymode 833bf726e6 define graph and watcher privileges statically
These privileges no longer need to be defined as a custom privilege since the
code is now consolidated into a single plugin. This also changes the manage
cluster privilege to be an alias to the all privilege.

Original commit: elastic/x-pack-elasticsearch@a7f444c898
2016-03-17 14:31:03 -04:00
jaymode cf0fd986e1 rename graph actions
Original commit: elastic/x-pack-elasticsearch@70a71d6bd6
2016-03-17 14:31:03 -04:00
jaymode 135742823e rename watcher actions
Original commit: elastic/x-pack-elasticsearch@5c67344595
2016-03-17 14:31:03 -04:00
jaymode 5bc3c0c1f8 security: rename actions to not use shield
This commit renames the security actions to not use shield in their action names. This
also includes updating the privileges as well.

Original commit: elastic/x-pack-elasticsearch@10460dffdb
2016-03-17 14:31:00 -04:00
jaymode a22539aca0 shield: add support for new privilege naming
This commit adds support for the privilege naming defined in elastic/elasticsearch#1342 and removes the
support for the privileges that were deprecated in 2.3. This change also includes
updates to the documentation to account for the new roles format.

Original commit: elastic/x-pack-elasticsearch@98e9afd409
2016-03-17 14:29:26 -04:00
Lukas Olson 03f8452d70 Update API spec for Shield
Original commit: elastic/x-pack-elasticsearch@6dcdfebc0a
2016-03-17 10:27:44 -07:00
Simon Willnauer 214b4f269a Use IndexModule#forceQueryCacheType instead of overriding configrations
This is a follow up from elasticsearchelastic/elasticsearch#16799 which prevents setting index
level settings on a node level.

Original commit: elastic/x-pack-elasticsearch@80d1819ab3
2016-03-17 14:25:43 +01:00
Areek Zillur 8817d2a3c0 rename license API actions
GetLicenseAction: cluster:admin/plugin/license/get --> cluster:monitor/xpack/license/get
PutLicenseAction: cluster:admin/plugin/license/put --> cluster:admin/xpack/license/put
DeleteLicenseAction: cluster:admin/plugin/license/delete --> cluster:admin/xpack/license/delete

closes elastic/elasticsearch#1717

Original commit: elastic/x-pack-elasticsearch@fe3f07cd69
2016-03-16 14:21:14 -04:00
jaymode 9e08579d4f security: file parsing only supports the new format
This commit remove the pre-existing file parsing code and replaces it with the updated
code in the RoleDescriptor class. This unifies the parsing for the files and API for roles.

Closes elastic/elasticsearch#1596

Original commit: elastic/x-pack-elasticsearch@9e0b58fcf1
2016-03-16 12:33:05 -04:00
Tanguy Leroux 1161edca2c Monitoring: Do not expose sensitive settings
Original commit: elastic/x-pack-elasticsearch@25d81bb7b6
2016-03-16 17:14:40 +01:00
Ali Beyad 8e79737b06 Merge pull request elastic/elasticsearch#1696 from abeyad/suggester-wiring
Suggester refactoring requires a Suggester to parse X-Content to Builder

Original commit: elastic/x-pack-elasticsearch@26f4d84068
2016-03-16 12:01:37 -04:00
jaymode 60500ec6af security: cleanup the logging in the native stores
A lot of messages were being logged at the info level in the native user and roles
stores. This changes the logging to be more selective in the cases where the index
does not exist or the error is really an error and the user should be notified.

Closes elastic/elasticsearch#1339

Original commit: elastic/x-pack-elasticsearch@0bc0d9bf7a
2016-03-16 10:36:12 -04:00
Ali Beyad 7d8149cb86 Suggester refactoring requires a Suggester to parse X-Content to Builder
As part of the search refactoring effort, we need to pass a Suggester
to the methods that parse X-Content to a SuggestBuilder in every
instance where we are parsing search/suggest requests.

Original commit: elastic/x-pack-elasticsearch@7f815c617a
2016-03-16 10:27:29 -04:00
Colin Goodheart-Smithe e3551a7570 [TEST] fix timeout test so it checks message but not the reported time waiting
The reported time waiting for watches can be slightly different from the actual timeout (e.g. 2.1 seconds instead of 2 seconds) so checking the time waited in the message makes the test sometimes fail

Original commit: elastic/x-pack-elasticsearch@c2cd9da486
2016-03-16 13:44:33 +00:00
Nik Everett 787ebd5850 Handle task status registration cleanup
Core reworked how it registered tasks status's with NamedWriteableRegistry
so it was more pluggable. It changed a few signatures and x-plugins needs
these small changes to keep compiling.

Original commit: elastic/x-pack-elasticsearch@3dcf1df152
2016-03-16 08:20:40 -04:00
jaymode edc9580f66 security: validate that security and audit indices can be auto created
Adds a check to the settings at startup to ensure that the security and audit indices are
allowed to be auto created if a user has disabled auto create explicitly.

Additionally fixes a small issue with the error message for watcher passing the incorrect
value.

Closes elastic/elasticsearch#1453

Original commit: elastic/x-pack-elasticsearch@2b0698ff19
2016-03-15 13:15:00 -04:00
jaymode 03336912bb security: native realm is added when defined realms are unlicensed
If a user configures only custom realms and they are not licensed to use the custom realms then
we need to return our default realms. The default realms should be the esusers and esnative realms.
We were only returning the esusers realm previously.

Closes elastic/elasticsearch#1491

Original commit: elastic/x-pack-elasticsearch@3dc2b5d3a8
2016-03-15 13:11:19 -04:00
Yannick Welsch 0136f16ce7 [TEST] Suppress exception in Watcher benchmark
Original commit: elastic/x-pack-elasticsearch@099cad0ac1
2016-03-15 16:49:21 +01:00
Yannick Welsch 61123bb107 Remove System.out.println and Throwable.printStackTrace from tests
Relates to elastic/elasticsearchelastic/elasticsearch#17112

Original commit: elastic/x-pack-elasticsearch@404e40a4be
2016-03-15 16:30:23 +01:00
Simon Willnauer 4ec4b0d7e1 Watcher should try to load trust/keystore from `config` directory
Today Watcher tries to load stuff from the bin's parent directory which
is not readable since the shared data directory has been moved out of
the nodes parent in elasticsearchelastic/elasticsearch#17072 which causes security exception
now. The test copies trust stores into the config dir and that's where
we should read it from by default or even better explicitly configure the path?!

Original commit: elastic/x-pack-elasticsearch@1d32a595cf
2016-03-15 10:07:10 +01:00
Areek Zillur 4c4eac692a fix for elasticsearchelastic/elasticsearch#16442
Use index uuid as index folder name to decouple index name from being used as index folder name

Original commit: elastic/x-pack-elasticsearch@23193bcd6e
2016-03-14 23:28:05 -04:00
Simon Willnauer 6b7dadce43 remove unused imports
Original commit: elastic/x-pack-elasticsearch@4a8f4285f8
2016-03-14 20:52:49 +01:00
Simon Willnauer 67efe608d1 add assertion DefaultIndicesAndAliasesResolver that PutMapping special case holds
Original commit: elastic/x-pack-elasticsearch@417123150a
2016-03-14 20:51:54 +01:00
Tanguy Leroux 7d377a5b7f Fix LocalIndicesCleanerTests
Original commit: elastic/x-pack-elasticsearch@3e08c84e80
2016-03-14 16:25:00 +01:00
Simon Willnauer 3d1f1814a4 Wrap lines after 140 chars
Original commit: elastic/x-pack-elasticsearch@dce9c019ae
2016-03-14 15:40:42 +01:00
Simon Willnauer 3f9508d525 Merge pull request elastic/elasticsearch#1687 from s1monw/fix_put_mapping
Don't override indices when concreteIndex is set on PutMappingRequest

PutMappingRequest has a special case since it can come with one and only
one concrete index. In such a case we can't replace the indices list
with all authorized indices but should rather only check if the index
is authorized and otherwise fail the request.

Original commit: elastic/x-pack-elasticsearch@8949b16f16
2016-03-14 15:39:46 +01:00
Simon Willnauer d37bf240fe Don't override indices when concreteIndex is set on PutMappingRequest
PutMappingRequest has a special case since it can come with one and only
one concrete index. In such a case we can't replace the indices list
with all authorized indices but should rather only check if the index
is authorized and otherwise fail the request.

Original commit: elastic/x-pack-elasticsearch@4ee20029e1
2016-03-14 15:27:42 +01:00
Tanguy Leroux 9443086655 Monitoring: Declare resolvers id & version in registry
This commit changes the location where the ID and Version of the resolvers are defined. It was in each constructor, now it is in the ResolversRegistry class. It also rename MonitoringIds to MonitoredSystem.

Original commit: elastic/x-pack-elasticsearch@81d7711c40
2016-03-14 15:22:50 +01:00
Simon Willnauer 13b7bd884a wrap lines to match 140 chars
Original commit: elastic/x-pack-elasticsearch@108a982dc1
2016-03-14 12:52:24 +01:00
Simon Willnauer cd63903665 Fix compile errors
Original commit: elastic/x-pack-elasticsearch@9e95c31e9d
2016-03-14 12:42:34 +01:00
Tanguy Leroux 45dc717b92 Monitoring: Make MonitoringDoc implements Writeable
Update after Chris & Uri comments

Original commit: elastic/x-pack-elasticsearch@74e4420b2f
2016-03-14 10:07:52 +01:00
David Pilato 5a1fbe6d62 Update Setting according to changes in master
We changed Setting signatures in master branch of elasticsearch.
We need to adapt x-plugins to the new code.

See https://github.com/elastic/elasticsearch/pull/16629.

Closes elastic/elasticsearch#1684.

Original commit: elastic/x-pack-elasticsearch@c911aaca69
2016-03-13 20:34:15 +01:00
Ryan Ernst c739e9b61f Merge pull request elastic/elasticsearch#1654 from rjernst/cli-parsing
Switch to jopt-simple

Original commit: elastic/x-pack-elasticsearch@577af5af6f
2016-03-11 12:55:22 -08:00
jaymode 8e816bdfb9 test: add tests for scroll requests with document and field level security
Original commit: elastic/x-pack-elasticsearch@107b24e785
2016-03-11 11:50:38 -05:00
Tanguy Leroux e51aa21575 Monitoring: Add export() method to Exporters class
This commit adds a synchronized "export()" method to the Exporters so that the Exporters class can be used as an export service for exporting monitoring docs.

Original commit: elastic/x-pack-elasticsearch@22bda986c5
2016-03-11 17:33:16 +01:00
markharwood 925afa3cab Graph - port of 2.x graph API and kibana UI plugin
Closes X-plugins issue 518

Original commit: elastic/x-pack-elasticsearch@6c6371ed74
2016-03-11 14:22:31 +00:00
Yannick Welsch 0abe314bb6 Merge pull request elastic/elasticsearch#1674 from ywelsch/enhance/fix-logger-usages
Fix wrong placeholder usage in logging statements

Original commit: elastic/x-pack-elasticsearch@101f043fac
2016-03-11 10:30:28 +01:00
Tanguy Leroux be0e4255ce Mute EmailAttachmentTests and HistoryTemplateEmailMappingsTests
Original commit: elastic/x-pack-elasticsearch@5d62b2af11
2016-03-11 09:33:36 +01:00
Yannick Welsch 970efba3a3 Fix wrong placeholder usage in logging statements
Also make logging message String constant to allow static checks

Relates to elastic/elasticsearchelastic/elasticsearch#16707

Original commit: elastic/x-pack-elasticsearch@b5bd423de4
2016-03-10 20:18:07 +01:00
Alexander Reelsen f417ec7e8c CLI: Remove cygwin support
Cygwin support has been removed from master, so we should be
consistent with x-plugins as well.

See elastic/elasticsearchelastic/elasticsearch#16871

Closes elastic/elasticsearch#1635

Original commit: elastic/x-pack-elasticsearch@8dd93209c7
2016-03-10 17:29:35 +01:00
Martijn van Groningen fbe0aefa0c fix compile erors due to upstream changes in node stats
Original commit: elastic/x-pack-elasticsearch@a0a600cb68
2016-03-10 13:22:59 +01:00
Simon Willnauer a033f95072 Use ShardId#getIndexName() since index name has been removed from ShardSearchRequest
Original commit: elastic/x-pack-elasticsearch@ba997d0ae3
2016-03-09 19:54:27 +01:00
Ryan Ernst 8c5d8653e0 Fix forbidden apis usages, and convert more tests to CommandTestCase
Original commit: elastic/x-pack-elasticsearch@f5400388eb
2016-03-09 00:18:23 -08:00
Ryan Ernst d880803c2d Cutover more tests to CommandTestCase
Original commit: elastic/x-pack-elasticsearch@19c168a712
2016-03-08 17:28:11 -08:00
Ryan Ernst 64419c0856 Merge branch 'master' into cli-parsing
Original commit: elastic/x-pack-elasticsearch@bfe0cdc477
2016-03-08 14:17:44 -08:00
Ryan Ernst 53d87d158f Remove old help files and references to old cli tool stuff
Original commit: elastic/x-pack-elasticsearch@b02faa5251
2016-03-08 14:16:47 -08:00
Alexander Reelsen e728a49853 Watcher: Fix home path for croneval CLI tool
Drive-by fixes putting the $JAVA binary into quotes to support spaces, like
we do in other scripts as well.

Closes elastic/elasticsearch#1642

Original commit: elastic/x-pack-elasticsearch@f40fba32cc
2016-03-08 17:48:42 +01:00
Tanguy Leroux 62ad9f4f0d Move lazy initialization classes from Watcher to XPack
This commit moves the InitializingModule and InitializingService classes in the common XPack package so that it can be used by any plugin. It also renames the module and service from Initializing* to LazyInitializing* and add a ClientProxy class.

Original commit: elastic/x-pack-elasticsearch@fbdf9d1614
2016-03-08 16:25:11 +01:00
Robert Muir 0f905e9b00 CLI: Don't let ubuntu try to install its crazy jayatana agent.
See https://github.com/elastic/elasticsearch/pull/13813

This is the corresponding workaround for x-plugins commandline tools.

Closes elastic/elasticsearch#719

Original commit: elastic/x-pack-elasticsearch@c607fd2197
2016-03-08 16:23:47 +01:00
Tanguy Leroux 146f91f730 Watcher: Rename ClientProxy to WatcherClientProxy
Original commit: elastic/x-pack-elasticsearch@84c17d1bc0
2016-03-08 14:28:39 +01:00
Alexander Reelsen f4eb0e7c7c Docs: Mention option to enable scripting for watcher-only
Deep down buried there is an option to not only allow global
script execution, but also allow a single scripting language for
watcher only. It is time to document it as well.

Renamed this option to `script.engine.groovy.inline.xpack_watch`
to align with xpack renaming.

Closes elastic/elasticsearch#1422

Original commit: elastic/x-pack-elasticsearch@845eb5a0c0
2016-03-08 12:04:28 +01:00
Alexander Reelsen 10644a2784 Watcher: Fix correct setting of email attachment names
Fix to ensure that the email attachment has a correctly set filename, which is
also now explained in the documentation.

In addition there is a check now for email attachments, that a filename can only
be specified once, otherwise an exception is thrown.

Closes elastic/elasticsearch#1503

Original commit: elastic/x-pack-elasticsearch@2a399058b3
2016-03-07 21:57:42 +01:00
Ryan Ernst bafbcd9ed3 Moved MockTerminal and cleaned up some tests
Original commit: elastic/x-pack-elasticsearch@ffb873c826
2016-03-07 12:42:44 -08:00
jaymode 03dcc5ea67 shield: copy settings to tribe nodes
The shield settings need to be copied down to the tribe nodes so that they are
aware of the shield configuration. Otherwise there will be issues such as SSL
not carrying over or authentication realms not being available.

Closes elastic/elasticsearch#702

Original commit: elastic/x-pack-elasticsearch@7bd7674f3e
2016-03-07 12:31:40 -05:00
jaymode 101ff22546 fix compile after removal of versions < 2.0.0
Original commit: elastic/x-pack-elasticsearch@61e2814aac
2016-03-07 10:53:07 -05:00
jaymode 98e904deef fix compile due to core change in NodeInfo
Original commit: elastic/x-pack-elasticsearch@3ff3fa63e6
2016-03-07 09:34:53 -05:00
Robert Muir 2a9ba9e934 lucene 6 api changes (tests only)
Original commit: elastic/x-pack-elasticsearch@8120c29cd8
2016-03-07 04:14:09 -05:00
Ryan Ernst b54e6a7ae6 Merge branch 'master' into cli-parsing
Original commit: elastic/x-pack-elasticsearch@ff525e0e00
2016-03-06 13:33:08 -08:00
Ryan Ernst 59ec9302c8 Switch cli tests to unified MockTerminal
This is the xplugins side of elastic/elasticsearchelastic/elasticsearch#16966

Original commit: elastic/x-pack-elasticsearch@a2e2faf20a
2016-03-06 13:18:40 -08:00
jaymode 186dbf547a security: protect the user and roles index
This commit adds the logic to protect the user and roles index that we store locally
by restricting access to the internal XPack user. We need to do this in two places;
the first is when resolving wildcards and the other is when authorizing requests
made against specific indices.

Original commit: elastic/x-pack-elasticsearch@8ee0ce02db
2016-03-04 17:16:03 -05:00
Ryan Ernst 6fa9c1631d Merge branch 'master' into cli-parsing
Original commit: elastic/x-pack-elasticsearch@83f7f8139d
2016-03-04 12:15:11 -08:00
Ryan Ernst 706216844b Changed esusers tool to use jopt-simple
Original commit: elastic/x-pack-elasticsearch@1f8763fcd6
2016-03-04 12:14:34 -08:00
javanna 30a7ff1daa Adapt to node.client setting removal
We would previosly check if a node was a client node, we can now check it by just verifying that it is not a transport client through client_type setting.

Original commit: elastic/x-pack-elasticsearch@bddd44866e
2016-03-04 20:41:13 +01:00
Tanguy Leroux 452e729a02 Monitoring: Fix NodeStatsResolverTests on Windows platforms
Because load_average is not available on Windows, it must be excluded from test assertions.

Original commit: elastic/x-pack-elasticsearch@f67f9bb5e7
2016-03-04 17:28:49 +01:00
Tanguy Leroux 66e49a0546 Marvel: Add integration test for Marvel+Shield with SSL
closes elastic/elasticsearch#1467

Original commit: elastic/x-pack-elasticsearch@9dd6bf9629
2016-03-04 16:55:35 +01:00
Tanguy Leroux a8e52eb520 Monitoring: Clean up and refactoring
This commit removes various constructors in monitoring documents and add a single constructeur that accepts a monitoring id and version. It also renames *Renderer classes to *Resolver and centralizes the logic of resolving the index name, type name and id in 1 place. It changes Exporter so that they use these resolvers to know in which index a given document must be indexed.

Original commit: elastic/x-pack-elasticsearch@c2349a95a6
2016-03-04 16:31:14 +01:00
Ryan Ernst fe377cfda2 Converted cron eval tool to use jopt-simple
Original commit: elastic/x-pack-elasticsearch@fde96657d5
2016-03-03 00:35:39 -08:00
Adrien Grand c16ca2c779 string has been split into text and keyword.
Original commit: elastic/x-pack-elasticsearch@b98100f8b5
2016-03-03 09:17:47 +01:00
Ryan Ernst ee2749365f Add tests for FileAttributesChecker
Original commit: elastic/x-pack-elasticsearch@eb78087e64
2016-03-03 00:03:30 -08:00
Ryan Ernst 9864ae05a2 Switch system key tool to use jopt-simple
Original commit: elastic/x-pack-elasticsearch@c5c459c77a
2016-03-02 23:16:50 -08:00
jaymode d8617556cf shield: do not require password for user update operations
When thinking about applications and the need to update a user, we should not need to
update the password of the user when making changes to things like roles, email, full
name, or metadata. This commit changes how we handle operations where the password
field is missing.

When the password field is missing, we try to execute an update. If the user exists, all
values for the user are updated except for the password field. If the user does not exist
and the password field is missing then a ValidationException is returned.

When the password field is present, we always issue an index request.

Closes elastic/elasticsearch#1492

Original commit: elastic/x-pack-elasticsearch@3d8a5f2db6
2016-03-02 10:26:55 -05:00
jaymode d46f465ddb shield: refresh on user and role modifications by default
This commit introduces the default refresh on user and role update and delete
operations. The behavior can be controlled via the `refresh` parameter on the
REST API and the refresh option in the Java API.

Closes elastic/elasticsearch#1494

Original commit: elastic/x-pack-elasticsearch@aff4d13886
2016-03-02 09:04:41 -05:00
Tanguy Leroux ab3ee46104 Fix checkstyle violation
Original commit: elastic/x-pack-elasticsearch@7730c96d7c
2016-03-02 11:14:13 +01:00
Martijn van Groningen ceaed02f38 Added `manage_pipeline` privilege and `ingest_admin` default role for the ingest feature.
Closes elastic/elasticsearch#1367

Original commit: elastic/x-pack-elasticsearch@a4c9e22203
2016-03-02 10:53:10 +01:00
Tanguy Leroux edd993077b Marvel: Only clean timestamped indices with the current template version
Only current timestamped indices, like .marvel-es-1-* indices should be deleted. Other indices like the ones created by pre v2.3.0 plugin versions should be kept (like .marvel-es-YYYY.MM.dd)

Original commit: elastic/x-pack-elasticsearch@b2aff31875
2016-03-02 10:47:30 +01:00
Tanguy Leroux b39f4dcc37 Monitoring: Index node attributes and remove default mappings in data index
Original commit: elastic/x-pack-elasticsearch@c1581ecc1b
2016-03-02 10:06:27 +01:00
Jason Tedor 4c089cf33d Bump Elasticsearch version to 5.0.0-SNAPSHOT
This commit bumps the Elasticsearch version to 5.0.0-SNAPSHOT in line
with the alignment of versions across the stack.

Relates elastic/elasticsearchelastic/elasticsearch#16862

Original commit: elastic/x-pack-elasticsearch@155641c5e4
2016-03-01 17:18:13 -05:00
jaymode c8ee64d0cb test: sort by _uid to get consistent ordering
Original commit: elastic/x-pack-elasticsearch@73b5c49ea5
2016-03-01 09:30:12 -05:00
jaymode de72f4aeee security: change DLS behavior to OR queries together
This commit changes the behavior of combining multiple document level security queries
from an AND operation to an OR operation.

Additionally, the behavior is also changed when evaluating the combination of roles that
have document level security and roles that do not have document level security. Previously
when the permissions for these roles were combined, the queries from the roles with document
level security were still being applied, even though the user had access to all the documents.
This change now grants the user access to all documents in this scenario and the same applies
for field level security.

Closes elastic/elasticsearch#1074

Original commit: elastic/x-pack-elasticsearch@291107ec27
2016-03-01 07:03:38 -05:00
javanna 0be2b6cbbc Adapt to SearchServiceTransportAction rename
Original commit: elastic/x-pack-elasticsearch@b154325787
2016-03-01 12:58:53 +01:00
uboness 2a1b3250db Cleanup Security Roles
- Renamed `AddRoleAction/Request/Response` to `PutRoleAction/Request/Response`
- also renamed the user/roles rest actions
- Changed the returned format for `RestGetRoleAction`. Previously this endpoint returned an array of role descriptor. Now it returns an object where the role names serve as the keys for the role objects. This is aligned with other APIs in ES (e.g. index templates).
- When `RestGetRoleAction` cannot find all the requested roles, it'll return an empty object and a 404 response status
- Also cleaned up `RoleDescriptor`

Original commit: elastic/x-pack-elasticsearch@742f6e0020
2016-03-01 05:47:22 -05:00
Boaz Leskes 3ddbd77090 Remove DiscoveryService and reduce guice to just Discovery elastic/elasticsearch#1571
DiscoveryService was a bridge into the discovery universe. This is unneeded and we can just access discovery directly or do things in a different way.

This is a complement to elastic/elasticsearchelastic/elasticsearch#16821

Closes elastic/elasticsearch#1571

Original commit: elastic/x-pack-elasticsearch@496f0c4081
2016-02-29 20:26:38 +01:00
jaymode 03be6e3a62 change shield in log messages to security
Original commit: elastic/x-pack-elasticsearch@9c5acc488a
2016-02-29 10:26:48 -05:00
uboness 759d99de9c changed the User API
- Now it's more aligned with other APIs in ES (e.g. index template API)
- the "get user" API now returns an object as a response. The users are keyed by their username. If none of the requested users is found, an empty object will be returned with a 404 response status.
- the body of "put user" request doesn't require "username" anymore (as it's defined as part of the URL)

Original commit: elastic/x-pack-elasticsearch@f7c12648b1
2016-02-29 09:47:39 -05:00
Alexander Reelsen 1f113e07f4 Watcher: Fail email action on attachment download issues
In case that a single email attachment cannot be downloaded, this ensures
that the whole action fails with a correct Action.Failure.

This also fixes an NPE that would occur otherwise.

Original commit: elastic/x-pack-elasticsearch@7bb042a719
2016-02-28 21:07:23 -08:00
Alexander Reelsen cc8109bc87 Watcher: Fix naming of data attachments to use id in email attachments
This is a small fix to use specified id when sending data attachments.
The current solution always used "data".

Also a minor refactoring was made to include get the different parser impls
from the EmailAttachmentsParser instead of specifying them twice in the
EmailAction.

Closes elastic/elasticsearch#1503

Original commit: elastic/x-pack-elasticsearch@9354e83c8b
2016-02-28 20:22:45 -08:00
Nik Everett d7170197f6 Handle core's log refactoring
Original commit: elastic/x-pack-elasticsearch@9e2e41db90
2016-02-26 16:06:31 -05:00
jaymode 06fc60c2f6 shield: handle null tokens when parsing roles
The roles parsing does not currently handle null tokens since the YAML parser
was not emitting them. With the upgrade to Jackson 2.7.1, the parser is now
emitting the null token value.

Original commit: elastic/x-pack-elasticsearch@abcad633ad
2016-02-26 15:03:56 -05:00
Alexander Reelsen 47f1c2daa5 Watcher: Throw exception when empty URL is handed in http requests
This ensures that invalid watches are not even added and rejected on
index time.

Closes elastic/elasticsearch#1510

Original commit: elastic/x-pack-elasticsearch@d18e0c8ef6
2016-02-25 17:31:11 -08:00
Alexander Reelsen b97fea44d7 Watcher: Fix SSL default port when using request.fromUrl
If no port was specified, port 80 was assumed, even if https was specified
was the protocol. This lead to weird failures in the logs and trying to use
SSL on port 80.

Relates elastic/elasticsearch#1567

Original commit: elastic/x-pack-elasticsearch@0ea11d612e
2016-02-25 16:26:53 -08:00
Alexander Reelsen 47ef39037b Watcher: Fix latch await in timeout tests
The awaiting latch was not waiting as long as the sleep in the code
causing the latch to fail and the test to fail.

This code aligns the time to wait for the latch and the sleep code
in the mock http server.

Original commit: elastic/x-pack-elasticsearch@8a2cc61204
2016-02-25 15:56:30 -08:00
uboness eb8dbfb998 Renamed `.shield` index to `.security`
Going forward (from 5.0 on) we'll remove all occurrences of the "shield" name/word from the code base. For this reason we want to already start using `.security` index in 2.3 such that we won't need to migrate it to a `.security` index later on.

Original commit: elastic/x-pack-elasticsearch@74a1cbfcf2
2016-02-25 15:10:22 -08:00
Alexander Reelsen 4eef709d2e Watcher: Fix timeout tests by increasing wait timeout
The request timeout and the real time the webserver slept was 5000ms.
In case of loaded systems, there might be cases, where the request was
still received in time.

This commit increases the server side sleep time to 10 seconds, to ensure
that the client aborts the request early

Original commit: elastic/x-pack-elasticsearch@718c05519f
2016-02-25 14:23:34 -08:00
Alexander Reelsen 2daef601d4 Watcher: Fix timeout tests
The current HTTP timeout tests had two problems.

* Binding to port 9200-9300
* The first request to hit was having a delay, the other ones had not,
  so if any other component hit the test inbetween (likely in a CI env),
  the HTTP request from the test itself will not be delayed.

Both cases are fixed in this commit.

Original commit: elastic/x-pack-elasticsearch@d696e020cc
2016-02-25 12:23:46 -08:00
Alexander Reelsen 2f088a60bc Watcher: Always get HTTP response body independent from error code
When an HTTP input returns an error body, right now we check if the
error code is below 400 and only then we include the body.

However using another method from URLConnection, the body can be
access always.

Closes elastic/elasticsearch#1550

Original commit: elastic/x-pack-elasticsearch@1743fd0a77
2016-02-25 10:25:34 -08:00
Nik Everett 08e0717f6b Make tests follow naming conventions
One test wasn't running because it didn't match!

Original commit: elastic/x-pack-elasticsearch@081c6b09e2
2016-02-25 13:14:01 -05:00
uboness 7fbf5645e2 fixed checkstyle error
Original commit: elastic/x-pack-elasticsearch@7676e988a8
2016-02-25 01:50:19 -08:00
uboness 266bf09437 Fixed build failure related to security roles APIs
- roles are now reliably parsed
- in `Put Role` API, added a double check to verify that the role name in the URL matches the role name if the body. Also, if the body doesn't have a role name, the role name in the URL will be used.

Original commit: elastic/x-pack-elasticsearch@5054ce8567
2016-02-25 01:38:04 -08:00
uboness 8ff6b93a3c Cleanup Security Roles
- Renamed `AddRoleAction/Request/Response` to `PutRoleAction/Request/Response`
- also renamed the user/roles rest actions

Original commit: elastic/x-pack-elasticsearch@ae0ccd61e5
2016-02-24 13:46:32 -08:00
Chris Earle 7e334a5e4b Renaming interval variable to include units and reordering constructor field values to ensure listener is added last
Original commit: elastic/x-pack-elasticsearch@60983f4190
2016-02-23 13:17:42 -05:00
Chris Earle ef81157c47 Add Javadocs
Also a minor fix to the phrasing in `MarvelLicensee#expirationMessages()`.

Original commit: elastic/x-pack-elasticsearch@9366c07930
2016-02-22 15:56:19 -05:00
Chris Earle 0b0ca8f2a6 Removing unused imports
Original commit: elastic/x-pack-elasticsearch@40c094af91
2016-02-22 15:56:19 -05:00
Chris Earle df99174122 Removing duplicated import
Original commit: elastic/x-pack-elasticsearch@1618ec79d4
2016-02-22 15:56:19 -05:00
uboness 18b08c82ca Introducing user full name, email and metadata.
- `full_name` and `email` are optional user fields
- `metadata` is an optional arbitrary meta data that can be associated with the user
- cleaned up the user actions - consistent naming (e.g. `PutUserAction` vs. `AddUserAction`)
- moved source parsing from the `PutUserRequest` to the `PutUserRequestBuilder`
- renamed`WatcherXContentUtils` to `XContentUtils` and moved it to sit under `o.e.xpack.commons.xcontent`

Closes elastic/elasticsearch#412

Original commit: elastic/x-pack-elasticsearch@5460e3caf7
2016-02-22 10:22:36 -08:00
Alexander Reelsen 6d0d09468b Watcher/Shield: Ensure only one .in.bat file exists
This was a leftover from watcher/shield being different plugins.

Closes elastic/elasticsearch#1530

Original commit: elastic/x-pack-elasticsearch@521b4bad14
2016-02-21 15:20:24 -08:00
Tanguy Leroux a27d2bcc50 Fix line length
Original commit: elastic/x-pack-elasticsearch@bbf883437f
2016-02-21 15:19:52 -08:00
Tanguy Leroux b5f40adb12 Marvel: Add stats for primary shards
closes elastic/elasticsearch#1198

Original commit: elastic/x-pack-elasticsearch@e823d01397
2016-02-21 14:39:52 -08:00
jaymode e3f53be3ef test: disable marvel for watcher disabled tests
We shouldn't have marvel enabled for these tests because we get false test failures
due to marvel indices existing and failing to lock the shard.

Original commit: elastic/x-pack-elasticsearch@11123bb660
2016-02-21 14:11:43 -08:00
jaymode d9ca4e0ce3 fix shield settings to not rely on iteration order
This removes the use of group setting for `shield.` and introduces some individual settings
and some group settings that should not overlap and cause issues when iteration order
changes.

See elastic/elasticsearch#1520

Original commit: elastic/x-pack-elasticsearch@193e937193
2016-02-21 10:10:52 -08:00
Simon Willnauer 64e4ccf9a0 Update x-pack to elastic/elasticsearchelastic/elasticsearch#16740
Original commit: elastic/x-pack-elasticsearch@63a3f49730
2016-02-20 17:21:47 -08:00
Adrien Grand 7b2fae3982 Unmute DynamicIndexNameIntegrationTests.
Closes elastic/elasticsearch#1527

Original commit: elastic/x-pack-elasticsearch@4ba9fe5f08
2016-02-15 16:12:57 +01:00
Colin Goodheart-Smithe 77ffdbcbb4 Merge pull request elastic/elasticsearch#1519 from colings86/refactor/aggRefactoringChanges
X-Plugin changes due to the changes in the Aggregations Java API

Original commit: elastic/x-pack-elasticsearch@524be093de
2016-02-15 11:33:42 +00:00
Adrien Grand 026c26db54 Mute DynamicIndexNameIntegrationTests.
Original commit: elastic/x-pack-elasticsearch@1795d24800
2016-02-15 12:07:40 +01:00
javanna 4482cd4f6c Adapt to removal of unused generics type from TransportMessage
followup of elastic/elasticsearch#15776, the type is not needed anymore.

Original commit: elastic/x-pack-elasticsearch@3f96dc552d
2016-02-12 17:21:28 +01:00
Colin Goodheart-Smithe 197b8fe56f X-Plugin changes due to the changes in the Aggregations Java API
Original commit: elastic/x-pack-elasticsearch@b983d0a00f
2016-02-12 12:06:06 +00:00
Simon Willnauer ec76d3bce0 Fix imports
Original commit: elastic/x-pack-elasticsearch@79e4535040
2016-02-12 10:52:48 +01:00
uboness ffe339ae31 Refactoring for 5.0 - phase 5
- Moved all settings in Marvel from `marvel.*` to `xpack.monitoring.*`
- Cleaned up marvel settings in general - they're all now under `MarvelSettings` class
- fixed some integration tests along the way (they were configured wrong and never actually tested anything)
- Updated the docs accordingly
- Added `migration-5_0.asciidoc` under the Marvel docs to explain how to migrate from Marvel 2.x to XPack 5.0.
- Replaced all `marvel` mentions in the logs to `monitoring`
- Removed the `xpack.monitoring.template.version` setting from the templates
- renamed the templates to `monitoring-es-data.json` and `monitoring-es.json`
- monitoring indices are now `.monitoring-es-<version>-data` and `.monitoring-es-<version>-<timestamp>`

Original commit: elastic/x-pack-elasticsearch@17f2abe17d
2016-02-11 21:34:38 +01:00
jaymode 95a8f77146 shield: do not throw exception if authorization header is not a basic token
Custom realms may enable the use of other authorization schemes than just basic authentication
and these schemes should work in addition to our built in realms. However, our built in realms use
the UsernamePasswordToken class to parse the Authorization header, which had a check to ensure
the token was for basic authentication and if not, an exception was thrown. The throwing of the
exception stops the authentication process and prevents custom realms from evaluating the header
if they come later in the ordering of realms.

This change removes the throwing of the exception unless the header starts with 'Basic ' and is invalid.

Original commit: elastic/x-pack-elasticsearch@fd438ded95
2016-02-11 09:59:35 -05:00
uboness 42c9eead60 Refactoring for 5.0 - phase 4
- renaming `ShieldPlugin` to `Shield` (it's no longer a plugin)
 - renaming `WatcherPlugin` to `Watcher` (it's no longer a plugin)
 - renaming `MarvelPlugin` to `Marvel` (it's no longer a plugin)
 - renaming `LicensePlugin` to `Licensing` (it's no longer a plugin)
 - renamed setting:`watcher.enabled` -> `xpack.watcher.enabled`
 - renamed setting:`marvel.enabled` -> `xpack.marvel.enabled`

Original commit: elastic/x-pack-elasticsearch@35a6540b11
2016-02-10 11:15:35 +01:00
Igor Motov dbff0e1144 Add task cancellation mechanism
See elastic/elasticsearchelastic/elasticsearch#16320 for more information

Original commit: elastic/x-pack-elasticsearch@4f8a9b1258
2016-02-09 22:31:08 -05:00
Nik Everett 97e8cdc5f0 Remove suppression and implement hashCode
Original commit: elastic/x-pack-elasticsearch@0505f28e78
2016-02-09 21:49:13 -05:00
Jason Tedor 602f67d7c6 Use MessageDigests abstraction in core
This commit removes the message digest providers in x-plugins by using
the MessageDigests abstraction in core. In particular, this permits the
removal of the use of MessageDigest#clone in x-plugins.

Closes elastic/elasticsearch#1489

Original commit: elastic/x-pack-elasticsearch@6868e6e8ed
2016-02-09 10:18:00 -05:00
uboness 3a6a1d5dc2 Shield refactoring for 5.0 - phase 3
- Consolidated the `bin` and `config` directories of watcher, shield and marvel under a single `config/xpack` and `bin/xpack` directories.

 - updated docs accordingly

Original commit: elastic/x-pack-elasticsearch@c2aa6132fa
2016-02-09 16:06:49 +01:00
uboness 92f027159a Shield refactoring for 5.0 - phase 2
- Started to move configuration under the `xpack` name
 - Cleaned up `ShieldPlugin`
 - renamed `ShieldClient` to `SecurityClient`
 - Introduced `XPackClient` that wraps security and watcher clients

Original commit: elastic/x-pack-elasticsearch@f05be0c180
2016-02-09 14:32:33 +01:00
jaymode 50452e403f test: filter out unsupported ciphers when checking default socket factory
Closes elastic/elasticsearch#2

Original commit: elastic/x-pack-elasticsearch@6510f65dc4
2016-02-09 08:14:05 -05:00
Alexander Reelsen e8ad8cbb36 Watcher: Load versioned index template for watch history
This loads an index template for the watch history to make sure,
that field changes are taken into account.

Also, the dynamic mapping for the watch history template has been
changed from strict to false.

This means that new fields can be included in a document, but they
will not indexed and are not searchable.

In addition the index names have been changed from .watch_history-$date to
.watcher-history-$template-$date - using dashes to be more consistent.

Closes elastic/elasticsearch#1299

Original commit: elastic/x-pack-elasticsearch@794f982234
2016-02-09 09:39:07 +01:00
Simon Willnauer 25c3a66502 Fix compile error after core change
Original commit: elastic/x-pack-elasticsearch@ba170bbc63
2016-02-08 21:57:12 +01:00
jaymode aa2eb15f31 fixes to allow bad apple tests to pass
This commit fixes the bad apple tests that failed when running them. The
IndexAuditTrailEnabledTest was removed and the test was folded into the
IndexAuditIT. Some watcher tests that relied on mustache were moved
into the QA tests with the mustache plugin.

Additionally, fixing these tests uncovered a issue with the privileges needed
for writing data into an index. If the mappings need to be updated because
of a write, then the update mapping action gets executed. In 2.x this was
handled by the system user, but now is executed under the user's context,
which is the correct thing to do. The update mapping action is now added to
the read, index, crud, and write privileges for an index.

Original commit: elastic/x-pack-elasticsearch@30711f9625
2016-02-08 09:48:10 -05:00
Jason Tedor 7f5349db57 Avoid cloning Mac instances
This commit modifies the HmacSHA1Provider to return a thread local
instance of Mac instead of using clone since some providers do not
support clone.

Closes elastic/elasticsearch#1468

Original commit: elastic/x-pack-elasticsearch@cb38f5f9e8
2016-02-06 09:12:39 -05:00
Alexander Reelsen e6784d5c7d Checkstyle: Adhere to checkstyle in all xpack .java files
In elastic/elasticsearch#1442 checkstyle checks were added, but also some files were freed from this.
If we have support for checkstyle, we should check this for all files and not allow
exceptions. This commit removes the file list to ignore any files and fixes all the
java files.

Original commit: elastic/x-pack-elasticsearch@99e6cbc5be
2016-02-05 16:57:41 +01:00
Simon Willnauer 878d244a96 Fix compilation failures
Original commit: elastic/x-pack-elasticsearch@4afbf84c20
2016-02-05 16:07:46 +01:00
Tanguy Leroux 4488cacdd8 Marvel: Add permission for HTTPExporter + SSL support
See elastic/elasticsearch#1451

Original commit: elastic/x-pack-elasticsearch@5e3d87149e
2016-02-05 15:21:27 +01:00
Alexander Reelsen 93a3d3f570 Watcher: Ensure that HTTP headers are case insensitive in response
According to RFC 2616 HTTP headers are case insensitive.
But `HttpResponse#contentType()` only looks up for Content-Type.

This stores all header responses lower cased in the HTTP response.

Closes elastic/elasticsearch#1357

Original commit: elastic/x-pack-elasticsearch@c009be8365
2016-02-05 14:59:27 +01:00
Jason Tedor 166e8786ea Fix compilation from upstream XContentType changes
This commit fixes a compilation issue that arose from upstream changes
in core where some method names on XContentType were changed.

Closes elastic/elasticsearch#1463

Original commit: elastic/x-pack-elasticsearch@0a3763dbb5
2016-02-05 07:28:47 -05:00
Jim Ferenczi cc8ae273c9 Merge pull request elastic/elasticsearch#1462 from jimferenczi/rename_plugin_cmd
bin/plugin is now bin/elasticsearch-plugin

Original commit: elastic/x-pack-elasticsearch@8ecf75af66
2016-02-05 12:52:54 +01:00
Tanguy Leroux d70b49f42d Marvel: Add source_node information to marvel documents
This commit adds a new `source_node` field to all marvel documents that holds various information (node's name/ip/host/id/transport address) about the node that emitted the document.

(cherry picked from commit elastic/x-pack@29a411a931)

Original commit: elastic/x-pack-elasticsearch@66e057d334
2016-02-05 11:50:07 +01:00
Jim Ferenczi e18e537bef bin/plugin is now bin/elasticsearch-plugin
Original commit: elastic/x-pack-elasticsearch@077f2a6357
2016-02-05 10:31:58 +01:00
jaymode 8996a3710a shield: remove deleted transport handlers
Original commit: elastic/x-pack-elasticsearch@a9803509d8
2016-02-04 13:31:11 -05:00
jaymode 8d70501f25 fix compilation due to TestShardRouting changes in core
Original commit: elastic/x-pack-elasticsearch@51f17b5b67
2016-02-04 13:21:40 -05:00
Ryan Ernst ab95b33df5 Terminal cleanup
This is the xplugins side of elastic/elasticsearchelastic/elasticsearch#16443

Original commit: elastic/x-pack-elasticsearch@1ab1b4b941
2016-02-04 02:06:37 -08:00
Simon Willnauer 09c8374cfe Merge branch 'master' into fix_settings_filtering
Original commit: elastic/x-pack-elasticsearch@ba664a5b79
2016-02-04 09:29:07 +01:00
Simon Willnauer d430a2ab5e Apply feedback from @uboness
Original commit: elastic/x-pack-elasticsearch@cb7c347657
2016-02-04 09:27:53 +01:00
Nik Everett 3ebe266d13 Merge pull request elastic/elasticsearch#1428 from nik9000/trask_status
Support task status

Original commit: elastic/x-pack-elasticsearch@9e2ca22b4a
2016-02-03 18:30:22 -05:00
Simon Willnauer 1c5d04c99b Cleanup settings filtering after elastic/elasticsearchelastic/elasticsearch#16425
This change registers all filtered settings up-front and removes all
the unnecessary wrappers around SettingsFilter. This is a pretty big
change and needs some review but after all things are generally simplified and
settings are always filtered even if shield is not enabled which is the right thing
todo.

Relates to elastic/elasticsearchelastic/elasticsearch#16425

Original commit: elastic/x-pack-elasticsearch@c7df85492b
2016-02-03 21:53:08 +01:00
Simon Willnauer 11d4e69267 Add missing setting
Original commit: elastic/x-pack-elasticsearch@59db7b52fd
2016-02-03 14:09:42 +01:00
Simon Willnauer 610bd8c820 Merge branch 'master' into migrate_to_strict_settings
Original commit: elastic/x-pack-elasticsearch@608c37fa4c
2016-02-03 13:22:27 +01:00
Martijn van Groningen 3bf5dc14f9 revert change: 'test: fix tests to not use mustache' and instead moved these test to qa module
Original commit: elastic/x-pack-elasticsearch@502d877c24
2016-02-03 12:56:54 +01:00
Simon Willnauer 422163445e Converte to strict settings infrastructure elastic/elasticsearchelastic/elasticsearch#16365
Original commit: elastic/x-pack-elasticsearch@c877a21e2d
2016-02-03 11:28:17 +01:00
Martijn van Groningen 4d30dadba9 test: fix tests to not use mustache
Original commit: elastic/x-pack-elasticsearch@4a88d0d458
2016-02-03 10:47:35 +01:00
Martijn van Groningen e617d8365f watcher: Removed custom xmustache script and use mustache script engine in lang-mustache module
The lang-mustache module has been extended to meet Watcher's needs:
* The ability to refer the specific slots in arrays.
* An `content_type` option controls whether json string escaping is used. Otherwise there is no escaping.

Closes elastic/elasticsearch#1116

Other changes:
* I changed tests that were just using mustache just because it was around to not use mustache
* I moved tests to `test-xpack-with-mustache` module that were testing mustache with Watcher
* added smoke test for watcher and mustache
* moved some tests around
* instead of using DefaultTextTemplateEngine in watcher tests use MockTextTemplateEngine
* added a mock mustache script engine
* Cleanup some messy tests to not rely on mustache and move them back into xpack module
* moved array access test to smoke test watcher with mustache module
* test: simplified the condition search test to take the time component out of it, while still simulation a condition
* removed the mustache dependency in the messy-test-watcher-with-groovy module

Original commit: elastic/x-pack-elasticsearch@6a2a4e885f
2016-02-03 09:18:50 +01:00
uboness 266917e1bc fix build
More places where String.format was missing a Locale

Original commit: elastic/x-pack-elasticsearch@6e3df91526
2016-02-03 00:16:24 +01:00
uboness db003cd2a4 fix build
Added Local to String.format

Original commit: elastic/x-pack-elasticsearch@2c7368c3de
2016-02-02 23:12:36 +01:00
uboness ffab6da42d fix build with latest core changes
`Terminal.println(..)` doesn't support varargs arguments anymore

Original commit: elastic/x-pack-elasticsearch@533a4f7919
2016-02-02 20:57:05 +01:00
uboness e039ef412f Shield refactoring for 5.0
- Consolidated `InternalMarvelUser`, `InternalWatcherUser` and `InternalShieldUser` into a single `XPackUser` - this is the single internal user for xpack that has all the permissions internally required by xpack (for marvel, watcher and shield)

 - Renamed `InternalSystemUser` to `SystemUser`

 - Removed the notion of "reserved roles". Now that we have a single internal user we know its role. The authz service now checks to see if the current user is the internal xpack user, and if so, it just uses its role (and not trying to resolve it from the role store). With this model, it's no longer possible for outside users to use the internal role (it's fully internal)

 - Consolidated the notion of an `InternalClient` (in Marvel it was knows as the `SecuredClient`). This is an ES client that xpack is using to manage itself. If shield is enabled, it will execute all request on behalf of the internal xpack user.

 - Removed the verification of the license plugin on plugin installation - no need to do it anymore as the license plugin is part of the distribution.

Original commit: elastic/x-pack-elasticsearch@c851410f93
2016-02-02 18:05:01 +01:00
Tanguy Leroux 766fc3273b Fix compilation errors
From elasticsearch core commit 10b5ffcda5

Original commit: elastic/x-pack-elasticsearch@d77909332f
2016-02-02 10:31:21 +01:00
Ryan Ernst 7519d035a7 Switch to UserError for cli tools
This is the xplugins side of elastic/elasticsearchelastic/elasticsearch#16359

Original commit: elastic/x-pack-elasticsearch@547b3f50e0
2016-02-01 17:38:42 -08:00
Nik Everett 8fe5afd8a7 Support task status
This is the x-content buddy of https://github.com/elastic/elasticsearch/issues/16344

Original commit: elastic/x-pack-elasticsearch@db216f7b46
2016-02-01 18:18:45 -05:00
jaymode c3b6146a72 shield: clean up hack to force switching to the system user for internal action
This commit cleans up the hack we had forcefully switching the request to execute under the system
user when a internal action gets triggered from a system request. The authorization service now tracks
the originating request in the context to allow us to validate if the request should be run as the system
user.

The system user should be used only when a user action causes an internal action, which needs to
be run by the system user.

Closes elastic/elasticsearch#1403

Original commit: elastic/x-pack-elasticsearch@4972df459f
2016-02-01 14:07:15 -05:00
uboness c9d54c0c83 Cleanup and refactoring
- removed `/_shield/roles` and `/_shield/users` endpoints (only keeping the singular forms)
 - fixed `ClearRealmsCacheTests` to use the correct endpoint for clearing the realms cache
 - used action name constants where possible in `InternalShieldUser`

Original commit: elastic/x-pack-elasticsearch@d1481de389
2016-02-01 19:51:43 +01:00
Ryan Ernst 3893ad9c5f Merge branch 'master' into remove_multicast
Original commit: elastic/x-pack-elasticsearch@7d107e88fc
2016-02-01 07:26:21 -08:00
uboness 96b2930ac7 Cleanup and refactoring
- Moved all role action classes to live under `o.e.s.action.role`
 - Moved all realm related action classes (for now just the clear cache) to live under `o.e.s.action.realm`
 - Moved all user action classes to live under `o.e.s.action.user`
 - Moved all the rest actions to live under `o.e.s.rest.action`
 - Changed the `clear role cache` endpoint to `/_shield/role/{id}/_clear_cache` (aligned with all other role endpoints)
 - Changed `InternalShieldUserHolder` to the `InternalShieldUser` singleton user... to be aligned with `InternalMarvelUser` and `InternalWatcherUser`.
 - Removed the dedicated audit log user. The new `InternalShieldUser` is now the user that manages and writes to the audit log indices
 - Extracted the `User.System` class to a top level `InternalSystemUser` class (to be aligned with the other internal user classes)
 - Removed the `SystemRole` class (the `InternalSystemUser` class now holds all the needed info/logic)

Original commit: elastic/x-pack-elasticsearch@cf82b257d1
2016-02-01 13:08:38 +01:00
Alexander Reelsen c226590e77 Watcher tests: Fix imports resulting in checkstyle exceptions
Original commit: elastic/x-pack-elasticsearch@1e55ca7bf1
2016-02-01 11:14:30 +01:00
Simon Willnauer 2698441770 Fix test compilation failures
Original commit: elastic/x-pack-elasticsearch@5d166a63fa
2016-02-01 10:54:18 +01:00
Simon Willnauer 9c0ae6411c Fix test compilation failures
Original commit: elastic/x-pack-elasticsearch@303df9b9dd
2016-02-01 10:51:49 +01:00
Boaz Leskes d27b9b4b41 Migrate the rest of NettyTransport settings to the new infra
Also does some consistency clean up, renaming trasnport.netty.* settings to transport.*

Closes elastic/elasticsearch#1397

Relates to https://github.com/elastic/elasticsearch/pull/16307

Original commit: elastic/x-pack-elasticsearch@4a128ff68c
2016-02-01 10:41:16 +01:00
Alexander Reelsen 0fe7716459 HttpClient: Prevent NPE when no path is specified
Original commit: elastic/x-pack-elasticsearch@47f26a5850
2016-02-01 10:37:51 +01:00
Simon Willnauer 6287a1300a Catch IOExcption after core change
Original commit: elastic/x-pack-elasticsearch@1fa5a3dc82
2016-02-01 10:27:33 +01:00
Alexander Reelsen 4a686f04cf Watcher: Do not encode URLs in HttpClient
When using a path like `"/<logstash-{now%2Fd}>/_search"` in the
http webhook. The already escaped slash (%2F) got escaped twice
and thus did not work any more.

The escaping happened when the code created an URI and was done
as part of that constructor. This is now switched to an URL (which
is used at the end anyway) which does not do the escaping, even though
this was required for the query string, which is now done when constructing.

Closes elastic/elasticsearch#1364

Original commit: elastic/x-pack-elasticsearch@861b6d2378
2016-02-01 09:19:07 +01:00
Ryan Ernst 131fd679b9 Remove multicast references
Xplugins side of elastic/elasticsearch#16326

Original commit: elastic/x-pack-elasticsearch@10d3ec2ebb
2016-01-31 17:44:18 -08:00
Jason Tedor e13a5e695a Uppercase ells ('L') in long literals
This commit removes all lowercase ells ('l') in long literals because
they are often hard to distinguish from the digit representing one
('1').

Closes elastic/elasticsearch#1414

Original commit: elastic/x-pack-elasticsearch@98b38705fb
2016-01-30 22:18:02 -05:00
Tanguy Leroux 970c95b6a8 Marvel: various tests fixes
Two regressions have been introduced in elastic/x-pack@156d9e4d5b: marvel index templates should not be deleted between tests and checking for marvel indices existence should not fail with IndexNotFoundException when the indices are not yet created and Shield enabled.

closes elastic/elasticsearch#1396 elastic/elasticsearch#1394 elastic/elasticsearch#1382

In MultiNodesStatsTests.java, multiple nodes are started in async: the first node may collect marvel data multiple times when the last one just started. So we should not check for exact 1 doc per node but at least 1 doc per node.

closes elastic/elasticsearch#1370

In HttpExporterTemplateTests.java, we must compare a long count with a long value.

Original commit: elastic/x-pack-elasticsearch@732fef995a
2016-01-29 17:25:07 +01:00
Alexander Reelsen 4e1d44110b Marvel: Fix compilation issues in tests
Original commit: elastic/x-pack-elasticsearch@9ffc4c501b
2016-01-29 15:15:25 +01:00
Alexander Reelsen 7147354525 Marvel: Fix compilation problem
Original commit: elastic/x-pack-elasticsearch@4db33fc6ab
2016-01-29 15:12:18 +01:00
Alexander Reelsen 8635d264ae Shield: Give native stores possibility to exit poller loop
Similar to the lifecycle services, stopping the shield lifecycle should
also ensure that the poller threads are stopped, which is tricky, in case
they run through huge user/role lists.

Original commit: elastic/x-pack-elasticsearch@7a48f19853
2016-01-29 10:16:15 +01:00
Ali Beyad e2feb61297 IndexStatsTests.testIndexStats awaits a fix on elastic/elasticsearch#1396
Original commit: elastic/x-pack-elasticsearch@0db738f324
2016-01-28 17:32:53 -05:00
jaymode 4b6ac7ceb8 shield: restore non-empty original contexts
Restoring empty contexts causes issues with searches, but failure to restore the
original context when executing index requests that auto-create results in a
the index operation being tried by the system user.

See elastic/elasticsearch#1380

Original commit: elastic/x-pack-elasticsearch@522f857de7
2016-01-28 14:07:59 -05:00
jaymode 1b4bac8203 shield: only restore the original if we forcefully replaced it
Original commit: elastic/x-pack-elasticsearch@347a4dba3f
2016-01-28 12:50:46 -05:00
Tanguy Leroux 19545596cf Marvel: Fix NodeStatsRendererTests and NodeStatsTests on Windows
Load average is not available anymore on Windows, the tests should not check the presence of the field. Also, "node_stats.json" file is hard to maintain and quite useless so this commit removes it.

Original commit: elastic/x-pack-elasticsearch@74d2e0dce6
2016-01-28 16:59:05 +01:00
jaymode 75894e6b38 shield: also restore original context to transport handlers
See elastic/elasticsearch#1380

Original commit: elastic/x-pack-elasticsearch@afbd964f18
2016-01-28 10:54:45 -05:00
jaymode 9c080681d8 shield: restore the original context when the listener is called
Also, restores running the watcher tests.

See elastic/elasticsearch#1380

Original commit: elastic/x-pack-elasticsearch@0e0c748c04
2016-01-28 09:48:26 -05:00
Boaz Leskes 0b73e3ef33 Update to incorporate changes made in Netty settings in elasticsearch elastic/elasticsearch#16200
Original commit: elastic/x-pack-elasticsearch@0e54a24519
2016-01-28 15:24:59 +01:00
Boaz Leskes dfb9068e33 Update Index usage to elasticsearchelastic/elasticsearch#16217
elasticsearchelastic/elasticsearch#16217 changed the Index class to also include index UUIDs . This commit adapts the code for it.

Closes elastic/elasticsearch#1377

Original commit: elastic/x-pack-elasticsearch@87c909c15a
2016-01-28 08:38:44 +01:00
jaymode 4012b4c7c6 test: mute watcher tests for now until. See elastic/elasticsearch#1380
Original commit: elastic/x-pack-elasticsearch@f8d9053ef6
2016-01-27 18:14:11 -05:00
jaymode 634b3edf4e only set the client instance once in the proxy
Original commit: elastic/x-pack-elasticsearch@55eb6288db
2016-01-27 14:24:41 -05:00
jaymode 7645698070 go back to setting the shield user header
Original commit: elastic/x-pack-elasticsearch@0921bd27a9
2016-01-27 13:48:51 -05:00
jaymode dcf9074c4f fix compile after change to Client settings in core
Original commit: elastic/x-pack-elasticsearch@ab069484a6
2016-01-27 12:33:35 -05:00
Jay Modi d587ace5f1 Merge pull request elastic/elasticsearch#1374 from jaymode/request_context
replace ContextAndHeaders with ThreadContext

Original commit: elastic/x-pack-elasticsearch@469ab3f5a1
2016-01-27 11:30:00 -05:00
jaymode ee7a109827 add comments about client wrapping and add ClientWithUser
Original commit: elastic/x-pack-elasticsearch@472c6dbd80
2016-01-27 10:16:14 -05:00
jaymode ed7c4273c3 test: remove check in ClearRolesCacheTests that is prone to failure
This removes a check in the ClearRolesCacheTests that is prone to failure due to the
possibility of the cache poller running while we modify documents and updating cached
values prior to the test issuing the get roles call.

See elastic/elasticsearch#1354

Original commit: elastic/x-pack-elasticsearch@ba0b803466
2016-01-27 09:25:59 -05:00
jaymode e82c969959 migrate from ContextAndHeaders to ThreadContext
This change migrates all of the xpack code to use the new ThreadContext when
dealing with headers and context data. For the most part this is a simple
cutover, but there are some things that required special casing. The internal
actions that executed by a user's requests need to forcefully drop the context
and set the system user. The workaround for this will be improved in a followup.
Additionally, the RequestContext still lives on due to the OptOutQueryCache,
which requires some core changes to fix this issue.

Original commit: elastic/x-pack-elasticsearch@87d2966d93
2016-01-27 08:02:01 -05:00
Jason Tedor d02ddece8f Merge pull request elastic/elasticsearch#1375 from jasontedor/script-settings
Script settings

Original commit: elastic/x-pack-elasticsearch@a2f4da6784
2016-01-27 06:54:24 -05:00
Simon Willnauer 6c290d22c1 Fix renamed constant
Original commit: elastic/x-pack-elasticsearch@709cd849b2
2016-01-27 11:55:15 +01:00
Adrien Grand 11125797bc Fix mapping definitions.
Original commit: elastic/x-pack-elasticsearch@609f12602e
2016-01-27 09:26:05 +01:00
Jason Tedor 8eb97c5509 Script settings
This commit is the x-plugins side of the refactoring of script settings.

Relates elastic/elasticsearchelastic/elasticsearch#16197

Original commit: elastic/x-pack-elasticsearch@4c429933b9
2016-01-26 21:13:29 -05:00
Areek Zillur 4586ca2e06 [TEST] ensure later license issue date
Original commit: elastic/x-pack-elasticsearch@fcedb7ae18
2016-01-26 15:49:01 -05:00
jaymode 3fdf9ad390 test: use the correct stop watcher url
Original commit: elastic/x-pack-elasticsearch@6fa81079bb
2016-01-26 10:22:33 -05:00
Martijn van Groningen 39a56202cf test: added ingest actions
Original commit: elastic/x-pack-elasticsearch@102751aa5f
2016-01-26 14:20:29 +01:00
jaymode 8d67195ffc test: add additional logging to debug ClearRolesCacheTests CI failures
See elastic/elasticsearch#1354

Original commit: elastic/x-pack-elasticsearch@a7cbf5e08c
2016-01-25 14:38:17 -05:00
uboness 978996e088 cleanup shield's `Privilege` and `Permission` constructs
- broke down these classes to multiple top level classes
- also `Role` is not a top level class

Original commit: elastic/x-pack-elasticsearch@8900f869e1
2016-01-25 12:54:04 +01:00
uboness 8781990ca8 fix build - compilation
Original commit: elastic/x-pack-elasticsearch@7508ed0c38
2016-01-22 18:36:53 +01:00
markharwood 03944c9a95 Settings - change over to o.e.common.settings.Setting for http.enabled setting
Original commit: elastic/x-pack-elasticsearch@3b551a6fb6
2016-01-22 14:56:38 +00:00
javanna 80aa3e29dd [TEST] the jvm flag is not returned anymore as site plugins support has been removed
Original commit: elastic/x-pack-elasticsearch@f02a42aed6
2016-01-22 14:33:55 +01:00
uboness 617c51cc86 fix build (settings cannot be prefixed with `.`)
Original commit: elastic/x-pack-elasticsearch@62178e1e82
2016-01-21 11:50:53 +01:00
Tanguy Leroux e6832e5881 Marvel: Fix MultiNodesStatsTests
Closes elastic/elasticsearch#960

Original commit: elastic/x-pack-elasticsearch@969f22fcf7
2016-01-21 10:31:47 +01:00
Tanguy Leroux d4afcf4e4e Marvel: Fix CleanerServiceTests when setting is equal to 0
closes elastic/elasticsearch#1319

Original commit: elastic/x-pack-elasticsearch@2dd8d61376
2016-01-21 09:36:28 +01:00
Simon Willnauer 01bc1f4124 Pass identity function as a client wrapper #Relates to elastic/elasticsearchelastic/elasticsearch#16101
Original commit: elastic/x-pack-elasticsearch@5eff4b440b
2016-01-20 09:39:37 +01:00
Simon Willnauer a30c6c2780 Add generic type and suppress warnings to test
Original commit: elastic/x-pack-elasticsearch@b454af89bd
2016-01-20 09:21:05 +01:00
jaymode 471ee7d867 shield: add rest API spec for authenticate api
Original commit: elastic/x-pack-elasticsearch@3dcfd5549b
2016-01-19 12:51:42 -05:00
Simon Willnauer 8831a880b1 Upgrade to new index settings infrastructure
As of elastic/elasticsearchelastic/elasticsearch#16054 all index level settings
must be registered and use the new settings infrastructure. This commit
prepares for the merge to provide a smooth transition.

Original commit: elastic/x-pack-elasticsearch@bc0a4fec07
2016-01-19 12:03:11 +01:00
Adrien Grand fedfdde216 Fix compilation after elastic/elasticsearchelastic/elasticsearch#16059.
Original commit: elastic/x-pack-elasticsearch@60e083a739
2016-01-19 09:32:52 +01:00
Ryan Ernst 80617ab39e Test: Make rest tests extend ESTestCase
This is the xplugins side of elastic/elasticsearchelastic/elasticsearch#16070.

Original commit: elastic/x-pack-elasticsearch@57d1a9108b
2016-01-18 16:44:56 -08:00
Lee Hinman da3d7177be Add Shield HTTP APIs for users and roles
Relates to elastic/elasticsearch#33

Original commit: elastic/x-pack-elasticsearch@a0942c9334
2016-01-18 16:21:22 -07:00
Nik Everett 1feea91734 Merge pull request elastic/elasticsearch#1235 from nik9000/more_remove_inject
Stop building query parsers with guice

Original commit: elastic/x-pack-elasticsearch@c621cfc94d
2016-01-18 17:40:04 -05:00
Jason Tedor 69ee9d77ad Reflect upstream load average change
This commit addresses the handling of load averages in Marvel due to
upstream changes in core Elasticsearch where the load average field was
changed from an array to an object.

Original commit: elastic/x-pack-elasticsearch@9ea57968bb
2016-01-18 15:50:17 -05:00
Nik Everett d713f203ad Fix compilation error after core shifted
Core is slowly removing raw types. Slowly. And one such removal broke shield.

Original commit: elastic/x-pack-elasticsearch@aa1b668c63
2016-01-18 10:37:39 -05:00
Tanguy Leroux 9e4686536a Marvel: Map renderers by object class rather than by name
Original commit: elastic/x-pack-elasticsearch@8f6dd0c530
2016-01-18 15:12:42 +01:00
Tanguy Leroux a30b894166 Marvel: Check that document count is the same on all data nodes
closes elastic/elasticsearch#1214

Original commit: elastic/x-pack-elasticsearch@1cf352fa3b
2016-01-15 10:51:16 +01:00
javanna af60f45c4a fix failing DefaultIndicesResolverTests due to upstream change
get aliases api returns now closed indices too by default

Original commit: elastic/x-pack-elasticsearch@d97e18cd71
2016-01-14 15:04:58 +01:00
Alexander Reelsen 9aa5c0ba62 Tests: Disabling Watcher in LdapUserSearchSessionFactoryTests
Due to lingering threads when shutting down when running this in CI
this disables watcher in this tests. It is really hard to reproduce
to get the correct order of start/stop. The reason here is, that watcher
is still starting and not finished, when stop is called on the plugin.

Original commit: elastic/x-pack-elasticsearch@2de85bcba6
2016-01-13 18:29:30 +01:00
Daniel Mitterdorfer 5a9289d777 Correct load average structure for NodeStatsRendererTests
In elastic/elasticsearchelastic/elasticsearch#15907, we changed the load average
structure to also include 5 and 15 minute load averages. This
commit adjusts the expected JSON structure for
NodeStatsRendererTests.

Original commit: elastic/x-pack-elasticsearch@59f6a1e9d9
2016-01-12 08:29:51 +01:00
Nik Everett b94670acc0 Remove serialVersionUID
It doesn't do anything and Elasticsearch will likely ban using it.

Original commit: elastic/x-pack-elasticsearch@c243c913c4
2016-01-11 13:34:05 -05:00
Simon Willnauer 07a4146068 Fix import after IndexingOperationListeners infrastructure cleanup in elasticsearch/15875
Original commit: elastic/x-pack-elasticsearch@aa1bc847eb
2016-01-10 20:23:33 +01:00
jaymode 94ce98ad9f always debug the user dn role mapping
When debugging role mapping it is useful to know the actual user DN, which is only logged
when something is actually mapped to the DN. Since this is logged at debug level, we should
always log it.

Original commit: elastic/x-pack-elasticsearch@b690c757d3
2016-01-08 14:32:22 -05:00
Jason Tedor 2b5c28242d Remove use of j.u.c.ThreadLocalRandom
This commit removes all uses of java.util.concurrent.ThreadLocalRandom
across the codebase.

Original commit: elastic/x-pack-elasticsearch@eca3701357
2016-01-08 12:21:30 -05:00
Nik Everett 2d50c77717 Merge pull request elastic/elasticsearch#1258 from nik9000/unneeded_suppress
Remove unneeded SuppressWarnings

Original commit: elastic/x-pack-elasticsearch@1c20a8c3fc
2016-01-08 11:21:28 -05:00
jaymode c5592ee3be add the ability to utilize load balancing and failover for ldap
Previously we only exposed the use of a single URL for LDAP realms, while the code supported
multiple URLs. Internally we always used a failover server set, which would have provided failover
to another LDAP server if multiple existed. This change introduces a new setting `load_balance.type`
on the realm that indicates the type of load balancing. Valid options are:

* `failover` - the first server in the list will be used until it fails and then additional servers will be tried until
one succeeds. The first successful server will be used from now on. This is the default.
* `round_robin` - continuously iterates through the list of servers for each new connection. If a server is down,
the iteration will continue until a successful connection is made. The downfall here is that the list does not
get reordered on a down server, so there is overhead for always trying the servers in order.
* `dns_failover` - This server set takes a single URL that uses a DNS that will resolve to multiple IP addresses.
Connections will be consistently attempted to servers in the order they are retrieved from the name service; there
is no re-ordering and the first successful connection will be used.
* `dns_round_robin` - This server set takes a single URL that uses a DNS that will resolve to multiple IP addresses.
The addresses retrieved from the name service will connected to in the same order as `round_robin`.

Closes elastic/elasticsearch#31

Original commit: elastic/x-pack-elasticsearch@9ce9a1bf23
2016-01-07 09:14:41 -05:00
Alexander Reelsen f68f9aa268 Watcher: Fix test failure by ensuring non-null argument for equality check
Original commit: elastic/x-pack-elasticsearch@b811dcdf7e
2016-01-07 15:09:38 +01:00
Alexander Reelsen 39403028db Watcher: Added missing equals/hashcode methods to EmailAttachments
In order to correctly check for equality in an EmailAction, all the email
attachments have to implement equals/hashCode methods.

This has already been added to the 2.x branch in elastic/x-pack@ebde22507f

Original commit: elastic/x-pack-elasticsearch@bb980ea934
2016-01-07 14:25:51 +01:00
Tanguy Leroux cdb3869b1b Marvel: Do not collect data in SecuredClientTests
closes elastic/elasticsearch#1242

Original commit: elastic/x-pack-elasticsearch@cd8f8ce2fa
2016-01-07 11:58:36 +01:00
Alexander Reelsen 75ab4f9470 Watcher: Allow for external email attachments
This feature is mainly done for the integration with the commercial reporting, but can be used
for anything else as well.

This adds a `attachments` to the email configuration, which can be used like this

```
"attachments" : {
  "some_id" : {
    "http" : {
      "request" : {
        "url" : "http://example.org/foo.pdf"
      }
    }
  },
  "other_id" : {
    "data" : {
      "format" : "json"
    }
  }
}
```

The main reason to pick this format is extensibility. If we would like to support another
attachment type, like an file reader, we could do so easily from an API point of view.

Closes elastic/elasticsearch#870

Original commit: elastic/x-pack-elasticsearch@66d14be965
2016-01-07 10:49:13 +01:00
Adrien Grand 2bab66dcb5 Remove warmers from the known actions.
Original commit: elastic/x-pack-elasticsearch@325f77518f
2016-01-07 10:30:35 +01:00
Tanguy Leroux 54215200ba Marvel: HttpExporter should not clean indices
This commit removes the current implementation in HttpExporter so that it does not automatically clean indices anymore.

Original commit: elastic/x-pack-elasticsearch@7d30338355
2016-01-07 10:05:02 +01:00
Tanguy Leroux 57b7c7eb85 Marvel: Automatic deletion of expired timestamped indices
closes elastic/elasticsearch#1057

Original commit: elastic/x-pack-elasticsearch@6cf24a0a0d
2016-01-07 10:05:02 +01:00
Alexander Reelsen 080c2afc55 Watcher: Allow execute Watch API fields in request params
In order to have a shortcut for the execution of a watch and
specifying the record_execution and ignore_condition booleans,
so are now supported in the HTTP request parameters as well.

Closes elastic/elasticsearch#918

Original commit: elastic/x-pack-elasticsearch@bed5da40b7
2016-01-07 10:00:11 +01:00
Nik Everett 38dcbc50b6 Remove unneeded SuppressWarnings
Original commit: elastic/x-pack-elasticsearch@46d86d555e
2016-01-06 20:07:27 -05:00
Alexander Reelsen 9108001c73 Watcher: Remove pre 2.0 compatibility code
This code is not needed anymore in any 2.x version.

Original commit: elastic/x-pack-elasticsearch@8346b0120e
2016-01-06 17:25:13 +01:00
Martijn van Groningen 996a9a9891 shield: add percolator query terms fields to the allowed fields if FLS is enabled
Fixes issue that came from upstream change elastic/elasticsearch#13646

Original commit: elastic/x-pack-elasticsearch@53f796c9c3
2016-01-06 17:04:59 +01:00
Martijn van Groningen 6f2208cc86 test: upstream changes for elastic/elasticsearch#13646
Original commit: elastic/x-pack-elasticsearch@0b2bff1b06
2016-01-06 16:09:25 +01:00
Alexander Reelsen 9709036024 Watcher: Adding PagerDuty Action
* This action enables sending notifications to pager duty services.
* Utilizes pager duty's REST API
* Similar to the `email`, `hipchat` and `slack` actions, multiple `pagerduty` accounts can be configured, each with its own Service API key
* A `pagerduty` account is roughly mapped to a service in your pagerduty service.
* `pagerduty` actions are associated with an account, or if not, their events will be sent via the default account.
* An incident can be acknowledged, resolved or triggered

Closes elastic/elasticsearch#492

Original commit: elastic/x-pack-elasticsearch@72cc21d119
2016-01-06 08:58:46 +01:00
Nik Everett de12d4b58d Stop building query parsers with guice
This is the fallout from
https://github.com/elastic/elasticsearch/pull/15761

Original commit: elastic/x-pack-elasticsearch@9509feb310
2016-01-05 13:53:40 -05:00
jaymode e8eb0fa312 test: only specify the XPackPlugin once
Original commit: elastic/x-pack-elasticsearch@46249d54c6
2016-01-05 13:37:43 -05:00
Igor Motov 852aac0b9c Add support for the task management framework
These changes are required to support elastic/elasticsearchelastic/elasticsearch#15347

Original commit: elastic/x-pack-elasticsearch@37adf4fc83
2016-01-05 11:09:31 -05:00
Simon Willnauer ebcca4f3c2 Prepare for removal of #getIndexTimeInMillis
In `https://github.com/elastic/elasticsearch/pull/14632/` IndexingStats#getIndexTimeInMillis()
has been removed and is superseeded by IndexingStats#getIndexTime() which is already avaliable

Original commit: elastic/x-pack-elasticsearch@2caba81352
2016-01-05 09:39:32 +01:00
Igor Motov c4569432d1 Fixes a race condition in HandshakeWaitingHandlerTests
Closes elastic/elasticsearch#1210

Original commit: elastic/x-pack-elasticsearch@bf130a969e
2016-01-04 11:46:53 -05:00
Tanguy Leroux 2cec08798b Marvel: Merge ClusterInfoCollector in ClusterStatsCollector
This commit merge the ClusterInfoCollector in the ClusterStatsCollector so that cluster stats are retrieved only once.

Original commit: elastic/x-pack-elasticsearch@fe70149210
2016-01-04 14:45:31 +01:00
Tanguy Leroux eeb5842730 Marvel: Use versioned index templates
This commit changes the templates so that they are now versionned using a number (starting from 1). This number is used in index templates names (ex: .marvel-es-data-1, .marvel-es-1) as well as in indices names (ex: .marvel-es-1-2015-12-30, .marvel-es-data-1).

If the template does not exist, it is created. Otherwise nothing (no update) is done.

Original commit: elastic/x-pack-elasticsearch@66c1a8bed0
2015-12-31 16:26:17 +01:00
Tanguy Leroux a931e4e0b8 Marvel: Add tribe nodes support
This commit enable tribe nodes support for Marvel. It avoid ElasticsearchSecurityException when a tribe node is connected to a cluster that has been configured for both Shield and Marvel by loading the MarvelShieldIntegration support on tribe node even if marvel.enabled is set to false. It also allows tribe nodes to be monitored using Marvel with their own marvel settings.

closes elastic/elasticsearch#1088

Original commit: elastic/x-pack-elasticsearch@e0401c1288
2015-12-30 12:20:49 +01:00
Alexander Reelsen d3ced7161b Watcher: Allow `url` as shortcut in requests
Instead of having to specify `scheme`, `host`, `port`, `path` and `params` each
one can now use the `url` field and specify something like `http://example.org/foo?bar=baz`

This works for HttpRequest and HttpRequestTemplate

Original commit: elastic/x-pack-elasticsearch@8c052cf419
2015-12-30 12:18:17 +01:00
Tanguy Leroux cc0933733c Marvel: Reimplement SecuredClient
closes elastic/elasticsearch#1150

i#Update after Uri's review

Original commit: elastic/x-pack-elasticsearch@2526dc9da1
2015-12-30 11:32:41 +01:00
Robert Muir 2655db3d72 remove outdated build.gradle parameter
Original commit: elastic/x-pack-elasticsearch@63bc9907e6
2015-12-29 09:25:34 -05:00
Adrien Grand fbe777005b Use currentName instead of text() to parse field names.
Original commit: elastic/x-pack-elasticsearch@f4b75c3f2d
2015-12-28 16:44:16 +01:00
Tanguy Leroux d904fa5931 Marvel: Restore cluster_state.nodes
Original commit: elastic/x-pack-elasticsearch@7cf33baf2a
2015-12-23 16:59:29 +01:00
Adrien Grand ff0217d80d Merge pull request elastic/elasticsearch#1153 from jpountz/remove/index_name_back_compat
x-pack sibling of elastic/elasticsearchelastic/elasticsearch#15488

Original commit: elastic/x-pack-elasticsearch@cccaee133b
2015-12-23 15:02:49 +01:00
Yannick Welsch 4ddd7af334 Fix issue where license metadata deserialization swallows other custom metadata
Closes elastic/elasticsearch#1190

Original commit: elastic/x-pack-elasticsearch@5c5280fee5
2015-12-22 15:49:25 +01:00
Alexander Reelsen 0cd636422c Watcher: Prevent double creation of node services
Because of specifying the concrete implementations in WatcherPlugin.nodeServices(),
all of those services got created twice for each node (guice requires the interface here).
This resulted in NPEs as the first instantiation did not run doStart() and thus had empty
settings, that resulted in a NPE.

Closes elastic/elasticsearch#1179

Original commit: elastic/x-pack-elasticsearch@c6a1f5093f
2015-12-22 11:29:04 +01:00
Adrien Grand dbc863add7 Upgrade to lucene-5.5.0-snapshot-1721183.
Original commit: elastic/x-pack-elasticsearch@2dea406d5f
2015-12-21 17:30:20 +01:00
Ryan Ernst c86e8b9c2e Remove wildcard imports
Original commit: elastic/x-pack-elasticsearch@65b2fee336
2015-12-18 14:15:06 -08:00
Robert Muir 114184b5dd disable license headers check for x-plugins, until we figure out what it should do
Original commit: elastic/x-pack-elasticsearch@48bc84865c
2015-12-18 13:27:52 -05:00
Simon Willnauer 1d95a7593f Merge pull request elastic/elasticsearch#1162 from s1monw/update_to_new_settings_infra
Upgrade X-Pack to new ClusterSettings infrastructure

Original commit: elastic/x-pack-elasticsearch@82df682838
2015-12-18 11:12:40 +01:00
Simon Willnauer 9713041fb4 Merge branch 'master' into update_to_new_settings_infra
Original commit: elastic/x-pack-elasticsearch@bf4eb0ef46
2015-12-18 10:21:34 +01:00
Martijn van Groningen de37a6e3ed shield: Enable fls and dls by default
* allow bulk requests with updates if fls/dls isn't configured for targetted index
* throw a hard error if the current call can't resolve an associated transport request
marvel: node stats collector should use the client instead of the internal apis, because otherwise the index searcher wrapper can't locate the transport request that is associated with current call and would then throw an exception, which then prevents the marvel agent from collecting stats.
* if both field or document level security is enabled then all forbidden operations should fail

Original commit: elastic/x-pack-elasticsearch@b2c40d6559
2015-12-18 10:16:08 +01:00
Zachary Tong 40b7f97559 Fix compile due to change in InternalSearchResponse signature
Original commit: elastic/x-pack-elasticsearch@8415605621
2015-12-17 15:52:49 -05:00
jaymode 7f97a1bf5d test: set anonymousEnabled in a before class method to prevent changes between tests
Original commit: elastic/x-pack-elasticsearch@e1496ca725
2015-12-17 14:16:45 -05:00
Adrien Grand 53a757a5de Fix compilation due to changes in elastic/elasticsearchelastic/elasticsearch#15511.
Original commit: elastic/x-pack-elasticsearch@5a6e77a246
2015-12-17 18:08:28 +01:00
jaymode 7691859baa add REST authenticate API
The REST authenticate API can be used to test credentials and retrieve details about the
user that has been authenticated. This currently includes retrieving the user's username
and roles.

Closes elastic/elasticsearch#1019

Original commit: elastic/x-pack-elasticsearch@117a226187
2015-12-17 12:00:41 -05:00
Simon Willnauer 080590f56c Upgrade X-Pack to new ClusterSettings infrastructure
This change adds compatability with https://github.com/elastic/elasticsearch/pull/15278

Original commit: elastic/x-pack-elasticsearch@100c5c0efb
2015-12-17 17:21:47 +01:00
Robert Muir 2d5cdf8ed8 lenient -> missingClasses
Original commit: elastic/x-pack-elasticsearch@bf19d3d843
2015-12-17 03:44:51 -05:00
Jack Conradson 9370ea99d0 Updated the plumbing for scripts to accept compile time parameters.
Closes elastic/elasticsearch#1155

Original commit: elastic/x-pack-elasticsearch@a7fd92f052
2015-12-16 18:29:10 -08:00
Ryan Ernst 3529231b5d Merge pull request elastic/elasticsearch#1157 from rjernst/disable_mock_plugins
Fix xplugins to suppress mock transport and transport service

Original commit: elastic/x-pack-elasticsearch@5e3f7041fd
2015-12-16 18:22:10 -08:00
Ryan Ernst 134cdb22bb Fix xplugins to suppress mock transport and transport service
This is the xplugins side of elastic/elasticsearchelastic/elasticsearch#15495

Original commit: elastic/x-pack-elasticsearch@9c29c057a5
2015-12-16 18:13:56 -08:00
Robert Muir 3375993e99 add third party audit for x-pack build
Original commit: elastic/x-pack-elasticsearch@fbb2016934
2015-12-16 18:57:05 -05:00
Ryan Ernst 60659c39fc Merge pull request elastic/elasticsearch#1145 from rjernst/http_type
Use NetworkModule for transport/http related extensions

Original commit: elastic/x-pack-elasticsearch@731ea8b2aa
2015-12-16 11:54:43 -08:00
Adrien Grand 9bec5b6f6d x-pack sibling of elastic/elasticsearchelastic/elasticsearch#15488
Original commit: elastic/x-pack-elasticsearch@db5f78fe19
2015-12-16 19:44:47 +01:00
Britta Weber 267b86c57f Marvel: add implementation for synced flush to SecuredClient
see elastic/elasticsearch#15396

Original commit: elastic/x-pack-elasticsearch@c60c271738
2015-12-16 17:41:04 +01:00
Britta Weber 6cf8f261e1 Update handler list to include synced flush
see elastic/elasticsearch#15396

Original commit: elastic/x-pack-elasticsearch@e41ddbf9fa
2015-12-16 17:19:21 +01:00
Ryan Ernst 1a9a79caa4 Use NetworkModule for transport/http related extensions
This is the xplugins side of elastic/elasticsearch#15434.

Original commit: elastic/x-pack-elasticsearch@728d8b728a
2015-12-15 19:38:11 -08:00
Ryan Ernst cfdfd4ed7c Add todo comment for disabled rest test
Original commit: elastic/x-pack-elasticsearch@6f4dae5903
2015-12-11 18:24:27 -08:00
Ryan Ernst 5739d4d921 Fixes for integ tests not using hardcoded ports
Original commit: elastic/x-pack-elasticsearch@9cc86da9e0
2015-12-11 18:23:01 -08:00
Jason Tedor de293ec225 Remove usage of Collections#shuffle(List)
This commit removes usage of Collections#shuffle(List) as this is a
forbidden method in upstream Elasticsearch.

Relates elastic/elasticsearchelastic/elasticsearch#15287, relates elastic/elasticsearchelastic/elasticsearch#15299

Original commit: elastic/x-pack-elasticsearch@2943569ee1
2015-12-11 11:36:41 -05:00
Adrien Grand aefd963327 Simplify xcontent usage.
This commit simplifies xcontent usage in x-pack in a way that is compatible with
elastic/elasticsearchelastic/elasticsearch#15358.

Original commit: elastic/x-pack-elasticsearch@0d6ce5f22f
2015-12-11 11:14:10 +01:00
Ryan Ernst 1f931f705b Remove uses of NodeBuilder
This is the xplugins side of removing NodeBuilder in ES.

Original commit: elastic/x-pack-elasticsearch@ae82f14daf
2015-12-10 20:13:05 -08:00
Robert Muir bc6c4470f7 bump securemock to 1.2 for https://github.com/elastic/elasticsearch/pull/15378
Original commit: elastic/x-pack-elasticsearch@a069ed2b4d
2015-12-10 15:26:32 -05:00
Robert Muir 5c480e118c fix x-pack compile/tests to work with https://github.com/elastic/elasticsearch/pull/15328
Squashed commit of the following:

commit 54de841112778b01e817e465d2f59840970bb4f3
Author: Robert Muir <rmuir@apache.org>
Date:   Thu Dec 10 08:47:12 2015 -0500

    see exactly how far MessyTestPlugin can go (unit tests depend on both groovy and mustache!)

commit 743b5a4e0cc9a05e307339dfcb4569feed31f337
Author: Robert Muir <rmuir@apache.org>
Date:   Thu Dec 10 08:35:03 2015 -0500

    fix x-pack compile/tests to work with https://github.com/elastic/elasticsearch/pull/15328

Original commit: elastic/x-pack-elasticsearch@4307bb163b
2015-12-10 08:47:55 -05:00
Alexander Reelsen 45f2223d57 Watcher: Fix compilation issue against core (PR elastic/elasticsearch#15337)
Original commit: elastic/x-pack-elasticsearch@a1215ea494
2015-12-10 10:42:08 +01:00
Areek Zillur f0cc7fefa8 add primary transport handlers corresponding to elasticsearchelastic/elasticsearch#14852
Original commit: elastic/x-pack-elasticsearch@25d52cccbf
2015-12-10 01:42:56 -05:00
Tanguy Leroux fdcf1f44e4 Marvel: Update template management in Local/Http Exporters
This commit update the Local & Http exporters so that they have the same behavior. Exporters now try to update the mappings of the current marvel indices if they exist (only new document types will be added)

It also adds dedicated tests to verify that the Marvel template is correctly updated depending of the current template version.

Original commit: elastic/x-pack-elasticsearch@ac650f5aba
2015-12-09 16:10:25 +01:00
Tanguy Leroux d377168a7f Marvel: Be more precise about the required stats
Original commit: elastic/x-pack-elasticsearch@2a0385ea85
2015-12-09 15:43:08 +01:00
jaymode fc321a02a1 fix logging audit trail to not cause guice issues
When the logging audit trail is configured to add the node hostname or ip address
as a prefix, the logging audit trail can invoke guice dependency injection issues since
the transport that is injected is a proxy. This change makes the logging audit trail a
lifecycle component and waits for the transport to be started before initializing the
prefix.

Closes elastic/elasticsearch#1104

Original commit: elastic/x-pack-elasticsearch@3b19283969
2015-12-09 07:35:53 -05:00
Alexander Reelsen 62cd783942 Watcher: Fix sending of emails
In order to be able to send emails, the thread context classs loader
must be set to the watcher plugin class loader (and reset afterwards),
otherwise some javax.activation classes needed to create mime attachments
cannot be found.

In addition the activation jar dependency has been removed.

Closes elastic/elasticsearch#1066
Closes elastic/elasticsearch#708

Original commit: elastic/x-pack-elasticsearch@10042375ec
2015-12-09 10:04:15 +01:00
uboness 1c4c25fbf6 Initial cleanup of shield integration in watcher and marvel
- Removed Marvel/WatcherUserHolder in favour of the new `InternalMarvelUser`/`InternalWatcherUser`

Original commit: elastic/x-pack-elasticsearch@8181630144
2015-12-07 14:08:43 +01:00
Ryan Ernst ad36c3f0dd Merge pull request elastic/elasticsearch#1086 from rjernst/jigsaw
Build: Changes to tests for modules in elasticsearch

Original commit: elastic/x-pack-elasticsearch@95e0c53939
2015-12-04 11:53:05 -08:00
Ryan Ernst 2521e567f1 Merge branch 'master' into jigsaw
Original commit: elastic/x-pack-elasticsearch@c7534cfcf0
2015-12-04 11:39:33 -08:00
jaymode 8e5b5688f5 test: change watcher rest tests to wait for yellow
Since we combined all of the plugins marvel will also be enabled and will cause
the cluster to never get to a green state since we only have a single node.

Original commit: elastic/x-pack-elasticsearch@60fbfa97f1
2015-12-04 14:18:07 -05:00
jaymode a039acf578 more fixes for the combined plugin
* move static initialization hack for UnboundID Debug to XPackPlugin
* cleanup bundlePlugin calls in build file
* properly disable watcher and marvel for shield core tests

Original commit: elastic/x-pack-elasticsearch@2b89cf2225
2015-12-03 14:56:12 -05:00
jaymode aca0c96d6a remove leftover use of onIndexService and disable license check
Original commit: elastic/x-pack-elasticsearch@1cdf5c9f95
2015-12-03 11:16:41 -05:00
jaymode 9b2dd0c11d fixes after rebase
Original commit: elastic/x-pack-elasticsearch@6896b88829
2015-12-03 16:24:40 +01:00
jaymode 628febf3f7 fix integration tests after reorganization
This commit fixes the integration tests and qa test after the reorganization to be
packaged as a single plugin.

Original commit: elastic/x-pack-elasticsearch@d6f488627f
2015-12-03 16:24:40 +01:00
jaymode e1c1552eb2 fix tests so gradle test passes
Original commit: elastic/x-pack-elasticsearch@30683bd771
2015-12-03 16:24:40 +01:00
uboness 13a8c98cb2 [WIP] unified x-pack repo restructuring
- added the license-plugin dir as a src dir

- Made XPackPlugin customizable for tests. Now tests that need to plug in different behaviours (e.g. a custom license plugin) can do that by simply resetting the relevant delegee plugins (i.e. shield, marvel, license, watcher) in the ctor of a new XPackPlugin.

Original commit: elastic/x-pack-elasticsearch@ab83104955
2015-12-03 16:24:40 +01:00
Ryan Ernst 7ef87632ab Moved shield, watcher, marvel and license plugin into common x-pack
project, and combined their gradle builds. Everything builds, but many
many tests fail.

Original commit: elastic/x-pack-elasticsearch@d18d4614aa
2015-12-03 16:24:40 +01:00