[ https://issues.apache.org/jira/browse/ARROW-10441?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
David Li reassigned ARROW-10441: -------------------------------- Assignee: Kyle Porter > [FlightRPC][Java] FlightClients from FlightGrpcUtils#createFlightClient > shutdown gRPC channel when closed > --------------------------------------------------------------------------------------------------------- > > Key: ARROW-10441 > URL: https://issues.apache.org/jira/browse/ARROW-10441 > Project: Apache Arrow > Issue Type: Bug > Components: FlightRPC, Java > Affects Versions: 2.0.0 > Reporter: Kyle Porter > Assignee: Kyle Porter > Priority: Minor > Labels: pull-request-available > Fix For: 3.0.0 > > Time Spent: 1h > Remaining Estimate: 0h > > It seems there may be a mistake in the Java FlightClient where it's possible > to create multiple FlightClients from a single ManagedChannel. > > See > [https://github.com/apache/arrow/blob/master/java/flight/flight-grpc/src/main/java/org/apache/arrow/flight/FlightGrpcUtils.java#L55] > which lets you specify the channel. However, if you do create multiple > FlightClients from a single channel, then calling close() > (https://github.com/apache/arrow/blob/master/java/flight/flight-core/src/main/java/org/apache/arrow/flight/FlightClient.java#L503) > on a single FlightClient will close the channel for all of the FlightClients > that share that channel, which seems incorrect. > > It's possible that the FlightGrpcUtils was intended only for testing purposes > and this should never happen in practice. A few possible options would be to: > * This behaviour is intended, no action. > * Track if a channel is used by multiple clients and only close on the last > client to close. > * Disallow creation of a FlightClient with a specified ManagedChannel. -- This message was sent by Atlassian Jira (v8.3.4#803005)