Class EntitlementBootstrap

java.lang.Object
org.elasticsearch.entitlement.bootstrap.EntitlementBootstrap

public class EntitlementBootstrap extends Object
  • Constructor Details

    • EntitlementBootstrap

      public EntitlementBootstrap()
  • Method Details

    • bootstrapArgs

      public static EntitlementBootstrap.BootstrapArgs bootstrapArgs()
    • bootstrap

      public static void bootstrap(Policy serverPolicyPatch, Map<String,Policy> pluginPolicies, Function<Class<?>,PolicyManager.PolicyScope> scopeResolver, Function<String,Stream<String>> settingResolver, Path[] dataDirs, Path sharedDataDir, Path[] sharedRepoDirs, Path configDir, Path libDir, Path modulesDir, Path pluginsDir, Map<String,Path> sourcePaths, Path logsDir, Path tempDir, Path pidFile, Set<Package> suppressFailureLogPackages)
      Activates entitlement checking. Once this method returns, calls to methods protected by Entitlements from classes without a valid policy will throw NotEntitledException.
      Parameters:
      serverPolicyPatch - a policy with additional entitlements to patch the embedded server layer policy
      pluginPolicies - a map holding policies for plugins (and modules), by plugin (or module) name.
      scopeResolver - a functor to map a Java Class to the component and module it belongs to.
      settingResolver - a functor to resolve a setting name pattern for one or more Elasticsearch settings.
      dataDirs - data directories for Elasticsearch
      sharedDataDir - shared data directory for Elasticsearch (deprecated)
      sharedRepoDirs - shared repository directories for Elasticsearch
      configDir - the config directory for Elasticsearch
      libDir - the lib directory for Elasticsearch
      modulesDir - the directory where Elasticsearch modules are
      pluginsDir - the directory where plugins are installed for Elasticsearch
      sourcePaths - a map holding the path to each plugin or module jars, by plugin (or module) name.
      logsDir - the log directory for Elasticsearch
      tempDir - the temp directory for Elasticsearch
      pidFile - path to a pid file for Elasticsearch, or null if one was not specified
      suppressFailureLogPackages - packages for which we do not need or want to log Entitlements failures
    • findAgentJar

      public static String findAgentJar()