Skip to content

Commit

Permalink
Upgrade horizontal scaling information (Keda) (#633)
Browse files Browse the repository at this point in the history
* initialize kedaClient

* fix hpa metrics

* log request errors as warnings

* insert HPA for controller test

* remove unused constant

* add client request logging

* add client request logging (simplified)

* add client request logging (simplified)

* add client request logging (simplified)

* refactor GetComponentsForDeployment

* test responses from scaledobjects and hpa

* test responses from scaledobjects and hpa

* fix unused import

* update swaggerui

* remove unused function

* Update api/utils/logs/roundtrip_logger.go

Co-authored-by: Nils Gustav Stråbø <65334626+nilsgstrabo@users.noreply.github.com>

* debugging

* handle client err seperatley from request error

* move getComponentStateFromSpec to environments package

* use kubequery where possible, remove unsuded fields

* cleanup deprecated fields, add lint ignore

* use same status code field as gin middleware

* Update api/deployments/component_handler.go

Co-authored-by: Nils Gustav Stråbø <65334626+nilsgstrabo@users.noreply.github.com>

* Update api/deployments/component_handler.go

Co-authored-by: Nils Gustav Stråbø <65334626+nilsgstrabo@users.noreply.github.com>

---------

Co-authored-by: Nils Gustav Stråbø <65334626+nilsgstrabo@users.noreply.github.com>
  • Loading branch information
Richard87 and nilsgstrabo authored Jun 14, 2024
1 parent a374de8 commit 0e583c9
Show file tree
Hide file tree
Showing 22 changed files with 956 additions and 500 deletions.
4 changes: 2 additions & 2 deletions .vscode/launch.json
Original file line number Diff line number Diff line change
Expand Up @@ -14,10 +14,10 @@
"RADIX_CONTAINER_REGISTRY":"radixdev.azurecr.io",
"PIPELINE_IMG_TAG": "master-latest",
"TEKTON_IMG_TAG": "main-latest",
"K8S_API_HOST": "https://weekly-14-clusters-16ede4-97pzjkre.hcp.northeurope.azmk8s.io",
"K8S_API_HOST": "https://weekly-24-clusters-dev-16ede4-uk527vqt.hcp.northeurope.azmk8s.io:443",
"RADIX_CLUSTER_TYPE": "development",
"RADIX_DNS_ZONE": "dev.radix.equinor.com",
"RADIX_CLUSTERNAME": "weekly-14",
"RADIX_CLUSTERNAME": "weekly-24",
"RADIX_ACTIVE_CLUSTER_EGRESS_IPS": "104.45.84.1",
"REQUIRE_APP_CONFIGURATION_ITEM": "true",
"REQUIRE_APP_AD_GROUPS": "true",
Expand Down
2 changes: 1 addition & 1 deletion api/applications/get_applications_handler.go
Original file line number Diff line number Diff line change
Expand Up @@ -133,7 +133,7 @@ func getComponentsForActiveDeploymentsInEnvironments(ctx context.Context, deploy

envName := env.Name
g.Go(func() error {
componentModels, err := deploy.GetComponentsForDeployment(ctx, appName, deployment)
componentModels, err := deploy.GetComponentsForDeployment(ctx, appName, deployment.Name, deployment.Environment)
if err == nil {
chanData <- &ChannelData{key: envName, components: componentModels}
}
Expand Down
260 changes: 213 additions & 47 deletions api/deployments/component_controller_test.go

Large diffs are not rendered by default.

Loading

0 comments on commit 0e583c9

Please sign in to comment.