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

Change Round Robin and WeightedRoundRobin into petiole policies #10528

Merged
merged 30 commits into from
Sep 15, 2023

Conversation

larry-safran
Copy link
Contributor

@larry-safran larry-safran commented Aug 30, 2023

Update MultiChildLoadBalancer to support changes needed for WRR.

Move deletion timer from MultiChildLoadBalancer back to ClusterManagerLoadBalancer as it only applies in the xds cluster case.

Add a generic Helper class for testing so that the mocks can delegate to it instead of complex when clauses. Not only simpler, but allows debugging.

@YifeiZhuang
Copy link
Contributor

@ejona86 do you have time to review? I have limited capacity so I would be very slow here.

@ejona86
Copy link
Member

ejona86 commented Sep 1, 2023

I'm unlikely to get to it before Tuesday, but I can take a look.

@larry-safran larry-safran requested review from temawi and removed request for YifeiZhuang September 6, 2023 00:32
ejona86 and others added 7 commits September 6, 2023 07:44
Blocking can be confused with the blocking stub, which is unrelated. I'm
purposefully not saying "it is used only for X," as that isn't what we
need from the API. But it is still helpful to users to describe the
sorts of things that use it.

Fixes grpc#10508
When a memory leak occurs, it is really helpful to have access records
to understand where the buffer was being held when it leaked. retain()
when we create the NettyReadableBuffer already creates an access record
the ByteBuf, so here we track when the ByteBuf is passed to another
thread.

See grpc#8330
Copy link
Contributor

@temawi temawi left a comment

Choose a reason for hiding this comment

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

I didn't review the original PR that introduced MultiChildLoadBalancer so some of my questions may be a bit ignorant and answered elsewhere, but humor me :-)

PR is pretty big with lot of intricate logic, so it was hard to wrap my brain around everything. Might still need to look at some things, but here's at least my initial thoughts.

YifeiZhuang and others added 9 commits September 8, 2023 15:09
Since 3b61799 OkHttp can support Grpc.newServerBuilderForPort().
Java 20+ don't support --release 7, so we just will use the default (8).
AndroidComponentAddress now accepts an Intent with merely a package
restriction, not a full ComponentName. This lets clients avoid hard
coding Service class names that they don't control.

Fixes grpc#9062
It is slow, and just tries a bunch of possibilities. Leave it around for
developers to run locally, but it isn't precise enough to run on every
build. This change reduces the build of servlet in isolation by
1 minute. I suspect the gains are larger in a full grpc build because it
is very CPU-intensive; it uses 600% CPU on my 8-thread CPU when running
by itself.
Copy link
Contributor

@temawi temawi left a comment

Choose a reason for hiding this comment

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

Check out the compile error in the Android build though.

@larry-safran larry-safran merged commit e1334ea into grpc:master Sep 15, 2023
14 checks passed
@larry-safran larry-safran deleted the round_robin4 branch September 15, 2023 17:27
@larry-safran larry-safran restored the round_robin4 branch September 26, 2023 23:17
larry-safran added a commit to larry-safran/grpc-java that referenced this pull request Sep 26, 2023
larry-safran added a commit to larry-safran/grpc-java that referenced this pull request Sep 26, 2023
larry-safran added a commit that referenced this pull request Sep 27, 2023
DNVindhya pushed a commit to DNVindhya/grpc-java that referenced this pull request Oct 5, 2023
…#10528)

* Change Round Robin and WeightedRoundRobin into petiole policies
DNVindhya pushed a commit to DNVindhya/grpc-java that referenced this pull request Oct 5, 2023
@larry-safran larry-safran deleted the round_robin4 branch October 18, 2023 00:41
@github-actions github-actions bot locked as resolved and limited conversation to collaborators Jan 16, 2024
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

9 participants