Skip to content

Commit

Permalink
Merge remote-tracking branch 'upstream/main' into fix-5570
Browse files Browse the repository at this point in the history
Signed-off-by: Yury Akudovich <[email protected]>
  • Loading branch information
yorik committed Feb 4, 2025
2 parents 4086a65 + d1eb176 commit 7da0be4
Show file tree
Hide file tree
Showing 10 changed files with 36 additions and 28 deletions.
6 changes: 3 additions & 3 deletions .github/ISSUE_TEMPLATE/3_bug_report.yml
Original file line number Diff line number Diff line change
Expand Up @@ -76,10 +76,10 @@ body:
label: Kubernetes Version
description: What version of Kubernetes that are you running?
options:
- "1.32"
- "1.31"
- "1.30"
- "1.29"
- "1.28"
- "< 1.28"
- "< 1.29"
- "Other"
validations:
required: false
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/pr-validation.yml
Original file line number Diff line number Diff line change
Expand Up @@ -144,7 +144,7 @@ jobs:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4
- uses: actions/setup-python@0b93645e9fea7318ecaed2b359559ac225c90a2b # v5.3.0
- uses: actions/setup-python@42375524e23c412d93fb67b49958b491fce71c38 # v5.4.0
with:
python-version: 3.x
- uses: actions/setup-go@f111f3307d8850f501ac008e886eec1fd1932a34 # v5
Expand Down
4 changes: 2 additions & 2 deletions .github/workflows/template-arm64-smoke-tests.yml
Original file line number Diff line number Diff line change
Expand Up @@ -10,5 +10,5 @@ jobs:
uses: kedacore/keda/.github/workflows/template-smoke-tests.yml@main
with:
runs-on: ARM64
kubernetesVersion: v1.30
kindImage: kindest/node:v1.30.0@sha256:047357ac0cfea04663786a612ba1eaba9702bef25227a794b52890dd8bcd692e
kubernetesVersion: v1.32
kindImage: kindest/node:v1.32.0@sha256:c48c62eac5da28cdadcf560d1d8616cfa6783b58f0d94cf63ad1bf49600cb027
12 changes: 6 additions & 6 deletions .github/workflows/template-versions-smoke-tests.yml
Original file line number Diff line number Diff line change
Expand Up @@ -9,14 +9,14 @@ jobs:
strategy:
fail-fast: false
matrix:
kubernetesVersion: [v1.30, v1.29, v1.28]
kubernetesVersion: [v1.32, v1.31, v1.30]
include:
- kubernetesVersion: v1.32
kindImage: kindest/node:v1.32.0@sha256:c48c62eac5da28cdadcf560d1d8616cfa6783b58f0d94cf63ad1bf49600cb027
- kubernetesVersion: v1.31
kindImage: kindest/node:v1.31.4@sha256:2cb39f7295fe7eafee0842b1052a599a4fb0f8bcf3f83d96c7f4864c357c6c30
- kubernetesVersion: v1.30
kindImage: kindest/node:v1.30.0@sha256:047357ac0cfea04663786a612ba1eaba9702bef25227a794b52890dd8bcd692e
- kubernetesVersion: v1.29
kindImage: kindest/node:v1.29.4@sha256:3abb816a5b1061fb15c6e9e60856ec40d56b7b52bcea5f5f1350bc6e2320b6f8
- kubernetesVersion: v1.28
kindImage: kindest/node:v1.28.9@sha256:dca54bc6a6079dd34699d53d7d4ffa2e853e46a20cd12d619a09207e35300bd0
kindImage: kindest/node:v1.30.8@sha256:17cd608b3971338d9180b00776cb766c50d0a0b6b904ab4ff52fd3fc5c6369bf
uses: kedacore/keda/.github/workflows/template-smoke-tests.yml@main
with:
runs-on: ubuntu-latest
Expand Down
2 changes: 2 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -72,6 +72,7 @@ Here is an overview of all new **experimental** features:
### Improvements

