Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Replace Jetty client when tripping circuit breaker #31233

Merged
merged 2 commits into from
May 21, 2024

Conversation

jonmv
Copy link
Member

@jonmv jonmv commented May 16, 2024

this(builder, builder.dryrun ? new DryrunCluster() : new JettyCluster(builder));
this(builder,
builder.dryrun ? () -> new DryrunCluster()
: () -> { try { return new JettyCluster(builder); } catch (IOException e) { throw new UncheckedIOException(e); } });
Copy link
Member

Choose a reason for hiding this comment

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

Consider adding a ClusterFactory interface and using clusterFactory instead of clusters as variable name to clarify its intention.


@Override
public void dispatch(HttpRequest request, CompletableFuture<HttpResponse> vessel) {
inflight.add(vessel);
Copy link
Member

Choose a reason for hiding this comment

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

inflight will hold a reference to all previous and current operations until a reset occur? So it will leak memory until the circuit breaker is tripped?

bjorncs
bjorncs previously approved these changes May 21, 2024
Base automatically changed from jonmv/feed-retry-grace-period to master May 21, 2024 13:28
@jonmv jonmv dismissed bjorncs’s stale review May 21, 2024 13:28

The base branch was changed.

@jonmv jonmv merged commit e92a050 into master May 21, 2024
2 checks passed
@jonmv jonmv deleted the jonmv/reset-jetty-client-on-circuit-breaker-trip branch May 21, 2024 13:28
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.

None yet

2 participants