-
Notifications
You must be signed in to change notification settings - Fork 465
Closed
Labels
type: feature request‘Nice-to-have’ improvement, new feature or different behavior or design.‘Nice-to-have’ improvement, new feature or different behavior or design.
Description
If a timeout is specified for NetHttpRequest, a singlethreadedexecutor is created.
https://github.com/googleapis/google-http-java-client/blob/master/google-http-client/src/main/java/com/google/api/client/http/javanet/NetHttpRequest.java#L184
This creates a new thread for every request which showed up as a 30% cpu increase issuing requests when writing to BigQuery from a Cloud Dataflow pipeline.
It seems that this cost could be reduced by using a cachedThreadPool, or by allowing the caller to inject an executorService to be used.
dzikoyskRussiaVk
Metadata
Metadata
Assignees
Labels
type: feature request‘Nice-to-have’ improvement, new feature or different behavior or design.‘Nice-to-have’ improvement, new feature or different behavior or design.