jduo commented on a change in pull request #7994:
URL: https://github.com/apache/arrow/pull/7994#discussion_r477542825



##########
File path: 
java/flight/flight-core/src/main/java/org/apache/arrow/flight/grpc/ServerInterceptorAdapter.java
##########
@@ -87,10 +87,12 @@ public ServerInterceptorAdapter(List<KeyFactory<?>> 
factories) {
     // Use LinkedHashMap to preserve insertion order
     final Map<FlightServerMiddleware.Key<?>, FlightServerMiddleware> 
middlewareMap = new LinkedHashMap<>();
     final MetadataAdapter headerAdapter = new MetadataAdapter(headers);
+    Context currentContext = Context.current();
     for (final KeyFactory<?> factory : factories) {
       final FlightServerMiddleware m;
       try {
         m = factory.factory.onCallStarted(info, headerAdapter);
+        currentContext = m.onAuthenticationSuccess(currentContext);

Review comment:
       I created a facade for this and supplied it as an input to onCallStarted.




----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
[email protected]


Reply via email to