Class ResourceOwnerService


  • public class ResourceOwnerService
    extends Object
    • Constructor Summary

      Constructors 
      Constructor Description
      ResourceOwnerService​(org.elasticsearch.client.Client client, org.elasticsearch.cluster.service.ClusterService clusterService, org.elasticsearch.threadpool.ThreadPool threadPool, SearchGuardPlugin.ProtectedIndices protectedIndices, org.elasticsearch.common.settings.Settings settings)  
    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      <R extends org.elasticsearch.action.ActionResponse>
      org.elasticsearch.action.ActionListener<R>
      applyCreatePostAction​(ActionConfig actionConfig, User currentUser, org.elasticsearch.action.ActionListener<R> actionListener)  
      <Request extends org.elasticsearch.action.ActionRequest,​R extends org.elasticsearch.action.ActionResponse>
      org.elasticsearch.action.ActionListener<R>
      applyDeletePostAction​(ActionConfig actionConfig, ActionConfig.Resource resource, User currentUser, org.elasticsearch.tasks.Task task, String action, Request actionRequest, org.elasticsearch.action.ActionListener<R> actionListener)  
      <Request extends org.elasticsearch.action.ActionRequest,​Response extends org.elasticsearch.action.ActionResponse>
      org.elasticsearch.action.support.ActionFilterChain<Request,​Response>
      applyOwnerCheckPreAction​(ActionConfig actionConfig, User currentUser, org.elasticsearch.tasks.Task task, String action, Request actionRequest, org.elasticsearch.action.ActionListener<Response> listener, org.elasticsearch.action.support.ActionFilterChain<Request,​Response> chain)  
      void checkOwner​(String resourceType, Object id, User currentUser, org.elasticsearch.action.ActionListener<com.floragunn.searchguard.privileges.extended_action_handling.ResourceOwnerService.CheckOwnerResponse> actionListener)  
      void deleteOwner​(String resourceType, Object id)  
      void shutdown()  
      void storeOwner​(String resourceType, Object id, User owner, long expires, org.elasticsearch.action.ActionListener<org.elasticsearch.action.index.IndexResponse> actionListener)  
    • Field Detail

      • MAX_CHECK_RETRIES

        public static final org.elasticsearch.common.settings.Setting<Integer> MAX_CHECK_RETRIES
      • CHECK_RETRY_DELAY

        public static final org.elasticsearch.common.settings.Setting<Integer> CHECK_RETRY_DELAY
      • CLEANUP_INTERVAL

        public static final org.elasticsearch.common.settings.Setting<org.elasticsearch.common.unit.TimeValue> CLEANUP_INTERVAL
      • DEFAULT_RESOURCE_LIFETIME

        public static final org.elasticsearch.common.settings.Setting<org.elasticsearch.common.unit.TimeValue> DEFAULT_RESOURCE_LIFETIME
      • REFRESH_POLICY

        public static final org.elasticsearch.common.settings.Setting<String> REFRESH_POLICY
      • SUPPORTED_SETTINGS

        public static final List<org.elasticsearch.common.settings.Setting<?>> SUPPORTED_SETTINGS
    • Constructor Detail

      • ResourceOwnerService

        public ResourceOwnerService​(org.elasticsearch.client.Client client,
                                    org.elasticsearch.cluster.service.ClusterService clusterService,
                                    org.elasticsearch.threadpool.ThreadPool threadPool,
                                    SearchGuardPlugin.ProtectedIndices protectedIndices,
                                    org.elasticsearch.common.settings.Settings settings)
    • Method Detail

      • storeOwner

        public void storeOwner​(String resourceType,
                               Object id,
                               User owner,
                               long expires,
                               org.elasticsearch.action.ActionListener<org.elasticsearch.action.index.IndexResponse> actionListener)
      • deleteOwner

        public void deleteOwner​(String resourceType,
                                Object id)
      • checkOwner

        public void checkOwner​(String resourceType,
                               Object id,
                               User currentUser,
                               org.elasticsearch.action.ActionListener<com.floragunn.searchguard.privileges.extended_action_handling.ResourceOwnerService.CheckOwnerResponse> actionListener)
      • applyOwnerCheckPreAction

        public <Request extends org.elasticsearch.action.ActionRequest,​Response extends org.elasticsearch.action.ActionResponse> org.elasticsearch.action.support.ActionFilterChain<Request,​Response> applyOwnerCheckPreAction​(ActionConfig actionConfig,
                                                                                                                                                                                                                                           User currentUser,
                                                                                                                                                                                                                                           org.elasticsearch.tasks.Task task,
                                                                                                                                                                                                                                           String action,
                                                                                                                                                                                                                                           Request actionRequest,
                                                                                                                                                                                                                                           org.elasticsearch.action.ActionListener<Response> listener,
                                                                                                                                                                                                                                           org.elasticsearch.action.support.ActionFilterChain<Request,​Response> chain)
      • applyCreatePostAction

        public <R extends org.elasticsearch.action.ActionResponse> org.elasticsearch.action.ActionListener<R> applyCreatePostAction​(ActionConfig actionConfig,
                                                                                                                                    User currentUser,
                                                                                                                                    org.elasticsearch.action.ActionListener<R> actionListener)
      • applyDeletePostAction

        public <Request extends org.elasticsearch.action.ActionRequest,​R extends org.elasticsearch.action.ActionResponse> org.elasticsearch.action.ActionListener<R> applyDeletePostAction​(ActionConfig actionConfig,
                                                                                                                                                                                                 ActionConfig.Resource resource,
                                                                                                                                                                                                 User currentUser,
                                                                                                                                                                                                 org.elasticsearch.tasks.Task task,
                                                                                                                                                                                                 String action,
                                                                                                                                                                                                 Request actionRequest,
                                                                                                                                                                                                 org.elasticsearch.action.ActionListener<R> actionListener)
      • shutdown

        public void shutdown()