Documentation

Overview

Example (Server)
Output:

baz
foobar

Index

Examples

Constants

This section is empty.

Variables

View Source
var (
	FlightDescriptor_DescriptorType_name = map[int32]string{
		0: "UNKNOWN",
		1: "PATH",
		2: "CMD",
	}
	FlightDescriptor_DescriptorType_value = map[string]int32{
		"UNKNOWN": 0,
		"PATH":    1,
		"CMD":     2,
	}
)

    Enum value maps for FlightDescriptor_DescriptorType.

    View Source
    var File_Flight_proto protoreflect.FileDescriptor

    Functions

    func AuthFromContext

    func AuthFromContext(ctx context.Context) interface{}

      AuthFromContext will return back whatever object was returned from `IsValid` for a given request context allowing handlers to retrieve identifying information for the current request for use.

      func DeserializeSchema

      func DeserializeSchema(info []byte, mem memory.Allocator) (*arrow.Schema, error)

        DeserializeSchema takes the schema bytes from FlightInfo or SchemaResult and returns the deserialized arrow schema.

        func NewRecordReader

        func NewRecordReader(r DataStreamReader, opts ...ipc.Option) (*ipc.Reader, error)

          NewRecordReader constructs an ipc reader using the flight data stream reader as the source of the ipc messages, opts passed will be passed to the underlying ipc.Reader such as ipc.WithSchema and ipc.WithAllocator

          func NewRecordWriter

          func NewRecordWriter(w DataStreamWriter, opts ...ipc.Option) *ipc.Writer

            NewRecordWriter can be used to construct a writer for arrow flight via the grpc stream handler to write flight data objects and write record batches to the stream. Options passed here will be passed to ipc.NewWriter

            func RegisterFlightServiceService

            func RegisterFlightServiceService(s grpc.ServiceRegistrar, srv *FlightServiceService)

              RegisterFlightServiceService registers a service implementation with a gRPC server.

              func SerializeSchema

              func SerializeSchema(rec *arrow.Schema, mem memory.Allocator) []byte

                SerializeSchema returns the serialized schema bytes for use in Arrow Flight protobuf messages.

                Types

                type Action

                type Action struct {
                	Type string `protobuf:"bytes,1,opt,name=type,proto3" json:"type,omitempty"`
                	Body []byte `protobuf:"bytes,2,opt,name=body,proto3" json:"body,omitempty"`
                	// contains filtered or unexported fields
                }

                  An opaque action specific for the service.

                  func (*Action) Descriptor

                  func (*Action) Descriptor() ([]byte, []int)

                    Deprecated: Use Action.ProtoReflect.Descriptor instead.

                    func (*Action) GetBody

                    func (x *Action) GetBody() []byte

                    func (*Action) GetType

                    func (x *Action) GetType() string

                    func (*Action) ProtoMessage

                    func (*Action) ProtoMessage()

                    func (*Action) ProtoReflect

                    func (x *Action) ProtoReflect() protoreflect.Message

                    func (*Action) Reset

                    func (x *Action) Reset()

                    func (*Action) String

                    func (x *Action) String() string

                    type ActionType

                    type ActionType struct {
                    	Type        string `protobuf:"bytes,1,opt,name=type,proto3" json:"type,omitempty"`
                    	Description string `protobuf:"bytes,2,opt,name=description,proto3" json:"description,omitempty"`
                    	// contains filtered or unexported fields
                    }

                      Describes an available action, including both the name used for execution along with a short description of the purpose of the action.

                      func (*ActionType) Descriptor

                      func (*ActionType) Descriptor() ([]byte, []int)

                        Deprecated: Use ActionType.ProtoReflect.Descriptor instead.

                        func (*ActionType) GetDescription

                        func (x *ActionType) GetDescription() string

                        func (*ActionType) GetType

                        func (x *ActionType) GetType() string

                        func (*ActionType) ProtoMessage

                        func (*ActionType) ProtoMessage()

                        func (*ActionType) ProtoReflect

                        func (x *ActionType) ProtoReflect() protoreflect.Message

                        func (*ActionType) Reset

                        func (x *ActionType) Reset()

                        func (*ActionType) String

                        func (x *ActionType) String() string

                        type AuthConn

                        type AuthConn interface {
                        	Read() ([]byte, error)
                        	Send([]byte) error
                        }

                          AuthConn wraps the stream from grpc for handshakes to simplify handling handshake request and response from the flight.proto forwarding just the payloads and errors instead of having to deal with the handshake request and response protos directly

                          type BasicAuth

                          type BasicAuth struct {
                          	Username string `protobuf:"bytes,2,opt,name=username,proto3" json:"username,omitempty"`
                          	Password string `protobuf:"bytes,3,opt,name=password,proto3" json:"password,omitempty"`
                          	// contains filtered or unexported fields
                          }

                            A message for doing simple auth.

                            func (*BasicAuth) Descriptor

                            func (*BasicAuth) Descriptor() ([]byte, []int)

                              Deprecated: Use BasicAuth.ProtoReflect.Descriptor instead.

                              func (*BasicAuth) GetPassword

                              func (x *BasicAuth) GetPassword() string

                              func (*BasicAuth) GetUsername

                              func (x *BasicAuth) GetUsername() string

                              func (*BasicAuth) ProtoMessage

                              func (*BasicAuth) ProtoMessage()

                              func (*BasicAuth) ProtoReflect

                              func (x *BasicAuth) ProtoReflect() protoreflect.Message

                              func (*BasicAuth) Reset

                              func (x *BasicAuth) Reset()

                              func (*BasicAuth) String

                              func (x *BasicAuth) String() string

                              type BasicAuthValidator

                              type BasicAuthValidator interface {
                              	Validate(username, password string) (string, error)
                              	IsValid(bearerToken string) (interface{}, error)
                              }

                              type Client

                              type Client interface {
                              	// Authenticate uses the ClientAuthHandler that was used when creating the client
                              	// in order to use the Handshake endpoints of the service.
                              	Authenticate(context.Context, ...grpc.CallOption) error
                              	AuthenticateBasicToken(ctx context.Context, username string, password string, opts ...grpc.CallOption) (context.Context, error)
                              	Close() error
                              	// join the interface from the FlightServiceClient instead of re-defining all
                              	// the endpoints here.
                              	FlightServiceClient
                              }

                                Client is an interface wrapped around the generated FlightServiceClient which is generated by grpc protobuf definitions. This interface provides a useful hiding of the authentication handshake via calling Authenticate and using the ClientAuthHandler rather than manually having to implement the grpc communication and sending of the auth token.

                                func NewFlightClient

                                func NewFlightClient(addr string, auth ClientAuthHandler, opts ...grpc.DialOption) (Client, error)

                                  NewFlightClient takes in the address of the grpc server and an auth handler for the application-level handshake. If using TLS or other grpc configurations they can still be passed via the grpc.DialOption list just as if connecting manually without this helper function.

                                  Alternatively, a grpc client can be constructed as normal without this helper as the grpc generated client code is still exported. This exists to add utility and helpers around the authentication and passing the token with requests.

                                  type ClientAuthHandler

                                  type ClientAuthHandler interface {
                                  	Authenticate(context.Context, AuthConn) error
                                  	GetToken(context.Context) (string, error)
                                  }

                                    ClientAuthHandler defines an interface for the Flight client to perform the authentication handshake. The token that is retrieved from GetToken will be sent as part of the context metadata in subsequent requests after authentication is performed using the key "auth-token-bin".

                                    type Criteria

                                    type Criteria struct {
                                    	Expression []byte `protobuf:"bytes,1,opt,name=expression,proto3" json:"expression,omitempty"`
                                    	// contains filtered or unexported fields
                                    }

                                      A service specific expression that can be used to return a limited set of available Arrow Flight streams.

                                      func (*Criteria) Descriptor

                                      func (*Criteria) Descriptor() ([]byte, []int)

                                        Deprecated: Use Criteria.ProtoReflect.Descriptor instead.

                                        func (*Criteria) GetExpression

                                        func (x *Criteria) GetExpression() []byte

                                        func (*Criteria) ProtoMessage

                                        func (*Criteria) ProtoMessage()

                                        func (*Criteria) ProtoReflect

                                        func (x *Criteria) ProtoReflect() protoreflect.Message

                                        func (*Criteria) Reset

                                        func (x *Criteria) Reset()

                                        func (*Criteria) String

                                        func (x *Criteria) String() string

                                        type DataStreamReader

                                        type DataStreamReader interface {
                                        	Recv() (*FlightData, error)
                                        }

                                          DataStreamReader is an interface for receiving flight data messages on a stream such as via grpc with Arrow Flight.

                                          type DataStreamWriter

                                          type DataStreamWriter interface {
                                          	Send(*FlightData) error
                                          }

                                            DataStreamWriter is an interface that represents an Arrow Flight stream writer that writes FlightData objects

                                            type Empty

                                            type Empty struct {
                                            	// contains filtered or unexported fields
                                            }

                                            func (*Empty) Descriptor

                                            func (*Empty) Descriptor() ([]byte, []int)

                                              Deprecated: Use Empty.ProtoReflect.Descriptor instead.

                                              func (*Empty) ProtoMessage

                                              func (*Empty) ProtoMessage()

                                              func (*Empty) ProtoReflect

                                              func (x *Empty) ProtoReflect() protoreflect.Message

                                              func (*Empty) Reset

                                              func (x *Empty) Reset()

                                              func (*Empty) String

                                              func (x *Empty) String() string

                                              type FlightData

                                              type FlightData struct {
                                              
                                              	//
                                              	// The descriptor of the data. This is only relevant when a client is
                                              	// starting a new DoPut stream.
                                              	FlightDescriptor *FlightDescriptor `protobuf:"bytes,1,opt,name=flight_descriptor,json=flightDescriptor,proto3" json:"flight_descriptor,omitempty"`
                                              	//
                                              	// Header for message data as described in Message.fbs::Message.
                                              	DataHeader []byte `protobuf:"bytes,2,opt,name=data_header,json=dataHeader,proto3" json:"data_header,omitempty"`
                                              	//
                                              	// Application-defined metadata.
                                              	AppMetadata []byte `protobuf:"bytes,3,opt,name=app_metadata,json=appMetadata,proto3" json:"app_metadata,omitempty"`
                                              	//
                                              	// The actual batch of Arrow data. Preferably handled with minimal-copies
                                              	// coming last in the definition to help with sidecar patterns (it is
                                              	// expected that some implementations will fetch this field off the wire
                                              	// with specialized code to avoid extra memory copies).
                                              	DataBody []byte `protobuf:"bytes,1000,opt,name=data_body,json=dataBody,proto3" json:"data_body,omitempty"`
                                              	// contains filtered or unexported fields
                                              }

                                                A batch of Arrow data as part of a stream of batches.

                                                func (*FlightData) Descriptor

                                                func (*FlightData) Descriptor() ([]byte, []int)

                                                  Deprecated: Use FlightData.ProtoReflect.Descriptor instead.

                                                  func (*FlightData) GetAppMetadata

                                                  func (x *FlightData) GetAppMetadata() []byte

                                                  func (*FlightData) GetDataBody

                                                  func (x *FlightData) GetDataBody() []byte

                                                  func (*FlightData) GetDataHeader

                                                  func (x *FlightData) GetDataHeader() []byte

                                                  func (*FlightData) GetFlightDescriptor

                                                  func (x *FlightData) GetFlightDescriptor() *FlightDescriptor

                                                  func (*FlightData) ProtoMessage

                                                  func (*FlightData) ProtoMessage()

                                                  func (*FlightData) ProtoReflect

                                                  func (x *FlightData) ProtoReflect() protoreflect.Message

                                                  func (*FlightData) Reset

                                                  func (x *FlightData) Reset()

                                                  func (*FlightData) String

                                                  func (x *FlightData) String() string

                                                  type FlightDescriptor

                                                  type FlightDescriptor struct {
                                                  	Type FlightDescriptor_DescriptorType `protobuf:"varint,1,opt,name=type,proto3,enum=arrow.flight.protocol.FlightDescriptor_DescriptorType" json:"type,omitempty"`
                                                  	//
                                                  	// Opaque value used to express a command. Should only be defined when
                                                  	// type = CMD.
                                                  	Cmd []byte `protobuf:"bytes,2,opt,name=cmd,proto3" json:"cmd,omitempty"`
                                                  	//
                                                  	// List of strings identifying a particular dataset. Should only be defined
                                                  	// when type = PATH.
                                                  	Path []string `protobuf:"bytes,3,rep,name=path,proto3" json:"path,omitempty"`
                                                  	// contains filtered or unexported fields
                                                  }

                                                    The name or tag for a Flight. May be used as a way to retrieve or generate a flight or be used to expose a set of previously defined flights.

                                                    func (*FlightDescriptor) Descriptor

                                                    func (*FlightDescriptor) Descriptor() ([]byte, []int)

                                                      Deprecated: Use FlightDescriptor.ProtoReflect.Descriptor instead.

                                                      func (*FlightDescriptor) GetCmd

                                                      func (x *FlightDescriptor) GetCmd() []byte

                                                      func (*FlightDescriptor) GetPath

                                                      func (x *FlightDescriptor) GetPath() []string

                                                      func (*FlightDescriptor) GetType

                                                      func (*FlightDescriptor) ProtoMessage

                                                      func (*FlightDescriptor) ProtoMessage()

                                                      func (*FlightDescriptor) ProtoReflect

                                                      func (x *FlightDescriptor) ProtoReflect() protoreflect.Message

                                                      func (*FlightDescriptor) Reset

                                                      func (x *FlightDescriptor) Reset()

                                                      func (*FlightDescriptor) String

                                                      func (x *FlightDescriptor) String() string

                                                      type FlightDescriptor_DescriptorType

                                                      type FlightDescriptor_DescriptorType int32

                                                        Describes what type of descriptor is defined.

                                                        const (
                                                        	// Protobuf pattern, not used.
                                                        	FlightDescriptor_UNKNOWN FlightDescriptor_DescriptorType = 0
                                                        	//
                                                        	// A named path that identifies a dataset. A path is composed of a string
                                                        	// or list of strings describing a particular dataset. This is conceptually
                                                        	//  similar to a path inside a filesystem.
                                                        	FlightDescriptor_PATH FlightDescriptor_DescriptorType = 1
                                                        	//
                                                        	// An opaque command to generate a dataset.
                                                        	FlightDescriptor_CMD FlightDescriptor_DescriptorType = 2
                                                        )

                                                        func (FlightDescriptor_DescriptorType) Descriptor

                                                        func (FlightDescriptor_DescriptorType) Enum

                                                        func (FlightDescriptor_DescriptorType) EnumDescriptor

                                                        func (FlightDescriptor_DescriptorType) EnumDescriptor() ([]byte, []int)

                                                          Deprecated: Use FlightDescriptor_DescriptorType.Descriptor instead.

                                                          func (FlightDescriptor_DescriptorType) Number

                                                          func (FlightDescriptor_DescriptorType) String

                                                          func (FlightDescriptor_DescriptorType) Type

                                                          type FlightEndpoint

                                                          type FlightEndpoint struct {
                                                          
                                                          	//
                                                          	// Token used to retrieve this stream.
                                                          	Ticket *Ticket `protobuf:"bytes,1,opt,name=ticket,proto3" json:"ticket,omitempty"`
                                                          	//
                                                          	// A list of URIs where this ticket can be redeemed. If the list is
                                                          	// empty, the expectation is that the ticket can only be redeemed on the
                                                          	// current service where the ticket was generated.
                                                          	Location []*Location `protobuf:"bytes,2,rep,name=location,proto3" json:"location,omitempty"`
                                                          	// contains filtered or unexported fields
                                                          }

                                                            A particular stream or split associated with a flight.

                                                            func (*FlightEndpoint) Descriptor

                                                            func (*FlightEndpoint) Descriptor() ([]byte, []int)

                                                              Deprecated: Use FlightEndpoint.ProtoReflect.Descriptor instead.

                                                              func (*FlightEndpoint) GetLocation

                                                              func (x *FlightEndpoint) GetLocation() []*Location

                                                              func (*FlightEndpoint) GetTicket

                                                              func (x *FlightEndpoint) GetTicket() *Ticket

                                                              func (*FlightEndpoint) ProtoMessage

                                                              func (*FlightEndpoint) ProtoMessage()

                                                              func (*FlightEndpoint) ProtoReflect

                                                              func (x *FlightEndpoint) ProtoReflect() protoreflect.Message

                                                              func (*FlightEndpoint) Reset

                                                              func (x *FlightEndpoint) Reset()

                                                              func (*FlightEndpoint) String

                                                              func (x *FlightEndpoint) String() string

                                                              type FlightInfo

                                                              type FlightInfo struct {
                                                              
                                                              	// schema of the dataset as described in Schema.fbs::Schema.
                                                              	Schema []byte `protobuf:"bytes,1,opt,name=schema,proto3" json:"schema,omitempty"`
                                                              	//
                                                              	// The descriptor associated with this info.
                                                              	FlightDescriptor *FlightDescriptor `protobuf:"bytes,2,opt,name=flight_descriptor,json=flightDescriptor,proto3" json:"flight_descriptor,omitempty"`
                                                              	//
                                                              	// A list of endpoints associated with the flight. To consume the whole
                                                              	// flight, all endpoints must be consumed.
                                                              	Endpoint []*FlightEndpoint `protobuf:"bytes,3,rep,name=endpoint,proto3" json:"endpoint,omitempty"`
                                                              	// Set these to -1 if unknown.
                                                              	TotalRecords int64 `protobuf:"varint,4,opt,name=total_records,json=totalRecords,proto3" json:"total_records,omitempty"`
                                                              	TotalBytes   int64 `protobuf:"varint,5,opt,name=total_bytes,json=totalBytes,proto3" json:"total_bytes,omitempty"`
                                                              	// contains filtered or unexported fields
                                                              }

                                                                The access coordinates for retrieval of a dataset. With a FlightInfo, a consumer is able to determine how to retrieve a dataset.

                                                                func (*FlightInfo) Descriptor

                                                                func (*FlightInfo) Descriptor() ([]byte, []int)

                                                                  Deprecated: Use FlightInfo.ProtoReflect.Descriptor instead.

                                                                  func (*FlightInfo) GetEndpoint

                                                                  func (x *FlightInfo) GetEndpoint() []*FlightEndpoint

                                                                  func (*FlightInfo) GetFlightDescriptor

                                                                  func (x *FlightInfo) GetFlightDescriptor() *FlightDescriptor

                                                                  func (*FlightInfo) GetSchema

                                                                  func (x *FlightInfo) GetSchema() []byte

                                                                  func (*FlightInfo) GetTotalBytes

                                                                  func (x *FlightInfo) GetTotalBytes() int64

                                                                  func (*FlightInfo) GetTotalRecords

                                                                  func (x *FlightInfo) GetTotalRecords() int64

                                                                  func (*FlightInfo) ProtoMessage

                                                                  func (*FlightInfo) ProtoMessage()

                                                                  func (*FlightInfo) ProtoReflect

                                                                  func (x *FlightInfo) ProtoReflect() protoreflect.Message

                                                                  func (*FlightInfo) Reset

                                                                  func (x *FlightInfo) Reset()

                                                                  func (*FlightInfo) String

                                                                  func (x *FlightInfo) String() string

                                                                  type FlightServiceClient

                                                                  type FlightServiceClient interface {
                                                                  	//
                                                                  	// Handshake between client and server. Depending on the server, the
                                                                  	// handshake may be required to determine the token that should be used for
                                                                  	// future operations. Both request and response are streams to allow multiple
                                                                  	// round-trips depending on auth mechanism.
                                                                  	Handshake(ctx context.Context, opts ...grpc.CallOption) (FlightService_HandshakeClient, error)
                                                                  	//
                                                                  	// Get a list of available streams given a particular criteria. Most flight
                                                                  	// services will expose one or more streams that are readily available for
                                                                  	// retrieval. This api allows listing the streams available for
                                                                  	// consumption. A user can also provide a criteria. The criteria can limit
                                                                  	// the subset of streams that can be listed via this interface. Each flight
                                                                  	// service allows its own definition of how to consume criteria.
                                                                  	ListFlights(ctx context.Context, in *Criteria, opts ...grpc.CallOption) (FlightService_ListFlightsClient, error)
                                                                  	//
                                                                  	// For a given FlightDescriptor, get information about how the flight can be
                                                                  	// consumed. This is a useful interface if the consumer of the interface
                                                                  	// already can identify the specific flight to consume. This interface can
                                                                  	// also allow a consumer to generate a flight stream through a specified
                                                                  	// descriptor. For example, a flight descriptor might be something that
                                                                  	// includes a SQL statement or a Pickled Python operation that will be
                                                                  	// executed. In those cases, the descriptor will not be previously available
                                                                  	// within the list of available streams provided by ListFlights but will be
                                                                  	// available for consumption for the duration defined by the specific flight
                                                                  	// service.
                                                                  	GetFlightInfo(ctx context.Context, in *FlightDescriptor, opts ...grpc.CallOption) (*FlightInfo, error)
                                                                  	//
                                                                  	// For a given FlightDescriptor, get the Schema as described in Schema.fbs::Schema
                                                                  	// This is used when a consumer needs the Schema of flight stream. Similar to
                                                                  	// GetFlightInfo this interface may generate a new flight that was not previously
                                                                  	// available in ListFlights.
                                                                  	GetSchema(ctx context.Context, in *FlightDescriptor, opts ...grpc.CallOption) (*SchemaResult, error)
                                                                  	//
                                                                  	// Retrieve a single stream associated with a particular descriptor
                                                                  	// associated with the referenced ticket. A Flight can be composed of one or
                                                                  	// more streams where each stream can be retrieved using a separate opaque
                                                                  	// ticket that the flight service uses for managing a collection of streams.
                                                                  	DoGet(ctx context.Context, in *Ticket, opts ...grpc.CallOption) (FlightService_DoGetClient, error)
                                                                  	//
                                                                  	// Push a stream to the flight service associated with a particular
                                                                  	// flight stream. This allows a client of a flight service to upload a stream
                                                                  	// of data. Depending on the particular flight service, a client consumer
                                                                  	// could be allowed to upload a single stream per descriptor or an unlimited
                                                                  	// number. In the latter, the service might implement a 'seal' action that
                                                                  	// can be applied to a descriptor once all streams are uploaded.
                                                                  	DoPut(ctx context.Context, opts ...grpc.CallOption) (FlightService_DoPutClient, error)
                                                                  	//
                                                                  	// Open a bidirectional data channel for a given descriptor. This
                                                                  	// allows clients to send and receive arbitrary Arrow data and
                                                                  	// application-specific metadata in a single logical stream. In
                                                                  	// contrast to DoGet/DoPut, this is more suited for clients
                                                                  	// offloading computation (rather than storage) to a Flight service.
                                                                  	DoExchange(ctx context.Context, opts ...grpc.CallOption) (FlightService_DoExchangeClient, error)
                                                                  	//
                                                                  	// Flight services can support an arbitrary number of simple actions in
                                                                  	// addition to the possible ListFlights, GetFlightInfo, DoGet, DoPut
                                                                  	// operations that are potentially available. DoAction allows a flight client
                                                                  	// to do a specific action against a flight service. An action includes
                                                                  	// opaque request and response objects that are specific to the type action
                                                                  	// being undertaken.
                                                                  	DoAction(ctx context.Context, in *Action, opts ...grpc.CallOption) (FlightService_DoActionClient, error)
                                                                  	//
                                                                  	// A flight service exposes all of the available action types that it has
                                                                  	// along with descriptions. This allows different flight consumers to
                                                                  	// understand the capabilities of the flight service.
                                                                  	ListActions(ctx context.Context, in *Empty, opts ...grpc.CallOption) (FlightService_ListActionsClient, error)
                                                                  }

                                                                    FlightServiceClient is the client API for FlightService service.

                                                                    For semantics around ctx use and closing/ending streaming RPCs, please refer to https://pkg.go.dev/google.golang.org/grpc/?tab=doc#ClientConn.NewStream.

                                                                    type FlightServiceService

                                                                    type FlightServiceService struct {
                                                                    	//
                                                                    	// Handshake between client and server. Depending on the server, the
                                                                    	// handshake may be required to determine the token that should be used for
                                                                    	// future operations. Both request and response are streams to allow multiple
                                                                    	// round-trips depending on auth mechanism.
                                                                    	Handshake func(FlightService_HandshakeServer) error
                                                                    	//
                                                                    	// Get a list of available streams given a particular criteria. Most flight
                                                                    	// services will expose one or more streams that are readily available for
                                                                    	// retrieval. This api allows listing the streams available for
                                                                    	// consumption. A user can also provide a criteria. The criteria can limit
                                                                    	// the subset of streams that can be listed via this interface. Each flight
                                                                    	// service allows its own definition of how to consume criteria.
                                                                    	ListFlights func(*Criteria, FlightService_ListFlightsServer) error
                                                                    	//
                                                                    	// For a given FlightDescriptor, get information about how the flight can be
                                                                    	// consumed. This is a useful interface if the consumer of the interface
                                                                    	// already can identify the specific flight to consume. This interface can
                                                                    	// also allow a consumer to generate a flight stream through a specified
                                                                    	// descriptor. For example, a flight descriptor might be something that
                                                                    	// includes a SQL statement or a Pickled Python operation that will be
                                                                    	// executed. In those cases, the descriptor will not be previously available
                                                                    	// within the list of available streams provided by ListFlights but will be
                                                                    	// available for consumption for the duration defined by the specific flight
                                                                    	// service.
                                                                    	GetFlightInfo func(context.Context, *FlightDescriptor) (*FlightInfo, error)
                                                                    	//
                                                                    	// For a given FlightDescriptor, get the Schema as described in Schema.fbs::Schema
                                                                    	// This is used when a consumer needs the Schema of flight stream. Similar to
                                                                    	// GetFlightInfo this interface may generate a new flight that was not previously
                                                                    	// available in ListFlights.
                                                                    	GetSchema func(context.Context, *FlightDescriptor) (*SchemaResult, error)
                                                                    	//
                                                                    	// Retrieve a single stream associated with a particular descriptor
                                                                    	// associated with the referenced ticket. A Flight can be composed of one or
                                                                    	// more streams where each stream can be retrieved using a separate opaque
                                                                    	// ticket that the flight service uses for managing a collection of streams.
                                                                    	DoGet func(*Ticket, FlightService_DoGetServer) error
                                                                    	//
                                                                    	// Push a stream to the flight service associated with a particular
                                                                    	// flight stream. This allows a client of a flight service to upload a stream
                                                                    	// of data. Depending on the particular flight service, a client consumer
                                                                    	// could be allowed to upload a single stream per descriptor or an unlimited
                                                                    	// number. In the latter, the service might implement a 'seal' action that
                                                                    	// can be applied to a descriptor once all streams are uploaded.
                                                                    	DoPut func(FlightService_DoPutServer) error
                                                                    	//
                                                                    	// Open a bidirectional data channel for a given descriptor. This
                                                                    	// allows clients to send and receive arbitrary Arrow data and
                                                                    	// application-specific metadata in a single logical stream. In
                                                                    	// contrast to DoGet/DoPut, this is more suited for clients
                                                                    	// offloading computation (rather than storage) to a Flight service.
                                                                    	DoExchange func(FlightService_DoExchangeServer) error
                                                                    	//
                                                                    	// Flight services can support an arbitrary number of simple actions in
                                                                    	// addition to the possible ListFlights, GetFlightInfo, DoGet, DoPut
                                                                    	// operations that are potentially available. DoAction allows a flight client
                                                                    	// to do a specific action against a flight service. An action includes
                                                                    	// opaque request and response objects that are specific to the type action
                                                                    	// being undertaken.
                                                                    	DoAction func(*Action, FlightService_DoActionServer) error
                                                                    	//
                                                                    	// A flight service exposes all of the available action types that it has
                                                                    	// along with descriptions. This allows different flight consumers to
                                                                    	// understand the capabilities of the flight service.
                                                                    	ListActions func(*Empty, FlightService_ListActionsServer) error
                                                                    }

                                                                      FlightServiceService is the service API for FlightService service. Fields should be assigned to their respective handler implementations only before RegisterFlightServiceService is called. Any unassigned fields will result in the handler for that method returning an Unimplemented error.

                                                                      func NewFlightServiceService

                                                                      func NewFlightServiceService(s interface{}) *FlightServiceService

                                                                        NewFlightServiceService creates a new FlightServiceService containing the implemented methods of the FlightService service in s. Any unimplemented methods will result in the gRPC server returning an UNIMPLEMENTED status to the client. This includes situations where the method handler is misspelled or has the wrong signature. For this reason, this function should be used with great care and is not recommended to be used by most users.

                                                                        type FlightService_DoActionClient

                                                                        type FlightService_DoActionClient interface {
                                                                        	Recv() (*Result, error)
                                                                        	grpc.ClientStream
                                                                        }

                                                                        type FlightService_DoActionServer

                                                                        type FlightService_DoActionServer interface {
                                                                        	Send(*Result) error
                                                                        	grpc.ServerStream
                                                                        }

                                                                        type FlightService_DoExchangeClient

                                                                        type FlightService_DoExchangeClient interface {
                                                                        	Send(*FlightData) error
                                                                        	Recv() (*FlightData, error)
                                                                        	grpc.ClientStream
                                                                        }

                                                                        type FlightService_DoExchangeServer

                                                                        type FlightService_DoExchangeServer interface {
                                                                        	Send(*FlightData) error
                                                                        	Recv() (*FlightData, error)
                                                                        	grpc.ServerStream
                                                                        }

                                                                        type FlightService_DoGetClient

                                                                        type FlightService_DoGetClient interface {
                                                                        	Recv() (*FlightData, error)
                                                                        	grpc.ClientStream
                                                                        }

                                                                        type FlightService_DoGetServer

                                                                        type FlightService_DoGetServer interface {
                                                                        	Send(*FlightData) error
                                                                        	grpc.ServerStream
                                                                        }

                                                                        type FlightService_DoPutClient

                                                                        type FlightService_DoPutClient interface {
                                                                        	Send(*FlightData) error
                                                                        	Recv() (*PutResult, error)
                                                                        	grpc.ClientStream
                                                                        }

                                                                        type FlightService_DoPutServer

                                                                        type FlightService_DoPutServer interface {
                                                                        	Send(*PutResult) error
                                                                        	Recv() (*FlightData, error)
                                                                        	grpc.ServerStream
                                                                        }

                                                                        type FlightService_HandshakeClient

                                                                        type FlightService_HandshakeClient interface {
                                                                        	Send(*HandshakeRequest) error
                                                                        	Recv() (*HandshakeResponse, error)
                                                                        	grpc.ClientStream
                                                                        }

                                                                        type FlightService_HandshakeServer

                                                                        type FlightService_HandshakeServer interface {
                                                                        	Send(*HandshakeResponse) error
                                                                        	Recv() (*HandshakeRequest, error)
                                                                        	grpc.ServerStream
                                                                        }

                                                                        type FlightService_ListActionsClient

                                                                        type FlightService_ListActionsClient interface {
                                                                        	Recv() (*ActionType, error)
                                                                        	grpc.ClientStream
                                                                        }

                                                                        type FlightService_ListActionsServer

                                                                        type FlightService_ListActionsServer interface {
                                                                        	Send(*ActionType) error
                                                                        	grpc.ServerStream
                                                                        }

                                                                        type FlightService_ListFlightsClient

                                                                        type FlightService_ListFlightsClient interface {
                                                                        	Recv() (*FlightInfo, error)
                                                                        	grpc.ClientStream
                                                                        }

                                                                        type FlightService_ListFlightsServer

                                                                        type FlightService_ListFlightsServer interface {
                                                                        	Send(*FlightInfo) error
                                                                        	grpc.ServerStream
                                                                        }

                                                                        type HandshakeRequest

                                                                        type HandshakeRequest struct {
                                                                        
                                                                        	//
                                                                        	// A defined protocol version
                                                                        	ProtocolVersion uint64 `protobuf:"varint,1,opt,name=protocol_version,json=protocolVersion,proto3" json:"protocol_version,omitempty"`
                                                                        	//
                                                                        	// Arbitrary auth/handshake info.
                                                                        	Payload []byte `protobuf:"bytes,2,opt,name=payload,proto3" json:"payload,omitempty"`
                                                                        	// contains filtered or unexported fields
                                                                        }

                                                                          The request that a client provides to a server on handshake.

                                                                          func (*HandshakeRequest) Descriptor

                                                                          func (*HandshakeRequest) Descriptor() ([]byte, []int)

                                                                            Deprecated: Use HandshakeRequest.ProtoReflect.Descriptor instead.

                                                                            func (*HandshakeRequest) GetPayload

                                                                            func (x *HandshakeRequest) GetPayload() []byte

                                                                            func (*HandshakeRequest) GetProtocolVersion

                                                                            func (x *HandshakeRequest) GetProtocolVersion() uint64

                                                                            func (*HandshakeRequest) ProtoMessage

                                                                            func (*HandshakeRequest) ProtoMessage()

                                                                            func (*HandshakeRequest) ProtoReflect

                                                                            func (x *HandshakeRequest) ProtoReflect() protoreflect.Message

                                                                            func (*HandshakeRequest) Reset

                                                                            func (x *HandshakeRequest) Reset()

                                                                            func (*HandshakeRequest) String

                                                                            func (x *HandshakeRequest) String() string

                                                                            type HandshakeResponse

                                                                            type HandshakeResponse struct {
                                                                            
                                                                            	//
                                                                            	// A defined protocol version
                                                                            	ProtocolVersion uint64 `protobuf:"varint,1,opt,name=protocol_version,json=protocolVersion,proto3" json:"protocol_version,omitempty"`
                                                                            	//
                                                                            	// Arbitrary auth/handshake info.
                                                                            	Payload []byte `protobuf:"bytes,2,opt,name=payload,proto3" json:"payload,omitempty"`
                                                                            	// contains filtered or unexported fields
                                                                            }

                                                                            func (*HandshakeResponse) Descriptor

                                                                            func (*HandshakeResponse) Descriptor() ([]byte, []int)

                                                                              Deprecated: Use HandshakeResponse.ProtoReflect.Descriptor instead.

                                                                              func (*HandshakeResponse) GetPayload

                                                                              func (x *HandshakeResponse) GetPayload() []byte

                                                                              func (*HandshakeResponse) GetProtocolVersion

                                                                              func (x *HandshakeResponse) GetProtocolVersion() uint64

                                                                              func (*HandshakeResponse) ProtoMessage

                                                                              func (*HandshakeResponse) ProtoMessage()

                                                                              func (*HandshakeResponse) ProtoReflect

                                                                              func (x *HandshakeResponse) ProtoReflect() protoreflect.Message

                                                                              func (*HandshakeResponse) Reset

                                                                              func (x *HandshakeResponse) Reset()

                                                                              func (*HandshakeResponse) String

                                                                              func (x *HandshakeResponse) String() string

                                                                              type Location

                                                                              type Location struct {
                                                                              	Uri string `protobuf:"bytes,1,opt,name=uri,proto3" json:"uri,omitempty"`
                                                                              	// contains filtered or unexported fields
                                                                              }

                                                                                A location where a Flight service will accept retrieval of a particular stream given a ticket.

                                                                                func (*Location) Descriptor

                                                                                func (*Location) Descriptor() ([]byte, []int)

                                                                                  Deprecated: Use Location.ProtoReflect.Descriptor instead.

                                                                                  func (*Location) GetUri

                                                                                  func (x *Location) GetUri() string

                                                                                  func (*Location) ProtoMessage

                                                                                  func (*Location) ProtoMessage()

                                                                                  func (*Location) ProtoReflect

                                                                                  func (x *Location) ProtoReflect() protoreflect.Message

                                                                                  func (*Location) Reset

                                                                                  func (x *Location) Reset()

                                                                                  func (*Location) String

                                                                                  func (x *Location) String() string

                                                                                  type PutResult

                                                                                  type PutResult struct {
                                                                                  	AppMetadata []byte `protobuf:"bytes,1,opt,name=app_metadata,json=appMetadata,proto3" json:"app_metadata,omitempty"`
                                                                                  	// contains filtered or unexported fields
                                                                                  }

                                                                                    * The response message associated with the submission of a DoPut.

                                                                                    func (*PutResult) Descriptor

                                                                                    func (*PutResult) Descriptor() ([]byte, []int)

                                                                                      Deprecated: Use PutResult.ProtoReflect.Descriptor instead.

                                                                                      func (*PutResult) GetAppMetadata

                                                                                      func (x *PutResult) GetAppMetadata() []byte

                                                                                      func (*PutResult) ProtoMessage

                                                                                      func (*PutResult) ProtoMessage()

                                                                                      func (*PutResult) ProtoReflect

                                                                                      func (x *PutResult) ProtoReflect() protoreflect.Message

                                                                                      func (*PutResult) Reset

                                                                                      func (x *PutResult) Reset()

                                                                                      func (*PutResult) String

                                                                                      func (x *PutResult) String() string

                                                                                      type Result

                                                                                      type Result struct {
                                                                                      	Body []byte `protobuf:"bytes,1,opt,name=body,proto3" json:"body,omitempty"`
                                                                                      	// contains filtered or unexported fields
                                                                                      }

                                                                                        An opaque result returned after executing an action.

                                                                                        func (*Result) Descriptor

                                                                                        func (*Result) Descriptor() ([]byte, []int)

                                                                                          Deprecated: Use Result.ProtoReflect.Descriptor instead.

                                                                                          func (*Result) GetBody

                                                                                          func (x *Result) GetBody() []byte

                                                                                          func (*Result) ProtoMessage

                                                                                          func (*Result) ProtoMessage()

                                                                                          func (*Result) ProtoReflect

                                                                                          func (x *Result) ProtoReflect() protoreflect.Message

                                                                                          func (*Result) Reset

                                                                                          func (x *Result) Reset()

                                                                                          func (*Result) String

                                                                                          func (x *Result) String() string

                                                                                          type SchemaResult

                                                                                          type SchemaResult struct {
                                                                                          
                                                                                          	// schema of the dataset as described in Schema.fbs::Schema.
                                                                                          	Schema []byte `protobuf:"bytes,1,opt,name=schema,proto3" json:"schema,omitempty"`
                                                                                          	// contains filtered or unexported fields
                                                                                          }

                                                                                            Wrap the result of a getSchema call

                                                                                            func (*SchemaResult) Descriptor

                                                                                            func (*SchemaResult) Descriptor() ([]byte, []int)

                                                                                              Deprecated: Use SchemaResult.ProtoReflect.Descriptor instead.

                                                                                              func (*SchemaResult) GetSchema

                                                                                              func (x *SchemaResult) GetSchema() []byte

                                                                                              func (*SchemaResult) ProtoMessage

                                                                                              func (*SchemaResult) ProtoMessage()

                                                                                              func (*SchemaResult) ProtoReflect

                                                                                              func (x *SchemaResult) ProtoReflect() protoreflect.Message

                                                                                              func (*SchemaResult) Reset

                                                                                              func (x *SchemaResult) Reset()

                                                                                              func (*SchemaResult) String

                                                                                              func (x *SchemaResult) String() string

                                                                                              type Server

                                                                                              type Server interface {
                                                                                              	// Init takes in the address to bind to and creates the listener
                                                                                              	Init(addr string) error
                                                                                              	// Addr will return the address that was bound to for the service to listen on
                                                                                              	Addr() net.Addr
                                                                                              	// SetShutdownOnSignals sets notifications on the given signals to call GracefulStop
                                                                                              	// on the grpc service if any of those signals are received
                                                                                              	SetShutdownOnSignals(sig ...os.Signal)
                                                                                              	// Serve blocks until accepting a connection fails with a fatal error. It will return
                                                                                              	// a non-nil error unless it stopped due to calling Shutdown or receiving one of the
                                                                                              	// signals set in SetShutdownOnSignals
                                                                                              	Serve() error
                                                                                              	// Shutdown will call GracefulStop on the grpc server so that it stops accepting connections
                                                                                              	// and will wait until current methods complete
                                                                                              	Shutdown()
                                                                                              	// RegisterFlightService sets up the handler for the Flight Endpoints as per
                                                                                              	// normal Grpc setups
                                                                                              	RegisterFlightService(*FlightServiceService)
                                                                                              }

                                                                                                Server is an interface for hiding some of the grpc specifics to make it slightly easier to manage a flight service, slightly modeled after the C++ implementation

                                                                                                func NewFlightServer

                                                                                                func NewFlightServer(auth ServerAuthHandler, opt ...grpc.ServerOption) Server

                                                                                                  NewFlightServer takes in an auth handler for managing the handshake authentication and any grpc Server options desired, such as TLS certs and so on which will just be passed through to the underlying grpc server.

                                                                                                  Alternatively, a grpc server can be created normally without this helper as the grpc server generated code is still being exported. This only exists to allow the utility of the helpers

                                                                                                  type ServerAuthHandler

                                                                                                  type ServerAuthHandler interface {
                                                                                                  	Authenticate(AuthConn) error
                                                                                                  	IsValid(token string) (interface{}, error)
                                                                                                  }

                                                                                                    ServerAuthHandler defines an interface for the server to perform the handshake. The token is expected to be sent as part of the context metadata in subsequent requests with a key of "auth-token-bin" which will then call IsValid to validate

                                                                                                    type Ticket

                                                                                                    type Ticket struct {
                                                                                                    	Ticket []byte `protobuf:"bytes,1,opt,name=ticket,proto3" json:"ticket,omitempty"`
                                                                                                    	// contains filtered or unexported fields
                                                                                                    }

                                                                                                      An opaque identifier that the service can use to retrieve a particular portion of a stream.

                                                                                                      func (*Ticket) Descriptor

                                                                                                      func (*Ticket) Descriptor() ([]byte, []int)

                                                                                                        Deprecated: Use Ticket.ProtoReflect.Descriptor instead.

                                                                                                        func (*Ticket) GetTicket

                                                                                                        func (x *Ticket) GetTicket() []byte

                                                                                                        func (*Ticket) ProtoMessage

                                                                                                        func (*Ticket) ProtoMessage()

                                                                                                        func (*Ticket) ProtoReflect

                                                                                                        func (x *Ticket) ProtoReflect() protoreflect.Message

                                                                                                        func (*Ticket) Reset

                                                                                                        func (x *Ticket) Reset()

                                                                                                        func (*Ticket) String

                                                                                                        func (x *Ticket) String() string

                                                                                                        type UnstableFlightServiceService

                                                                                                        type UnstableFlightServiceService interface {
                                                                                                        	//
                                                                                                        	// Handshake between client and server. Depending on the server, the
                                                                                                        	// handshake may be required to determine the token that should be used for
                                                                                                        	// future operations. Both request and response are streams to allow multiple
                                                                                                        	// round-trips depending on auth mechanism.
                                                                                                        	Handshake(FlightService_HandshakeServer) error
                                                                                                        	//
                                                                                                        	// Get a list of available streams given a particular criteria. Most flight
                                                                                                        	// services will expose one or more streams that are readily available for
                                                                                                        	// retrieval. This api allows listing the streams available for
                                                                                                        	// consumption. A user can also provide a criteria. The criteria can limit
                                                                                                        	// the subset of streams that can be listed via this interface. Each flight
                                                                                                        	// service allows its own definition of how to consume criteria.
                                                                                                        	ListFlights(*Criteria, FlightService_ListFlightsServer) error
                                                                                                        	//
                                                                                                        	// For a given FlightDescriptor, get information about how the flight can be
                                                                                                        	// consumed. This is a useful interface if the consumer of the interface
                                                                                                        	// already can identify the specific flight to consume. This interface can
                                                                                                        	// also allow a consumer to generate a flight stream through a specified
                                                                                                        	// descriptor. For example, a flight descriptor might be something that
                                                                                                        	// includes a SQL statement or a Pickled Python operation that will be
                                                                                                        	// executed. In those cases, the descriptor will not be previously available
                                                                                                        	// within the list of available streams provided by ListFlights but will be
                                                                                                        	// available for consumption for the duration defined by the specific flight
                                                                                                        	// service.
                                                                                                        	GetFlightInfo(context.Context, *FlightDescriptor) (*FlightInfo, error)
                                                                                                        	//
                                                                                                        	// For a given FlightDescriptor, get the Schema as described in Schema.fbs::Schema
                                                                                                        	// This is used when a consumer needs the Schema of flight stream. Similar to
                                                                                                        	// GetFlightInfo this interface may generate a new flight that was not previously
                                                                                                        	// available in ListFlights.
                                                                                                        	GetSchema(context.Context, *FlightDescriptor) (*SchemaResult, error)
                                                                                                        	//
                                                                                                        	// Retrieve a single stream associated with a particular descriptor
                                                                                                        	// associated with the referenced ticket. A Flight can be composed of one or
                                                                                                        	// more streams where each stream can be retrieved using a separate opaque
                                                                                                        	// ticket that the flight service uses for managing a collection of streams.
                                                                                                        	DoGet(*Ticket, FlightService_DoGetServer) error
                                                                                                        	//
                                                                                                        	// Push a stream to the flight service associated with a particular
                                                                                                        	// flight stream. This allows a client of a flight service to upload a stream
                                                                                                        	// of data. Depending on the particular flight service, a client consumer
                                                                                                        	// could be allowed to upload a single stream per descriptor or an unlimited
                                                                                                        	// number. In the latter, the service might implement a 'seal' action that
                                                                                                        	// can be applied to a descriptor once all streams are uploaded.
                                                                                                        	DoPut(FlightService_DoPutServer) error
                                                                                                        	//
                                                                                                        	// Open a bidirectional data channel for a given descriptor. This
                                                                                                        	// allows clients to send and receive arbitrary Arrow data and
                                                                                                        	// application-specific metadata in a single logical stream. In
                                                                                                        	// contrast to DoGet/DoPut, this is more suited for clients
                                                                                                        	// offloading computation (rather than storage) to a Flight service.
                                                                                                        	DoExchange(FlightService_DoExchangeServer) error
                                                                                                        	//
                                                                                                        	// Flight services can support an arbitrary number of simple actions in
                                                                                                        	// addition to the possible ListFlights, GetFlightInfo, DoGet, DoPut
                                                                                                        	// operations that are potentially available. DoAction allows a flight client
                                                                                                        	// to do a specific action against a flight service. An action includes
                                                                                                        	// opaque request and response objects that are specific to the type action
                                                                                                        	// being undertaken.
                                                                                                        	DoAction(*Action, FlightService_DoActionServer) error
                                                                                                        	//
                                                                                                        	// A flight service exposes all of the available action types that it has
                                                                                                        	// along with descriptions. This allows different flight consumers to
                                                                                                        	// understand the capabilities of the flight service.
                                                                                                        	ListActions(*Empty, FlightService_ListActionsServer) error
                                                                                                        }

                                                                                                          UnstableFlightServiceService is the service API for FlightService service. New methods may be added to this interface if they are added to the service definition, which is not a backward-compatible change. For this reason, use of this type is not recommended.