master not discovered should use 503 response code
This commit is contained in:
parent
a18021c778
commit
2b125bd6b4
|
@ -20,6 +20,7 @@
|
|||
package org.elasticsearch.discovery;
|
||||
|
||||
import org.elasticsearch.ElasticSearchException;
|
||||
import org.elasticsearch.rest.RestStatus;
|
||||
|
||||
/**
|
||||
*
|
||||
|
@ -29,4 +30,9 @@ public class MasterNotDiscoveredException extends ElasticSearchException {
|
|||
public MasterNotDiscoveredException() {
|
||||
super("");
|
||||
}
|
||||
|
||||
@Override
|
||||
public RestStatus status() {
|
||||
return RestStatus.SERVICE_UNAVAILABLE;
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue