public class ServerCallHeaderAuthMiddleware extends Object implements FlightServerMiddleware
Modifier and Type | Class and Description |
---|---|
static class |
ServerCallHeaderAuthMiddleware.Factory
Factory for accessing ServerAuthMiddleware.
|
FlightServerMiddleware.Key<T extends FlightServerMiddleware>
Constructor and Description |
---|
ServerCallHeaderAuthMiddleware(CallHeaderAuthenticator.AuthResult authResult) |
Modifier and Type | Method and Description |
---|---|
void |
onBeforeSendingHeaders(CallHeaders outgoingHeaders)
Callback for when the underlying transport is about to send response headers.
|
void |
onCallCompleted(CallStatus status)
Callback for when the underlying transport has completed a call.
|
void |
onCallErrored(Throwable err)
Callback for when an RPC method implementation throws an uncaught exception.
|
public ServerCallHeaderAuthMiddleware(CallHeaderAuthenticator.AuthResult authResult)
public void onBeforeSendingHeaders(CallHeaders outgoingHeaders)
FlightServerMiddleware
onBeforeSendingHeaders
in interface FlightServerMiddleware
outgoingHeaders
- A mutable set of response headers. These can be manipulated to send different headers to the
client.public void onCallCompleted(CallStatus status)
FlightServerMiddleware
onCallCompleted
in interface FlightServerMiddleware
status
- Whether the call completed successfully or not.public void onCallErrored(Throwable err)
FlightServerMiddleware
May be called multiple times, and may be called before or after FlightServerMiddleware.onCallCompleted(CallStatus)
.
Generally, an uncaught exception will end the call with a error CallStatus
, and will be reported to FlightServerMiddleware.onCallCompleted(CallStatus)
, but not necessarily this method.
onCallErrored
in interface FlightServerMiddleware
err
- The exception that was thrown.Copyright © 2023 The Apache Software Foundation. All rights reserved.