Skip to content

Commit 5ad700e

Browse files
authored
Merge branch 'main' into security-examples
2 parents a2f7fa3 + eac5ecf commit 5ad700e

File tree

111 files changed

+4499
-1017
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

111 files changed

+4499
-1017
lines changed

.github/workflows/check-backport-labels.yml

Lines changed: 7 additions & 22 deletions
Original file line numberDiff line numberDiff line change
@@ -48,8 +48,8 @@ jobs:
4848
4949
echo "::endgroup::"
5050
51+
has_backport_label=false
5152
has_skip_backport_label=false
52-
has_exact_backport_label=false
5353
declare -A pr_exact_majors=()
5454
declare -A pr_floating_majors=()
5555
@@ -66,12 +66,13 @@ jobs:
6666
continue
6767
fi
6868
69+
has_backport_label=true
70+
6971
if [[ "${pr_label}" =~ ${backport_regex} ]]; then
7072
major="${BASH_REMATCH[1]}"
7173
minor="${BASH_REMATCH[2]}"
7274
if [ "${minor}" != "x" ]; then
7375
pr_exact_majors["${major}"]=1
74-
has_exact_backport_label=true
7576
else
7677
pr_floating_majors["${major}"]=1
7778
fi
@@ -82,15 +83,15 @@ jobs:
8283
8384
echo "::endgroup::"
8485
85-
if [ "${has_skip_backport_label}" = true ] && [ "${has_exact_backport_label}" = true ]; then
86+
if [ "${has_skip_backport_label}" = true ] && [ "${has_backport_label}" = true ]; then
8687
echo "::error::The 'skip-backport' not be used in combination with another backport"\
8788
"label."
8889
exit 1
8990
fi
9091
91-
if [ "${has_skip_backport_label}" != true ] && [ "${has_exact_backport_label}" != true ]; then
92-
echo "::error::No exact backport label found. Please add at least one of the"\
93-
"'backport {major}.{minor}' labels or use 'skip-backport',"\
92+
if [ "${has_skip_backport_label}" != true ] && [ "${has_backport_label}" != true ]; then
93+
echo "::error::No backport label found. Please add at least one of the"\
94+
"'backport {major}.{minor|x}' labels or use 'skip-backport',"\
9495
"if this PR should not be backported."
9596
exit 1
9697
fi
@@ -115,19 +116,3 @@ jobs:
115116
if [ "${has_required_floating_labels}" != true ]; then
116117
exit 1
117118
fi
118-
119-
# Validate that an exact backport label exists for each floating backport label major
120-
# version.
121-
122-
has_required_exact_labels=true
123-
124-
for pr_floating_major in "${!pr_floating_majors[@]}"; do
125-
if [ -z "${pr_exact_majors[${pr_floating_major}]}" ]; then
126-
has_required_exact_labels=false
127-
echo "::error::Missing exact backport label for '${pr_floating_major}.x'"
128-
fi
129-
done
130-
131-
if [ "${has_required_exact_labels}" != true ]; then
132-
exit 1
133-
fi

compiler/src/model/utils.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -668,7 +668,7 @@ export function hoistRequestAnnotations (
668668
const privileges = [
669669
'all', 'cancel_task', 'create_snapshot', 'grant_api_key', 'manage', 'manage_api_key', 'manage_ccr',
670670
'manage_enrich', 'manage_ilm', 'manage_index_templates', 'manage_inference', 'manage_ingest_pipelines', 'manage_logstash_pipelines',
671-
'manage_ml', 'manage_oidc', 'manage_own_api_key', 'manage_pipeline', 'manage_rollup', 'manage_saml', 'manage_search_application', 'manage_search_query_rules',
671+
'manage_ml', 'manage_oidc', 'manage_own_api_key', 'manage_pipeline', 'manage_rollup', 'manage_saml', 'manage_search_application', 'manage_search_query_rules', 'manage_search_synonyms',
672672
'manage_security', 'manage_service_account', 'manage_slm', 'manage_token', 'manage_transform', 'manage_user_profile',
673673
'manage_watcher', 'monitor', 'monitor_ml', 'monitor_rollup', 'monitor_snapshot', 'monitor_text_structure',
674674
'monitor_transform', 'monitor_watcher', 'read_ccr', 'read_ilm', 'read_pipeline', 'read_security', 'read_slm', 'transport_client'

docs/overlays/elasticsearch-openapi-overlays.yaml

Lines changed: 21 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -546,3 +546,24 @@ actions:
546546
examples:
547547
delegatePkiResponseExample1:
548548
$ref: "../../specification/security/delegate_pki/examples/200_response/SecurityDelegatePkiResponseExample1.yaml"
549+
## Examples for watcher
550+
- target: "$.paths['/_watcher/settings']['put']"
551+
description: "Add request example for update watcher settings"
552+
update:
553+
requestBody:
554+
content:
555+
application/json:
556+
examples:
557+
updateWatcherSettingsRequestExample1:
558+
$ref: "../../specification/watcher/update_settings/examples/request/WatcherUpdateSettingsRequestExample1.yaml"
559+
- target: "$.paths['/_watcher/settings']['get']"
560+
description: "Add response example for get watcher settings"
561+
update:
562+
responses:
563+
200:
564+
content:
565+
application/json:
566+
examples:
567+
updateWatcherSettingsRequestExample1:
568+
$ref: "../../specification/watcher/get_settings/examples/200_response/WatcherGetSettingsResponseExample1.yaml"
569+

0 commit comments

Comments
 (0)