Commit Graph

785 Commits

Author SHA1 Message Date
Areek Zillur 57544b8688 incorporate feedback
Original commit: elastic/x-pack-elasticsearch@f10ea80143
2016-07-07 16:22:42 -04:00
Areek Zillur 7e3fac9b35 add comment regarding scheduling license with future issue date
Original commit: elastic/x-pack-elasticsearch@7d4094da1e
2016-07-06 17:29:10 -04:00
Areek Zillur c67beb1359 add expiry callback documentation
Original commit: elastic/x-pack-elasticsearch@03326406d1
2016-07-06 17:19:46 -04:00
Areek Zillur 827d68c7b0 initialize scheduler in constructor
Original commit: elastic/x-pack-elasticsearch@283ddf3aa3
2016-07-06 17:11:08 -04:00
Areek Zillur 3150bfa876 Simplify expiry callback code
Original commit: elastic/x-pack-elasticsearch@56e8e19048
2016-07-06 17:09:20 -04:00
Areek Zillur b1886ce978 address feedback
Original commit: elastic/x-pack-elasticsearch@f6b1d58c5b
2016-07-05 16:07:50 -04:00
Areek Zillur ce10289540 update to master
Original commit: elastic/x-pack-elasticsearch@9bc098f879
2016-07-05 11:29:30 -04:00
Areek Zillur d88e1ddb27 Merge branch 'master' into simplify_license_service_scheduling
Original commit: elastic/x-pack-elasticsearch@faa20465e4
2016-07-05 10:51:40 -04:00
Areek Zillur 3c5fca12ba cleanup unit tests
Original commit: elastic/x-pack-elasticsearch@f759f45b7f
2016-07-05 10:15:01 -04:00
Adrien Grand 5533470959 master is now 5.0.0-alpha5
Original commit: elastic/x-pack-elasticsearch@ce2a255cde
2016-07-05 15:27:27 +02:00
jaymode e861608c59 security: extend usage stats
This commit extends the usage stats to include the usage of ssl, ip filtering, auditing,
system key, field and document level security, and the number of roles.

See elastic/elasticsearch#2210

Original commit: elastic/x-pack-elasticsearch@e44c5748ba
2016-07-05 08:57:25 -04:00
Alexander Reelsen e8c1e7f9d8 Watcher: Dont hide exceptions during watch execution
When a painless exception is raised in the script condition, it was not bubbled up due to
catching exceptions on during execution. This removes the different catching of exceptions
and allows the watch record construct to contain an exception that is also serialized correctly
so that it can be stored in the watch history but also returned in the execute watch API.

This also updates the watch history template, so that exceptions are not indexed, but logged.

Relates elastic/elasticsearch#2587

Original commit: elastic/x-pack-elasticsearch@4dffb672bf
2016-07-05 09:33:44 +02:00
Jason Tedor f1670a3845 Rename UserError
The top-level class Throwable represents all errors and exceptions in
Java. This hierarchy is divided into Error and Exception, the former
being serious problems that applications should not try to catch and the
latter representing exceptional conditions that an application might
want to catch and handle. This commit renames
org.elasticsearch.cli.UserError to org.elasticsearch.UserException to
make its name consistent with where it falls in this hierarchy.

Relates elastic/elasticsearch#2701

