|
10 | 10 |
|
11 | 11 | import org.opensearch.action.ActionRequest; |
12 | 12 | import org.opensearch.action.support.ActionFilter; |
13 | | -import org.opensearch.autotagging.FeatureType; |
14 | 13 | import org.opensearch.cluster.metadata.IndexNameExpressionResolver; |
15 | 14 | import org.opensearch.cluster.node.DiscoveryNodes; |
16 | 15 | import org.opensearch.cluster.service.ClusterService; |
17 | | -import org.opensearch.core.common.io.stream.NamedWriteableRegistry; |
18 | | -import org.opensearch.core.xcontent.NamedXContentRegistry; |
19 | | -import org.opensearch.env.Environment; |
20 | | -import org.opensearch.env.NodeEnvironment; |
21 | 16 | import org.opensearch.common.inject.Module; |
22 | 17 | import org.opensearch.common.settings.ClusterSettings; |
23 | 18 | import org.opensearch.common.settings.IndexScopedSettings; |
24 | 19 | import org.opensearch.common.settings.Setting; |
25 | 20 | import org.opensearch.common.settings.Settings; |
26 | 21 | import org.opensearch.common.settings.SettingsFilter; |
27 | 22 | import org.opensearch.core.action.ActionResponse; |
| 23 | +import org.opensearch.core.common.io.stream.NamedWriteableRegistry; |
| 24 | +import org.opensearch.core.xcontent.NamedXContentRegistry; |
| 25 | +import org.opensearch.env.Environment; |
| 26 | +import org.opensearch.env.NodeEnvironment; |
28 | 27 | import org.opensearch.plugin.wlm.action.CreateWorkloadGroupAction; |
29 | 28 | import org.opensearch.plugin.wlm.action.DeleteWorkloadGroupAction; |
30 | 29 | import org.opensearch.plugin.wlm.action.GetWorkloadGroupAction; |
|
38 | 37 | import org.opensearch.plugin.wlm.rest.RestGetWorkloadGroupAction; |
39 | 38 | import org.opensearch.plugin.wlm.rest.RestUpdateWorkloadGroupAction; |
40 | 39 | import org.opensearch.plugin.wlm.service.WorkloadGroupPersistenceService; |
41 | | - |
42 | 40 | import org.opensearch.plugins.ActionPlugin; |
43 | 41 | import org.opensearch.plugins.Plugin; |
44 | 42 | import org.opensearch.repositories.RepositoriesService; |
|
61 | 59 | public class WorkloadManagementPlugin extends Plugin implements ActionPlugin { |
62 | 60 |
|
63 | 61 | private AutoTaggingActionFilter autoTaggingActionFilter; |
| 62 | + |
64 | 63 | /** |
65 | 64 | * Default constructor |
66 | 65 | */ |
67 | 66 | public WorkloadManagementPlugin() {} |
68 | 67 |
|
69 | 68 | @Override |
70 | | - public Collection<Object> createComponents(Client client, ClusterService clusterService, ThreadPool threadPool, ResourceWatcherService resourceWatcherService, ScriptService scriptService, NamedXContentRegistry xContentRegistry, Environment environment, NodeEnvironment nodeEnvironment, NamedWriteableRegistry namedWriteableRegistry, IndexNameExpressionResolver indexNameExpressionResolver, Supplier<RepositoriesService> repositoriesServiceSupplier) { |
71 | | - InMemoryRuleProcessingService ruleProcessingService = new InMemoryRuleProcessingService(); |
| 69 | + public Collection<Object> createComponents( |
| 70 | + Client client, |
| 71 | + ClusterService clusterService, |
| 72 | + ThreadPool threadPool, |
| 73 | + ResourceWatcherService resourceWatcherService, |
| 74 | + ScriptService scriptService, |
| 75 | + NamedXContentRegistry xContentRegistry, |
| 76 | + Environment environment, |
| 77 | + NodeEnvironment nodeEnvironment, |
| 78 | + NamedWriteableRegistry namedWriteableRegistry, |
| 79 | + IndexNameExpressionResolver indexNameExpressionResolver, |
| 80 | + Supplier<RepositoriesService> repositoriesServiceSupplier |
| 81 | + ) { |
| 82 | + InMemoryRuleProcessingService ruleProcessingService = new InMemoryRuleProcessingService(null, null); // TODO: change this post |
| 83 | + // Ruirui's get API PR |
72 | 84 | autoTaggingActionFilter = new AutoTaggingActionFilter(ruleProcessingService, threadPool); |
73 | 85 | return Collections.emptyList(); |
74 | 86 | } |
|
0 commit comments