summaryrefslogtreecommitdiff
path: root/core/src/test/java/org/elasticsearch/ElasticsearchExceptionTests.java
diff options
context:
space:
mode:
authorSimon Willnauer <simonw@apache.org>2015-07-02 22:40:54 +0200
committerSimon Willnauer <simonw@apache.org>2015-07-03 08:58:44 +0200
commit20d0b4f446a17e3ccbe417e2b455942168fa7287 (patch)
tree6033e1a11b1f90764105d9321f8efaf46ee7bda1 /core/src/test/java/org/elasticsearch/ElasticsearchExceptionTests.java
parent3084bed194e8c54144037d0fc3286c5a56fe8920 (diff)
Promote headers to first class citizens on exceptions
This commit merges the pre-existing special exception that allowed to associate headers with exceptions and the elasticsaerch base class `ElasticsearchException` This allows for more generic use of exceptions where plugins can associate meta-data with any elasticsearch base exception to control behavior etc. This also addds a generic SecurityException to allow plugins to pass on information based on the RestStatus.
Diffstat (limited to 'core/src/test/java/org/elasticsearch/ElasticsearchExceptionTests.java')
-rw-r--r--core/src/test/java/org/elasticsearch/ElasticsearchExceptionTests.java2
1 files changed, 1 insertions, 1 deletions
diff --git a/core/src/test/java/org/elasticsearch/ElasticsearchExceptionTests.java b/core/src/test/java/org/elasticsearch/ElasticsearchExceptionTests.java
index 699c3ca616..34bc1178b0 100644
--- a/core/src/test/java/org/elasticsearch/ElasticsearchExceptionTests.java
+++ b/core/src/test/java/org/elasticsearch/ElasticsearchExceptionTests.java
@@ -265,7 +265,7 @@ public class ElasticsearchExceptionTests extends ElasticsearchTestCase {
new IllegalArgumentException("alalaal"),
new NullPointerException("boom"),
new EOFException("dadada"),
- new SecurityException("nono!"),
+ new ElasticsearchSecurityException("nono!"),
new NumberFormatException("not a number"),
new CorruptIndexException("baaaam", "this is my resource"),
new IndexFormatTooNewException("tooo new", 1, 1, 1),