FastAPI and Arrow Flight integrated server offering efficient dual-protocol support for both REST and gRPC data streaming.
Project description
FastFlight
FastAPI + Arrow Flight Server
Introduction
This project integrates a FastAPI server with an embedded Arrow Flight server, offering a dual-protocol solution for handling both HTTP REST and gRPC requests efficiently.
- FastAPI Server: Provides a robust and high-performance HTTP REST service.
- Arrow Flight Server: Embedded within the FastAPI application, it directly handles gRPC requests, enabling fast and scalable data retrieval.
- REST to Flight Integration: A specialized REST endpoint forwards data requests to the Arrow Flight server, streaming the data back to the client seamlessly.
How does it work?
With FastAPI
- Run the flight server and the FastAPI server in separate processes
- Test by posting query params to the /fastflight/ endpoint
Without FastAPI
- RUn the flight server
- Test by posting flight ticket to the flight server endpoint.
- Or, use the flight_client to help with the data retrieval.
How to add a new data source type?
- Add a new data source type to the enum in
models/data_source - Add a new params class in
models/params. Make sure the new params class is registered with the new data source type - Add a new data service to handle the new params
Better logging
See src/fastflight/utils/custom_logging.py
Development Settings
- Create a venv
pip install -r requirements.txtuvicorn fastflight.main:app --reload --app-dir src
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file fastflight-0.2.1.tar.gz.
File metadata
- Download URL: fastflight-0.2.1.tar.gz
- Upload date:
- Size: 19.6 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/5.1.1 CPython/3.9.20
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
e37a942079bddbe1290962c7a494b7ced77c3f04c615964b4dfb319bd85fa08b
|
|
| MD5 |
147c1eace1142b3e02da3bcca682f94c
|
|
| BLAKE2b-256 |
c2224a8ece4f525c4f6bb411d84f5fa622943af52c28431c893064fc19128f48
|
File details
Details for the file fastflight-0.2.1-py3-none-any.whl.
File metadata
- Download URL: fastflight-0.2.1-py3-none-any.whl
- Upload date:
- Size: 17.8 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/5.1.1 CPython/3.9.20
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
7a568ef57eb42bc3cedb6afb568ca44cd7a94d9530d57b8e044974c85e1df011
|
|
| MD5 |
6e71768eb0e3d1b8f1c98498970661cf
|
|
| BLAKE2b-256 |
96cc98308c8f83969df3be0e92378fe8c74ac8fa09dde5592721185c35b71bdc
|