Original commit: elastic/x-pack-elasticsearch@589e159ec0
2016-07-04 19:22:46 -04:00
Boaz Leskes 8cc49b5b30 Remove DummyTransportAddress (elastic/elasticsearch#2048)
this is a partner PR to elastic/elasticsearchelastic/elasticsearch#17811

Original commit: elastic/x-pack-elasticsearch@1db11e4340
2016-07-04 21:09:53 +02:00
Tanguy Leroux bd0cf521aa Enable Checkstyle RedundantModifier
Original commit: elastic/x-pack-elasticsearch@7455e88dce
2016-07-04 15:17:50 +02:00
Jason Tedor 1cd53c41e2 Do not catch throwable
Today throughout the codebase, catch throwable is used with reckless
abandon. This is dangerous because the throwable could be a fatal
virtual machine error resulting from an internal error in the JVM, or an
out of memory error or a stack overflow error that leaves the virtual
machine in an unstable and unpredictable state. This commit removes
catch throwable from the codebase and removes the temptation to use it
by modifying listener APIs to receive instances of Exception instead of
the top-level Throwable.

Relates elastic/elasticsearch#2694

Original commit: elastic/x-pack-elasticsearch@7ecdd7d978
2016-07-04 08:41:08 -04:00
Colin Goodheart-Smithe b008a4de74 fixes package declarations in security tests
Original commit: elastic/x-pack-elasticsearch@09ed28aee3
2016-07-04 10:28:13 +01:00
Nik Everett 98f34c1120 Handle core removing addField
It is addStoredField now.

Original commit: elastic/x-pack-elasticsearch@c42c18894f
2016-07-04 09:36:36 +02:00
Ryan Ernst d6ff6211eb Merge pull request elastic/elasticsearch#2685 from rjernst/uninject_htmlsanitizer
Uninject HtmlSanitizer

Original commit: elastic/x-pack-elasticsearch@4a6c8cdee6
2016-07-01 16:26:57 -07:00
Ryan Ernst 9f52066bdb Removed generics from LifecycleComponent
This is the xplugins side of elastic/elasticsearch#19225

Original commit: elastic/x-pack-elasticsearch@845a945552
2016-07-01 16:23:13 -07:00
Ryan Ernst 09c8418a50 Fix xpack tests with node info ctor changes
Original commit: elastic/x-pack-elasticsearch@c741a2d231
2016-07-01 14:15:19 -07:00
Ryan Ernst 36a8c24b6b Uninject HtmlSanitizer
This is just a utility used by the email action and does not need to be
injected.

Original commit: elastic/x-pack-elasticsearch@4555db634c
2016-07-01 13:45:16 -07:00
Tanguy Leroux 561fc86585 Fix checkstyle violations
Original commit: elastic/x-pack-elasticsearch@187f1cbd35
2016-07-01 17:13:08 +02:00
Tanguy Leroux 17684f1e76 Fix order of modifiers
Original commit: elastic/x-pack-elasticsearch@1f970e78ba
2016-07-01 16:54:53 +02:00
Simon Willnauer 158a6b5588 Cleanup BytesRefrence interface (elastic/elasticsearch#2670)
This is a followup of elastic/elasticsearchelastic/elasticsearch#19196

Original commit: elastic/x-pack-elasticsearch@1d0398e89a
2016-07-01 16:09:53 +02:00
Alexander Reelsen 6527683e48 Licensing: Return HTTP 403 forbidden instead of 401 in exception (elastic/elasticsearch#2673)
When a license exception is raised, we returned 401 as HTTP error code
in there. However this seems to have triggered some browsers to actually
ask for login credentials, which wont have any impact here.

Closes elastic/elasticsearch#1863

Original commit: elastic/x-pack-elasticsearch@cc63abdac8
2016-07-01 14:32:42 +02:00
javanna 4eb21f4c01 [TEST] eagerly parse response body at ObjectPath initialization and read content type from response headers
We are going to parse the body anyways whenever it's in json format as it is going to be stashed. It is not useful to lazily parse it anymore. Also this allows us to not rely on automatic detection of the xcontent type based on the content of the response, but rather read the content type from the response headers.

Original commit: elastic/x-pack-elasticsearch@11be4684ae
2016-07-01 09:49:47 +02:00
javanna 579baa2bca [TEST] make JsonPath independent of data format, rename to ObjectPath
The internal representation of the object that JsonPath gives access to is a map. That is independent of the initial input format, which is json but could also be yaml etc.
This commit renames JsonPath to ObjectPath and adds a static method to create an ObjectPath from an XContent

Original commit: elastic/x-pack-elasticsearch@bc84c68161
2016-07-01 09:49:47 +02:00
Ryan Ernst 8d6d96d2f8 Merge pull request elastic/elasticsearch#2658 from rjernst/rest_handler_client
Change rest handler interface to use NodeClient

Original commit: elastic/x-pack-elasticsearch@82da58cc0c
2016-06-30 11:00:14 -07:00
Jay Modi 060120b53d Merge pull request elastic/elasticsearch#2660 from jaymode/rest_test_teardown
test: move teardown logic into the rest tests

Original commit: elastic/x-pack-elasticsearch@81a273a4c7
2016-06-30 12:03:07 -04:00
Boaz Leskes 7c1bc0c8de adapt randomFrom to not use null as a first param, in preparation for https://github.com/elastic/elasticsearch/pull/19172
Original commit: elastic/x-pack-elasticsearch@50296d6cfc
2016-06-30 17:55:17 +02:00
Lee Hinman 8c54887ab8 Merge remote-tracking branch 'dakrone/migrate-tool-master'
Original commit: elastic/x-pack-elasticsearch@ce82529d4b
2016-06-30 09:53:52 -06:00
jaymode 4999f3a38c test: remove unnecessary teardown section in license test
Original commit: elastic/x-pack-elasticsearch@b457404452
2016-06-30 11:39:37 -04:00
Lee Hinman 238eed2075 Throw correct exception type, reduce boilerplate in boolean statement
Original commit: elastic/x-pack-elasticsearch@1e33c4d8f2
2016-06-30 09:34:08 -06:00
Ryan Ernst 82e4330e87 Merge branch 'master' into rest_handler_client
Original commit: elastic/x-pack-elasticsearch@7fcc120767
2016-06-30 08:16:50 -07:00
jaymode d1b945d1f2 security: remove user/role deletion logic in XPackRestTestCase
Original commit: elastic/x-pack-elasticsearch@d6064e520a
2016-06-30 11:15:05 -04:00
Karel Minarik 67706a9a19 [SECURITY] Changed the setup/teardown YAML structure in the integration test for roles
Related: 176fd6a

Original commit: elastic/x-pack-elasticsearch@90e210dbc2
2016-06-30 11:15:05 -04:00
Karel Minarik 6d535043f8 [SECURITY] Added a `teardown` section to the integration test for roles
Currently, the REST tests for security (and possibly others) don't clean up the environment
after they have run, eg. they don't delete the users and roles they create. This leads to
test failures, because in a subsequent run, a user or role already exists, so eg. a test
like `match: { role: { created: true } }` fails.

This patch adds a `teardown` section to the test, with `do` actions which are to be
executed _after_ the test runs.

This patch assumes that REST tests runners for all languages support the `teardown` directive
in a xUnimt nomenclature -- similarly to the `setup` directive, which they already support.

Original commit: elastic/x-pack-elasticsearch@70d0ff4ee9
2016-06-30 11:15:05 -04:00
Simon Willnauer 30dd9ab09c Follup PR fore elastic/elasticsearchelastic/elasticsearch#19096 (elastic/elasticsearch#2656)
This PR is a cleanup / follup for elastic/elasticsearchelastic/elasticsearch#19096

Original commit: elastic/x-pack-elasticsearch@052b9a85a7
2016-06-30 13:42:09 +02:00
Martijn van Groningen 7c988b78e1 test: test that DLS is applied before FLS
Original commit: elastic/x-pack-elasticsearch@c7c12cc8d6
2016-06-30 12:32:37 +02:00
Ryan Ernst b513f2bb6b Merge branch 'master' into script_service_deps
Original commit: elastic/x-pack-elasticsearch@d4269e190d
2016-06-29 23:35:29 -07:00
Ryan Ernst 0fcb52a794 Merge branch 'master' into rest_handler_client
Original commit: elastic/x-pack-elasticsearch@429edeea84
2016-06-29 17:03:27 -07:00
Ryan Ernst 7822f28d7b Simplify rest handler constructors
This is the xplugins side of moving the client dependency for rest
handlers to the handleRequest method

Original commit: elastic/x-pack-elasticsearch@ce66e35e7b
2016-06-29 16:30:55 -07:00
Nik Everett 672d91f2a4 Move rest handler registration to ActionPlugin
Original commit: elastic/x-pack-elasticsearch@b3bc7d4a9f
2016-06-29 18:32:58 -04:00
Lee Hinman 92637d2eec Use client http ssl settings if applicable
Original commit: elastic/x-pack-elasticsearch@c74116d40a
2016-06-29 15:00:39 -06:00
Lee Hinman 4d7d9ad5b9 get the SSL status from the node settings
Original commit: elastic/x-pack-elasticsearch@6fff3e6ce1
2016-06-29 10:07:23 -06:00
Lee Hinman 27fb1e036e switch to RoleDescriptor jsonification, rename esusersSettings -> fileRealmSettings
Original commit: elastic/x-pack-elasticsearch@a7181a329a
2016-06-29 09:56:52 -06:00
jaymode b06249279e security: REST spec cleanup and authenticate tests create user
This change cleans up the rest API specs and changes the documentation field to a link. Additionally,
the integration tests for xpack now use the elastic user rather than a dummy user from a file realm.

Closes elastic/elasticsearch#2458
Closes elastic/elasticsearch#2437

Original commit: elastic/x-pack-elasticsearch@8059a0d856
2016-06-29 11:42:44 -04:00
Lee Hinman b4c19734ac Fail hard if retrieving user/role fails or adding user/role fails
Original commit: elastic/x-pack-elasticsearch@d641dab31c
2016-06-29 09:37:59 -06:00
Lee Hinman 24d7472cea Fix compilation for missing client
Original commit: elastic/x-pack-elasticsearch@586c5d0716
2016-06-29 09:37:47 -06:00