Class EntitlementBootstrap
java.lang.Object
org.elasticsearch.entitlement.bootstrap.EntitlementBootstrap
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionstatic voidbootstrap(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, Collection<Path>> pluginSourcePaths, Path logsDir, Path tempDir, Path pidFile, Set<Package> suppressFailureLogPackages) Main entry point that activates entitlement checking.
-
Constructor Details
-
EntitlementBootstrap
public EntitlementBootstrap()
-
-
Method Details
-
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, Collection<Path>> pluginSourcePaths, Path logsDir, Path tempDir, @Nullable Path pidFile, Set<Package> suppressFailureLogPackages) Main entry point that activates entitlement checking. Once this method returns, calls to methods protected by entitlements from classes without a valid policy will throwNotEntitledException.- Parameters:
serverPolicyPatch- additional entitlements to patch the embedded server layer policypluginPolicies- maps each plugin name to the correspondingPolicyscopeResolver- 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 ElasticsearchsharedDataDir- shared data directory for Elasticsearch (deprecated)sharedRepoDirs- shared repository directories for ElasticsearchconfigDir- the config directory for ElasticsearchlibDir- the lib directory for ElasticsearchmodulesDir- the directory where Elasticsearch modules arepluginsDir- the directory where plugins are installed for ElasticsearchpluginSourcePaths- maps each plugin name to the location of that plugin's codelogsDir- the log directory for ElasticsearchtempDir- the temp directory for ElasticsearchpidFile- path to a pid file for Elasticsearch, ornullif one was not specifiedsuppressFailureLogPackages- packages for which we do not need or want to log Entitlements failures
-