Skip to main content

fastDeploy python client

Project description

fastDeploy python client

from fdclient import FDClient

client = FDClient('http://localhost:8080') # optional compression=False to disable zstd compression

# infer
response = client.infer([obj_1, obj_2, ...]) # optional unique_id='some_id' to specify a unique id for the request

# infer in background
response_future = client.infer_background([obj_1, obj_2, ...]) # optional unique_id='some_id' to specify a unique id for the request
response = response_future.result() # wait for the response and get it
  • By default fdclient communicates with fastDeploy server via pickles
  • pickle is very useful and makes sense when using fastDeploy server as a micro service internally i.e: all requests to fastDeploy originate from code you have writtem
  • PICKLE is secure if all the inputs to fastDeploy are originating from your code and not direct external user's pickles
  • PICKLE is unsecure if you are passing external user inputs to fastDeploy directly without validation in between
  • start fastDeploy serve with --config "allow_pickle=false" if the fastDeploy APIs are exposed to outside
  • allow_pickle=false config on server side makes fdclient use msgpack if available or json if msgpack not available.

If pickle is unsecure, why use it at all?

  • pickle is great to send or receive arbitary inputs and outputs
  • if allow_pickle=true (default) your inputs and outputs can be any python objects, eg: np arrays, pd dataframes, float32 anything ....
  • pickle is only unsecure if you are unpickling objects pickled by others (since they can insert malicious code)
  • If fastDeploy is being used only for internal microservices, pickle is the best way so enabled by default

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

fdclient-3.1.2.tar.gz (4.8 kB view details)

Uploaded Source

Built Distribution

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

fdclient-3.1.2-py3-none-any.whl (3.9 kB view details)

Uploaded Python 3

File details

Details for the file fdclient-3.1.2.tar.gz.

File metadata

  • Download URL: fdclient-3.1.2.tar.gz
  • Upload date:
  • Size: 4.8 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.13.7

File hashes

Hashes for fdclient-3.1.2.tar.gz
Algorithm Hash digest
SHA256 65862c5c2decc8bd13ccff8cf4a5b01efce98216f3298cd1561e92e7172c118e
MD5 de19515a3ee35b574d23afc797796fd3
BLAKE2b-256 2aaa84dd533d3f2594bd75c9022bf8bfe6e446309ceb8e791bacf94820eb90d0

See more details on using hashes here.

Provenance

The following attestation bundles were made for fdclient-3.1.2.tar.gz:

Publisher: python_client.yml on notAI-tech/fastDeploy

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file fdclient-3.1.2-py3-none-any.whl.

File metadata

  • Download URL: fdclient-3.1.2-py3-none-any.whl
  • Upload date:
  • Size: 3.9 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.13.7

File hashes

Hashes for fdclient-3.1.2-py3-none-any.whl
Algorithm Hash digest
SHA256 20289e3434e31dfbfe7c21488f81edbee3ae3458e57c4d34d4eaa2d7211ca1fc
MD5 5a9746e03a68b5a222a64b96fa547c11
BLAKE2b-256 4bb4f99d557b9d74abd4cfd835764346f9350a0e67962fec4ba12c105b188266

See more details on using hashes here.

Provenance

The following attestation bundles were made for fdclient-3.1.2-py3-none-any.whl:

Publisher: python_client.yml on notAI-tech/fastDeploy

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

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