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

GEODE-9441: Reduce Nested func test thread count #6708

Conversation

demery-pivotal
Copy link
Contributor

Change NestedFunctionExecutionDistributedTest to create fewer threads.

The test creates a number of threads that is a multiple of
MAX_FE_THREADS. On a CI machine, the default value of MAX_FE_THREADS
can be very high, causing this test to create thousands of threads. This
can leave the system unable to create threads for other processes, which
in turn can cause Gradle processes or other tests to fail or hang.

This test now sets MAX_FE_THREADS to a lower value (100), which
suffices for the purpose of the test, and results in greatly reduced
consumption of threads.

Co-authored-by: Dale Emery demery@vmware.com

Change `NestedFunctionExecutionDistributedTest` to create fewer threads.

The test creates a number of threads that is a multiple of
`MAX_FE_THREADS`. On a CI machine, the default value of `MAX_FE_THREADS`
can be very high, causing this test to create thousands of threads. This
can leave the system unable to create threads for other processes, which
in turn can cause Gradle processes or other tests to fail or hang.

This test now sets `MAX_FE_THREADS` to a lower value (100), which
suffices for the purpose of the test, and results in greatly reduced
consumption of threads.

Co-authored-by: Dale Emery <demery@vmware.com>
@demery-pivotal demery-pivotal marked this pull request as ready for review July 20, 2021 20:46
@@ -111,6 +116,7 @@ private int createServerCache() throws IOException {

private void createClientCache(int port, int functionTimeout) {
System.setProperty(GEMFIRE_PREFIX + "CLIENT_FUNCTION_TIMEOUT", String.valueOf(functionTimeout));
System.setProperty(MAX_FE_THREADS_PROPERTY, TEST_MAX_FE_THREADS);
Copy link
Contributor

Choose a reason for hiding this comment

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

Its not necessary to set this value in the client. The Function Execution thread pool is not created there.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Currently the client does MAX_FE_THREADS * 2 executions of ParentFunction. If I don't set MAX_FE_THREADS in the client, I get a swarm of "Pool unexpected socket timed out on client connection" failures with that many functions. Should I directly reduce the number of functions it executes, rather than computing from MAX_FE_THREADS?

Copy link
Contributor

Choose a reason for hiding this comment

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

Sorry, you're right. You should set it.

@demery-pivotal demery-pivotal merged commit 6890221 into apache:develop Jul 20, 2021
@demery-pivotal demery-pivotal deleted the geode-9441-nested-function-execution-threads branch July 20, 2021 22:45
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
2 participants