Skip to main content

FastAPI and Arrow Flight integrated server offering efficient dual-protocol support for both REST and gRPC data streaming.

Project description

FastFlight

FastFlight is a high-performance framework for fetching and transferring data from multiple data sources using * Apache Arrow Flight*. It focuses on improving data transfer efficiency, particularly in scenarios requiring large-scale data retrieval, by using Arrow's columnar data format and gRPC for efficient streaming.


Features

  • Pluggable Data Services: Easily add support for different data sources (SQL, cloud, data lakes) through a modular service architecture.
  • Efficient Data Transfer: By using Arrow Flight, FastFlight reduces the overhead of traditional data transfer methods (JDBC/ODBC), improving performance across networks.
  • Asynchronous and Synchronous Support: The project supports both asynchronous data processing and synchronous interfaces, making it flexible for various use cases.
  • FastAPI Integration (Optional): Serve data via HTTP APIs with minimal latency using FastAPI, allowing you to expose your Flight server functionalities through a web interface.

Benefits of Using Arrow Flight

  • High Performance: Arrow Flight leverages the columnar format of Apache Arrow, which allows for more efficient data transport, especially in large datasets.
  • Low Latency: The use of gRPC streaming ensures efficient network communication, reducing round-trip time and enabling real-time data transfer.
  • Pluggable Architecture: Easy to integrate new data sources by extending base classes for params and data services.

Core Components

  • Flight Server: Manages incoming requests, dispatches to the appropriate data service, and streams results using Apache Arrow.
  • Flight Client: Fetches data from the Flight server and deserializes it into user-friendly formats like Pandas DataFrames or PyArrow Tables.
  • Data Services: Modular system for retrieving data from various data sources with support for asynchronous data streaming.

Installation

  1. Clone the repository:
    git clone https://github.com/cning112/fastflight
    cd fastflight
    
  2. Install dependencies:
    pip install -r requirements.txt
    

Basic Usage

  1. Start the Flight server:
    python src/fastflight/flight_server.py
    
  2. Use the Flight client to fetch data:
    from fastflight.flight_client import FlightClientManager
    # Connect to Flight server and fetch data
    

FastAPI Integration

For more information on how to integrate with FastAPI, refer to the FastAPI Integration Guide.


Technical Details

For in-depth technical discussions on the architecture, data service design, and utility functions (e.g., AsyncToSyncConverter, streaming utils), refer to the Technical Documentation.


License

This project is licensed under the MIT License.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

fastflight-0.2.2.tar.gz (26.2 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

fastflight-0.2.2-py3-none-any.whl (20.0 kB view details)

Uploaded Python 3

File details

Details for the file fastflight-0.2.2.tar.gz.

File metadata

  • Download URL: fastflight-0.2.2.tar.gz
  • Upload date:
  • Size: 26.2 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/5.1.1 CPython/3.9.20

File hashes

Hashes for fastflight-0.2.2.tar.gz
Algorithm Hash digest
SHA256 33e602464dd60543fa32ca81eba9ab4fcbc2ed6b8c4040e9a606d7b6a644f62e
MD5 e98300fde196987960a1e512c3cc4121
BLAKE2b-256 0c575c68c20265907eec718b912e21394717ec5268800a886b98f177177a0084

See more details on using hashes here.

File details

Details for the file fastflight-0.2.2-py3-none-any.whl.

File metadata

  • Download URL: fastflight-0.2.2-py3-none-any.whl
  • Upload date:
  • Size: 20.0 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/5.1.1 CPython/3.9.20

File hashes

Hashes for fastflight-0.2.2-py3-none-any.whl
Algorithm Hash digest
SHA256 2e30a56fe5bdce59b30705f27e2d8b2a03258946e7d76534d516da5adc8d30df
MD5 f1b9c17da224d4e251f9b90babcab038
BLAKE2b-256 a94ea0f80b99f6311a55383af134023dce701ef2cad95454826d8f269c309789

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page