Skip to content

Conversation

@joschi
Copy link
Contributor

@joschi joschi commented Nov 19, 2025

Some load balancers cannot handle HTTP response codes other than 200 (OK) in health checks and treat every other response codes (even in the 2xx range) as unhealthy.

The response codes of the /ready and /healthy HTTP resources has been changed from 204 (No Content) to 200 (OK) to accommodate these load balancer health checks.

@ppatierno
Copy link
Member

Thanks for the PR! I was wondering if this type of change would need a Strimzi proposal first in order to explain the motivation for the change (which is anyway in the description here) and the compatibility with current users. It would not be that complex and in the past we had similar proposals like https://github.com/strimzi/proposals/blob/main/063-pdb-generation-environment-variable.md and https://github.com/strimzi/proposals/blob/main/028-network-policy-generation-environment-variable.md to use an env var for changing the default behaviour within the Strimzi operator. @strimzi/maintainers wdyt?

@ppatierno
Copy link
Member

@joschi meanwhile please check that doc build is failing with the following error (in the Azure pipeline):

ERROR: Uncommitted changes in documentation:
M	documentation/book/api/.openapi-generator/openapi.json-generate-apidoc.sha256
M	documentation/book/api/index.adoc
Run the following to add up-to-date resources:
  make docu_api \
    && git add documentation/book/ \
    && git commit -s -m 'Update generated documentation'
make: *** [Makefile:69: docu_check] Error 1

you should be able to fix it by just following the above instructions.

@joschi joschi force-pushed the fix-health-checks-response-status branch 3 times, most recently from 93c17a7 to e357b50 Compare November 19, 2025 11:00
@see-quick
Copy link
Member

Thanks for the PR! I was wondering if this type of change would need a Strimzi proposal first in order to explain the motivation for the change (which is anyway in the description here) and the compatibility with current users. It would not be that complex and in the past we had similar proposals like https://github.com/strimzi/proposals/blob/main/063-pdb-generation-environment-variable.md and https://github.com/strimzi/proposals/blob/main/028-network-policy-generation-environment-variable.md to use an env var for changing the default behaviour within the Strimzi operator. @strimzi/maintainers wdyt?

SGTM 👍 having the proposal to set motivation and make it more visible (to current users).

joschi added a commit to joschi/proposals that referenced this pull request Nov 24, 2025
This proposal introduces an environment variable to configure the HTTP response status code for Kafka Bridge health check endpoints, addressing compatibility issues with various cloud load balancers.

Refs strimzi/strimzi-kafka-bridge#1047

Signed-off-by: Jochen Schalanda <[email protected]>
@joschi
Copy link
Contributor Author

joschi commented Nov 24, 2025

Some load balancers cannot handle HTTP response codes other than 200 (OK) in health checks and treat every other response codes (even in the 2xx range) as unhealthy.

The response codes of the `/ready` and `/healthy` HTTP resources has been changed from 204 (No Content) to 200 (OK) to accommodate these load balancer health checks.

Signed-off-by: Jochen Schalanda <[email protected]>
@joschi joschi force-pushed the fix-health-checks-response-status branch from e357b50 to f36e1cc Compare December 17, 2025 16:40
@joschi
Copy link
Contributor Author

joschi commented Dec 17, 2025

@ppatierno @see-quick changed the PR according to the latest proposal.

@joschi joschi changed the title feat: make response status of health checks configurable feat!: change success response status of health checks to 200 (OK) Dec 17, 2025
@joschi joschi changed the title feat!: change success response status of health checks to 200 (OK) Change success response status of health checks to 200 (OK) Dec 17, 2025
@ppatierno ppatierno requested review from a team and ppatierno December 18, 2025 08:47
@ppatierno
Copy link
Member

Thanks @joschi let's wait for the proposal to be approved.

@ppatierno ppatierno added this to the 0.34.0 milestone Dec 18, 2025
joschi added a commit to joschi/proposals that referenced this pull request Dec 18, 2025
This proposal introduces an environment variable to configure the HTTP response status code for Kafka Bridge health check endpoints, addressing compatibility issues with various cloud load balancers.

Refs strimzi/strimzi-kafka-bridge#1047

Signed-off-by: Jochen Schalanda <[email protected]>
ppatierno added a commit to strimzi/proposals that referenced this pull request Dec 19, 2025
* Add configurable HTTP response status for health checks

This proposal introduces an environment variable to configure the HTTP response status code for Kafka Bridge health check endpoints, addressing compatibility issues with various cloud load balancers.

Refs strimzi/strimzi-kafka-bridge#1047

Signed-off-by: Jochen Schalanda <[email protected]>

* Add more details about the proposal

Signed-off-by: Jochen Schalanda <[email protected]>

* Update 124-configurable-health-check-response-status.md

Co-authored-by: Paolo Patierno <[email protected]>
Signed-off-by: Jochen Schalanda <[email protected]>

* Add proposal 125 to table in README

Signed-off-by: Jochen Schalanda <[email protected]>

* Update proposal

Signed-off-by: Jochen Schalanda <[email protected]>

* Update 124-configurable-health-check-response-status.md

Signed-off-by: Jochen Schalanda <[email protected]>

* Renumber proposal and update title

Signed-off-by: Jochen Schalanda <[email protected]>

---------

Signed-off-by: Jochen Schalanda <[email protected]>
Co-authored-by: Paolo Patierno <[email protected]>
Copy link
Member

@ppatierno ppatierno left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM. Thanks!

@ppatierno ppatierno merged commit d0091aa into strimzi:main Dec 24, 2025
11 checks passed
@scholzj
Copy link
Member

scholzj commented Dec 24, 2025

@ppatierno I guess we both missed the CHANGELOG update :-/

@ppatierno
Copy link
Member

I realized right after merging but I opened the PR for that.

@scholzj
Copy link
Member

scholzj commented Dec 24, 2025

I realized right after merging but I opened the PR for that.

Yeah, I somehow realized it immediately when I saw the merge email ... I guess the brain works in strange ways 🤷 😄

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants