Skip to content

Conversation

@hbhanawat
Copy link

@hbhanawat hbhanawat commented Aug 19, 2021

To reduce the overload of YB master on initialization, create the connections in batches by using a semaphore. The number of connections to be created in one go can be specified using a cmd line parameter.

Hemant Bhanawat added 2 commits August 19, 2021 17:12
connection creation by using a semaphore. The number of connections to
be created in one go can be specified using a cmd line parameter.
@hbhanawat hbhanawat changed the title Stagger connection creation Connection creation in batches Aug 19, 2021
Copy link

@fritshoogland-yugabyte fritshoogland-yugabyte left a comment

Choose a reason for hiding this comment

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

I need a rough description of what the idea of this code to batch connection creation is.

@hbhanawat
Copy link
Author

hbhanawat commented Aug 24, 2021

We started hitting the "connection creation failed" issues because we were trying to create too many connections. To avoid this error, I am creating the connection in batches i.e. create only n connections simultaneously where n can be specified as a cmd line parameter.
I am using semaphore like construct to ensure that only n connections are being created at any point in time.
@fritshoogland-yugabyte

Base automatically changed from multihostAndLoading to master December 10, 2021 08:41
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.

3 participants