- **IBMMQ Scaler**: Handling StatusNotFound in IBMMQ scaler ([#6472](https://github.com/kedacore/keda/pull/6472))
- **RabbitMQ Scaler**: Support use of the ‘vhostName’ parameter in the ‘TriggerAuthentication’ resource ([#6369](https://github.com/kedacore/keda/issues/6369))

### Fixes

Expand All @@ -96,6 +97,7 @@ New deprecation(s):

### Other

- **General**: Add debug logs tracking validation of ScaledObjects on webhook ([#6498](https://github.com/kedacore/keda/pull/6498))
- **General**: New eventreason KEDAScalersInfo to display important information ([#6328](https://github.com/kedacore/keda/issues/6328))

## v2.16.1
Expand Down
2 changes: 1 addition & 1 deletion Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -52,7 +52,7 @@ GO_LDFLAGS="-X=github.com/kedacore/keda/v2/version.GitCommit=$(GIT_COMMIT) -X=gi
COSIGN_FLAGS ?= -y -a GIT_HASH=${GIT_COMMIT} -a GIT_VERSION=${VERSION} -a BUILD_DATE=${DATE}

# ENVTEST_K8S_VERSION refers to the version of kubebuilder assets to be downloaded by envtest binary.
ENVTEST_K8S_VERSION = 1.31
ENVTEST_K8S_VERSION = 1.32

# Setting SHELL to bash allows bash commands to be executed by recipes.
# This is a requirement for 'setup-envtest.sh' in the test target.
Expand Down
26 changes: 14 additions & 12 deletions apis/keda/v1alpha1/scaledobject_webhook.go
Original file line number Diff line number Diff line change
Expand Up @@ -148,27 +148,29 @@ func isRemovingFinalizer(so *ScaledObject, old runtime.Object) bool {
func validateWorkload(so *ScaledObject, action string, dryRun bool) (admission.Warnings, error) {
metricscollector.RecordScaledObjectValidatingTotal(so.Namespace, action)

verifyFunctions := []func(*ScaledObject, string, bool) error{
verifyCPUMemoryScalers,
verifyScaledObjects,
verifyHpas,
verifyReplicaCount,
verifyFallback,
verifyFunctions := map[string]func(*ScaledObject, string, bool) error{
"verifyCPUMemoryScalers": verifyCPUMemoryScalers,
"verifyScaledObjects": verifyScaledObjects,
"verifyHpas": verifyHpas,
"verifyReplicaCount": verifyReplicaCount,
"verifyFallback": verifyFallback,
}

for i := range verifyFunctions {
err := verifyFunctions[i](so, action, dryRun)
for functionName, function := range verifyFunctions {
scaledobjectlog.V(1).Info(fmt.Sprintf("calling %s to validate %s", functionName, so.Name))
err := function(so, action, dryRun)
if err != nil {
return nil, err
}
}

verifyCommonFunctions := []func(interface{}, string, bool) error{
verifyTriggers,
verifyCommonFunctions := map[string]func(interface{}, string, bool) error{
"verifyTriggers": verifyTriggers,
}

for i := range verifyCommonFunctions {
err := verifyCommonFunctions[i](so, action, dryRun)
for functionName, function := range verifyCommonFunctions {
scaledobjectlog.V(1).Info(fmt.Sprintf("calling %s to validate %s", functionName, so.Name))
err := function(so, action, dryRun)
if err != nil {
return nil, err
}
Expand Down
2 changes: 1 addition & 1 deletion pkg/scalers/rabbitmq_scaler.go
Original file line number Diff line number Diff line change
Expand Up @@ -86,7 +86,7 @@ type rabbitMQMetadata struct {
// either http or amqp protocol
Protocol string `keda:"name=protocol, order=triggerMetadata;authParams, default=auto"`
// override the vhost from the connection info
VhostName string `keda:"name=vhostName, order=triggerMetadata, optional"`
VhostName string `keda:"name=vhostName, order=triggerMetadata;authParams, optional"`
// specify if the queueName contains a rexeg
UseRegex bool `keda:"name=useRegex, order=triggerMetadata, optional"`
// specify if the QueueLength value should exclude Unacknowledged messages (Ready messages only)
Expand Down
4 changes: 4 additions & 0 deletions pkg/scalers/rabbitmq_scaler_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -161,6 +161,10 @@ var testRabbitMQAuthParamData = []parseRabbitMQAuthParamTestData{
{map[string]string{"queueName": "sample", "hostFromEnv": host}, v1alpha1.AuthPodIdentity{}, map[string]string{"username": "user"}, true, rmqTLSDisable, false},
// failure, password but no username
{map[string]string{"queueName": "sample", "hostFromEnv": host}, v1alpha1.AuthPodIdentity{}, map[string]string{"password": "PASSWORD"}, true, rmqTLSDisable, false},
// success, vhostName
{map[string]string{"queueName": "sample", "hostFromEnv": host}, v1alpha1.AuthPodIdentity{}, map[string]string{"vhostName": "myVhost"}, false, rmqTLSDisable, false},
// success, vhostName but empty
{map[string]string{"queueName": "sample", "hostFromEnv": host}, v1alpha1.AuthPodIdentity{}, map[string]string{"vhostName": ""}, false, rmqTLSDisable, false},
// success, username and password from env
{map[string]string{"queueName": "sample", "hostFromEnv": host, "usernameFromEnv": rabbitMQUsername, "passwordFromEnv": rabbitMQPassword}, v1alpha1.AuthPodIdentity{}, map[string]string{}, false, rmqTLSDisable, false},
// failure, username from env but not password
Expand Down
4 changes: 2 additions & 2 deletions pkg/util/welcome.go
Original file line number Diff line number Diff line change
Expand Up @@ -26,8 +26,8 @@ import (
)

const (
minSupportedVersion = 29
maxSupportedVersion = 31
minSupportedVersion = 30
maxSupportedVersion = 32
)

func PrintWelcome(logger logr.Logger, kubeVersion K8sVersion, component string) {
Expand Down

0 comments on commit 7da0be4

Please sign in to comment.