Skip to content

Commit

Permalink
feat(kuma-cp): implement meshtimeout policy api + validation (#5294)
Browse files Browse the repository at this point in the history
* feat(kuma-cp): Implement MeshTimeout policy api

Fixes: #5267
Signed-off-by: Marcin Skalski <marcin.skalski@konghq.com>
  • Loading branch information
Automaat authored Nov 21, 2022
1 parent a04c4b0 commit 531d380
Show file tree
Hide file tree
Showing 49 changed files with 3,623 additions and 141 deletions.
103 changes: 103 additions & 0 deletions app/kumactl/cmd/completion/testdata/bash.golden
Original file line number Diff line number Diff line change
Expand Up @@ -1762,6 +1762,76 @@ _kumactl_get_meshgateways()
noun_aliases=()
}

_kumactl_get_meshtimeout()
{
last_command="kumactl_get_meshtimeout"

command_aliases=()

commands=()

flags=()
two_word_flags=()
local_nonpersistent_flags=()
flags_with_completion=()
flags_completion=()

flags+=("--mesh=")
two_word_flags+=("--mesh")
two_word_flags+=("-m")
flags+=("--api-timeout=")
two_word_flags+=("--api-timeout")
flags+=("--config-file=")
two_word_flags+=("--config-file")
flags+=("--log-level=")
two_word_flags+=("--log-level")
flags+=("--no-config")
flags+=("--output=")
two_word_flags+=("--output")
two_word_flags+=("-o")

must_have_one_flag=()
must_have_one_noun=()
noun_aliases=()
}

_kumactl_get_meshtimeouts()
{
last_command="kumactl_get_meshtimeouts"

command_aliases=()

commands=()

flags=()
two_word_flags=()
local_nonpersistent_flags=()
flags_with_completion=()
flags_completion=()

flags+=("--mesh=")
two_word_flags+=("--mesh")
two_word_flags+=("-m")
flags+=("--offset=")
two_word_flags+=("--offset")
flags+=("--size=")
two_word_flags+=("--size")
flags+=("--api-timeout=")
two_word_flags+=("--api-timeout")
flags+=("--config-file=")
two_word_flags+=("--config-file")
flags+=("--log-level=")
two_word_flags+=("--log-level")
flags+=("--no-config")
flags+=("--output=")
two_word_flags+=("--output")
two_word_flags+=("-o")

must_have_one_flag=()
must_have_one_noun=()
noun_aliases=()
}

_kumactl_get_meshtrace()
{
last_command="kumactl_get_meshtrace"
Expand Down Expand Up @@ -2839,6 +2909,8 @@ _kumactl_get()
commands+=("meshgatewayroute")
commands+=("meshgatewayroutes")
commands+=("meshgateways")
commands+=("meshtimeout")
commands+=("meshtimeouts")
commands+=("meshtrace")
commands+=("meshtraces")
commands+=("meshtrafficpermission")
Expand Down Expand Up @@ -3172,6 +3244,36 @@ _kumactl_inspect_meshgateway()
noun_aliases=()
}

_kumactl_inspect_meshtimeout()
{
last_command="kumactl_inspect_meshtimeout"

command_aliases=()

commands=()

flags=()
two_word_flags=()
local_nonpersistent_flags=()
flags_with_completion=()
flags_completion=()

flags+=("--api-timeout=")
two_word_flags+=("--api-timeout")
flags+=("--config-file=")
two_word_flags+=("--config-file")
flags+=("--log-level=")
two_word_flags+=("--log-level")
flags+=("--no-config")
flags+=("--output=")
two_word_flags+=("--output")
two_word_flags+=("-o")

must_have_one_flag=()
must_have_one_noun=()
noun_aliases=()
}

_kumactl_inspect_meshtrace()
{
last_command="kumactl_inspect_meshtrace"
Expand Down Expand Up @@ -3674,6 +3776,7 @@ _kumactl_inspect()
commands+=("meshaccesslog")
commands+=("meshes")
commands+=("meshgateway")
commands+=("meshtimeout")
commands+=("meshtrace")
commands+=("meshtrafficpermission")
commands+=("proxytemplate")
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -207,6 +207,7 @@ rules:
- meshgatewayroutes
- meshgatewayinstances
- meshaccesslogs
- meshtimeouts
- meshtraces
- meshtrafficpermissions
verbs:
Expand Down Expand Up @@ -501,7 +502,7 @@ spec:
metadata:
annotations:
checksum/config: c52be51867deb8823a422dc1d188c7a2ab7fc5e501f620467d7fdd8fc4637d47
checksum/tls-secrets: 0ba784d2b167dfda86979b636ad66c25c71e8a5fc80126ac10e97e65496ed6b2
checksum/tls-secrets: faa99eb0cb4d10a6d1f0cfeb938194fb2f04bd41dbead69912beaede8bda99cf
labels:
app: kuma-control-plane
app.kubernetes.io/name: kuma
Expand Down Expand Up @@ -660,6 +661,7 @@ webhooks:
resources:
- meshes
- meshaccesslogs
- meshtimeouts
- meshtraces
- meshtrafficpermissions
sideEffects: None
Expand Down Expand Up @@ -696,6 +698,7 @@ webhooks:
- traffictraces
- virtualoutbounds
- meshaccesslogs
- meshtimeouts
- meshtraces
- meshtrafficpermissions

Expand Down Expand Up @@ -814,6 +817,7 @@ webhooks:
- zones
- containerpatches
- meshaccesslogs
- meshtimeouts
- meshtraces
- meshtrafficpermissions

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -207,6 +207,7 @@ rules:
- meshgatewayroutes
- meshgatewayinstances
- meshaccesslogs
- meshtimeouts
- meshtraces
- meshtrafficpermissions
verbs:
Expand Down Expand Up @@ -519,7 +520,7 @@ spec:
metadata:
annotations:
checksum/config: c52be51867deb8823a422dc1d188c7a2ab7fc5e501f620467d7fdd8fc4637d47
checksum/tls-secrets: 0ba784d2b167dfda86979b636ad66c25c71e8a5fc80126ac10e97e65496ed6b2
checksum/tls-secrets: faa99eb0cb4d10a6d1f0cfeb938194fb2f04bd41dbead69912beaede8bda99cf
labels:
app: kuma-control-plane
app.kubernetes.io/name: kuma
Expand Down Expand Up @@ -682,6 +683,7 @@ webhooks:
resources:
- meshes
- meshaccesslogs
- meshtimeouts
- meshtraces
- meshtrafficpermissions
sideEffects: None
Expand Down Expand Up @@ -718,6 +720,7 @@ webhooks:
- traffictraces
- virtualoutbounds
- meshaccesslogs
- meshtimeouts
- meshtraces
- meshtrafficpermissions

Expand Down Expand Up @@ -836,6 +839,7 @@ webhooks:
- zones
- containerpatches
- meshaccesslogs
- meshtimeouts
- meshtraces
- meshtrafficpermissions

Expand Down
Loading

0 comments on commit 531d380

Please sign in to comment.