flight

package
v0.0.0-...-056b33b Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Feb 18, 2023 License: MIT Imports: 12 Imported by: 0

README

Apache Arrow Flight Data Connector

The Flight data connector will query and fetch data from an Apache Flight endpoint.

Supported parameters

  • sql [Required] File or string containing a SQL query to execute.
  • username [Optional] Username for authentication (omit with password if no auth).
  • password [Optional] Password for authentication (omit with username if no auth).

Example Dataspace

dataspaces:
  - from: spice
    name: sql
    identifiers:
      - name: number
    measurements:
      - name: gas_used
    data:
      connector:
        name: flight
        params:
          password: <api_key>
          sql: SELECT number, timestamp, gas_used FROM eth.recent_blocks ORDER BY number DESC
      processor:
        name: arrow
        params:
          time_selector: timestamp

Documentation

Index

Constants

View Source
const (
	FlightConnectorName string = "flight"
)

Variables

This section is empty.

Functions

This section is empty.

Types

type FlightConnector

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

func NewFlightConnector

func NewFlightConnector() *FlightConnector

func (*FlightConnector) Init

func (c *FlightConnector) Init(epoch time.Time, period time.Duration, interval time.Duration, params map[string]string) error

func (*FlightConnector) Read

func (c *FlightConnector) Read(handler func(data []byte, metadata map[string]string) ([]byte, error)) error

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL