Http to thrift protocol conversion
Project description
Use http client to call thrift services.
Example
App config:
# app.yaml
app_name: http_app
port: 1991
app: http_app:app
thrift_file: ping.thrift
thrift_protocol_class: takumi_http.protocol.HttpProtocol
App code:
# http_app.py
from takumi_service.service import ServiceHandler
app = ServiceHandler('PingService')
@app.api
def ping():
return 'pong'
Start the service using takumi-cli.
$ takumi serve
Then open http://localhost:1991/ping in your brower.
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
takumi_http-0.1.0.tar.gz
(8.5 kB
view hashes)
Built Distribution
Close
Hashes for takumi_http-0.1.0-py2.py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | a6cf7c0e43e978d15d56ef0a3661c8093a56491d4be58493ea2a7070b10ec221 |
|
MD5 | 8da3385eb2be31a61a3d4aa951cf7ea2 |
|
BLAKE2b-256 | 4cb37e44cdba27a01ed026cab4620660e263e04a1a37fee6f5b879bbcc8bf40d |