Class EnrollmentBaseRestHandler
java.lang.Object
org.elasticsearch.rest.BaseRestHandler
org.elasticsearch.xpack.security.rest.action.SecurityBaseRestHandler
org.elasticsearch.xpack.security.rest.action.enrollment.EnrollmentBaseRestHandler
- All Implemented Interfaces:
org.elasticsearch.rest.RestHandler
- Direct Known Subclasses:
RestKibanaEnrollAction,RestNodeEnrollmentAction
An abstract implementation of
SecurityBaseRestHandler that performs enrollment_enabled setting check-
Nested Class Summary
Nested classes/interfaces inherited from class org.elasticsearch.rest.BaseRestHandler
org.elasticsearch.rest.BaseRestHandler.RestChannelConsumer, org.elasticsearch.rest.BaseRestHandler.WrapperNested classes/interfaces inherited from interface org.elasticsearch.rest.RestHandler
org.elasticsearch.rest.RestHandler.Route -
Field Summary
Fields inherited from class org.elasticsearch.xpack.security.rest.action.SecurityBaseRestHandler
licenseState, settingsFields inherited from class org.elasticsearch.rest.BaseRestHandler
DEFAULT_INCLUDE_TYPE_NAME_POLICY, INCLUDE_TYPE_NAME_PARAMETER, MULTI_ALLOW_EXPLICIT_INDEX -
Constructor Summary
ConstructorsConstructorDescriptionEnrollmentBaseRestHandler(org.elasticsearch.common.settings.Settings settings, org.elasticsearch.license.XPackLicenseState licenseState) -
Method Summary
Modifier and TypeMethodDescriptionprotected ExceptioncheckFeatureAvailable(org.elasticsearch.rest.RestRequest request) Check whether the given request is allowed within the current license state and setup, and return the name of any unlicensed feature.Methods inherited from class org.elasticsearch.xpack.security.rest.action.SecurityBaseRestHandler
innerPrepareRequest, prepareRequestMethods inherited from class org.elasticsearch.rest.BaseRestHandler
getName, getUsageCount, handleRequest, mediaTypesValid, responseParams, responseParams, routes, unrecognizedMethods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface org.elasticsearch.rest.RestHandler
allowsUnsafeBuffers, allowSystemIndexAccessByDefault, canTripCircuitBreaker, supportsContentStream
-
Constructor Details
-
EnrollmentBaseRestHandler
public EnrollmentBaseRestHandler(org.elasticsearch.common.settings.Settings settings, org.elasticsearch.license.XPackLicenseState licenseState)
-
-
Method Details
-
checkFeatureAvailable
Description copied from class:SecurityBaseRestHandlerCheck whether the given request is allowed within the current license state and setup, and return the name of any unlicensed feature. By default this returns an exception if security is not enabled. Sub-classes can override this method if they have additional requirements.- Overrides:
checkFeatureAvailablein classSecurityBaseRestHandler- Returns:
nullif all required features are available, otherwise an exception to be sent to the requestor
-