Skip to content

bugfix enable wrapper openfeign client with spring-cloud-circuitbreak… - #3980

Open
TianMing2018 wants to merge 5 commits into
alibaba:2023.xfrom
TianMing2018:2023.x
Open

bugfix enable wrapper openfeign client with spring-cloud-circuitbreak…#3980
TianMing2018 wants to merge 5 commits into
alibaba:2023.xfrom
TianMing2018:2023.x

Conversation

@TianMing2018

Copy link
Copy Markdown

Describe what this PR does / why we need it

refer to issue #3979

it will fix sample sentinel-circuitbreaker-example, make it return fallback info by enable wrapper openfeign client with spring-cloud-circuitbreak…

Does this pull request fix one issue?

Fixes #3979 sentinel-feign.FeignException$InternalServerError #3979

Describe how you did it

enable spring.cloud.openfeign.circuitbreaker.enabled

Describe how to verify it

  1. git clone https://github.com/alibaba/spring-cloud-alibaba -b 2023.x
  2. open spring-cloud-alibaba-examples/sentinel-example/sentinel-circuitbreaker-example
  3. enable spring.cloud.openfeign.circuitbreaker.enabled
  4. access this endpoint http://localhost/test/default/false , it should return user fallback

Special notes for reviews

Maybe we should shade starter spring-cloud-circuitbreaker-sentinel, toggle state with spring.cloud.circuitbreaker.sentinel.enabled

By the way, I found that many projects which based on spring-boot 3.x or spring-web 6.x, required jdk17+ and Jakarta. It affect many Sentinel releated projects ,eg alibabaspring-cloud-alibabaalibaba/Sentinel and sentinel-group/sentinel-website and alibaba/Sentinel.wiki, maybe we should archived some project and write more test case (blockHandler) for other modules to improve quality.

@CLAassistant

CLAassistant commented May 1, 2025

Copy link
Copy Markdown

CLA assistant check
All committers have signed the CLA.

@oss-sentinel-ai oss-sentinel-ai left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

Summary

This PR bundles multiple example/config updates (MySQL driver class, RocketMQ hostname, Dockerfiles, Helm charts, docs) together with an OpenFeign @PathVariable annotation fix. The changes are reasonable but span 36 files across different concerns.

Review Notes

  • @PathVariable(value = "ok") fix — Correct. Without -parameters compiler flag, Spring needs the explicit value attribute to resolve path variable names. This is a valid fix.
  • MySQL driver update (com.mysql.jdbc.Drivercom.mysql.cj.jdbc.Driver) — Good catch, the old class is deprecated.
  • RocketMQ hostname changes — Switching from hardcoded IP to service name (rocketmq-server) improves Docker Compose portability.
  • Scope concern: This PR mixes bugfixes, config updates, Dockerfile changes, and documentation updates. For future PRs, consider splitting these into separate commits or PRs for easier review and backporting.
  • Backport note: If these example fixes apply to maintained branches (2025.1.x, 2025.0.x), please mention target branches in the PR description.

Automated review by github-manager-bot

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.

sentinel-feign.FeignException$InternalServerError

3 participants