Skip to content

Commit 546c317

Browse files
authored
[ML-Data Frame] Add data frame transform cluster privileges to HLRC (#43879)
Adds the monitor_data_frame_transforms and manage_data_frame_transforms cluster privileges to the high level rest client. The ALL_ARRAY variable is only used in randomized tests at the within the Elasticsearch code, so it's not a major problem that these cluster privileges weren't added from the start. But since ALL_ARRAY is public HLRC users may be using it to find out which cluster privileges exist, so it's best that it contains them all.
1 parent 5ecf669 commit 546c317

File tree

1 file changed

+5
-2
lines changed
  • client/rest-high-level/src/main/java/org/elasticsearch/client/security/user/privileges

1 file changed

+5
-2
lines changed

client/rest-high-level/src/main/java/org/elasticsearch/client/security/user/privileges/Role.java

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -299,10 +299,12 @@ public static class ClusterPrivilegeName {
299299
public static final String NONE = "none";
300300
public static final String ALL = "all";
301301
public static final String MONITOR = "monitor";
302+
public static final String MONITOR_DATA_FRAME_TRANSFORMS = "monitor_data_frame_transforms";
302303
public static final String MONITOR_ML = "monitor_ml";
303304
public static final String MONITOR_WATCHER = "monitor_watcher";
304305
public static final String MONITOR_ROLLUP = "monitor_rollup";
305306
public static final String MANAGE = "manage";
307+
public static final String MANAGE_DATA_FRAME_TRANSFORMS = "manage_data_frame_transforms";
306308
public static final String MANAGE_ML = "manage_ml";
307309
public static final String MANAGE_WATCHER = "manage_watcher";
308310
public static final String MANAGE_ROLLUP = "manage_rollup";
@@ -318,8 +320,9 @@ public static class ClusterPrivilegeName {
318320
public static final String READ_CCR = "read_ccr";
319321
public static final String MANAGE_ILM = "manage_ilm";
320322
public static final String READ_ILM = "read_ilm";
321-
public static final String[] ALL_ARRAY = new String[] { NONE, ALL, MONITOR, MONITOR_ML, MONITOR_WATCHER, MONITOR_ROLLUP, MANAGE,
322-
MANAGE_ML, MANAGE_WATCHER, MANAGE_ROLLUP, MANAGE_INDEX_TEMPLATES, MANAGE_INGEST_PIPELINES, TRANSPORT_CLIENT,
323+
public static final String[] ALL_ARRAY = new String[] { NONE, ALL, MONITOR, MONITOR_DATA_FRAME_TRANSFORMS, MONITOR_ML,
324+
MONITOR_WATCHER, MONITOR_ROLLUP, MANAGE, MANAGE_DATA_FRAME_TRANSFORMS,
325+
MANAGE_ML, MANAGE_WATCHER, MANAGE_ROLLUP, MANAGE_INDEX_TEMPLATES, MANAGE_INGEST_PIPELINES, TRANSPORT_CLIENT,
323326
MANAGE_SECURITY, MANAGE_SAML, MANAGE_OIDC, MANAGE_TOKEN, MANAGE_PIPELINE, MANAGE_CCR, READ_CCR, MANAGE_ILM, READ_ILM};
324327
}
325328

0 commit comments

Comments
 (0)