diff --git a/java/flight/flight-core/src/main/java/org/apache/arrow/flight/auth/ClientAuthHandler.java b/java/flight/flight-core/src/main/java/org/apache/arrow/flight/auth/ClientAuthHandler.java index 985e10aa4dd..af7da86e009 100644 --- a/java/flight/flight-core/src/main/java/org/apache/arrow/flight/auth/ClientAuthHandler.java +++ b/java/flight/flight-core/src/main/java/org/apache/arrow/flight/auth/ClientAuthHandler.java @@ -19,9 +19,16 @@ import java.util.Iterator; +import org.apache.arrow.flight.FlightClient; + /** * Implement authentication for Flight on the client side. + * + * @deprecated As of 14.0.0. This implements a stateful "login" flow that does not play well with + * distributed or stateless systems. It will not be removed, but should not be used. Instead + * see {@link FlightClient#authenticateBasicToken(String, String)}. */ +@Deprecated public interface ClientAuthHandler { /** * Handle the initial handshake with the server. diff --git a/java/flight/flight-core/src/main/java/org/apache/arrow/flight/auth/ServerAuthHandler.java b/java/flight/flight-core/src/main/java/org/apache/arrow/flight/auth/ServerAuthHandler.java index 3a978b131f2..378027c9287 100644 --- a/java/flight/flight-core/src/main/java/org/apache/arrow/flight/auth/ServerAuthHandler.java +++ b/java/flight/flight-core/src/main/java/org/apache/arrow/flight/auth/ServerAuthHandler.java @@ -20,9 +20,18 @@ import java.util.Iterator; import java.util.Optional; +import org.apache.arrow.flight.FlightServer; +import org.apache.arrow.flight.auth2.CallHeaderAuthenticator; + /** * Interface for Server side authentication handlers. + * + * @deprecated As of 14.0.0. This implements a stateful "login" flow that does not play well with + * distributed or stateless systems. It will not be removed, but should not be used. Instead, + * see {@link FlightServer.Builder#headerAuthenticator(CallHeaderAuthenticator)} + * and {@link CallHeaderAuthenticator}. */ +@Deprecated public interface ServerAuthHandler { /**