Skip to main content

No project description provided

Project description

dataflow-sdk

Example

from datetime import datetime

from dataflow_sdk import save_items, Record
from dataflow_sdk.entity.model import SinkType

result = {
    'name': 'xiaoming',
    "age": 25,
    "time": datetime.now().strftime("%Y-%m-%d %H:%M:%S"),
    "hello": "world",
    "world": 1121211
}

records = [Record(
    parent_url="https://www.json.cn",
    sink_type=SinkType.ITEM,
    store_key=f"https://www.json.cn{x}/",
    data=result,
    metadata={"name": "gage"},
) for x in range(10)]

save_items('77963b7a931377ad4ab5ad6a9cd718aa', records)

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

dataflow_sdk-0.1.7.tar.gz (7.4 kB view details)

Uploaded Source

Built Distribution

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

dataflow_sdk-0.1.7-py3-none-any.whl (13.2 kB view details)

Uploaded Python 3

File details

Details for the file dataflow_sdk-0.1.7.tar.gz.

File metadata

  • Download URL: dataflow_sdk-0.1.7.tar.gz
  • Upload date:
  • Size: 7.4 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: poetry/2.1.3 CPython/3.10.18 Linux/4.4.0-22621-Microsoft

File hashes

Hashes for dataflow_sdk-0.1.7.tar.gz
Algorithm Hash digest
SHA256 3fadbd256b594f79ac53450b055490dedee526ae664b46f154783547acb24e74
MD5 9c256c0cf1169e9df2e46c2d3f826cbf
BLAKE2b-256 b3890b01fb6f7d132b82091d108a1b946f25ad47a122567d0e8b13a5070ac2c1

See more details on using hashes here.

File details

Details for the file dataflow_sdk-0.1.7-py3-none-any.whl.

File metadata

  • Download URL: dataflow_sdk-0.1.7-py3-none-any.whl
  • Upload date:
  • Size: 13.2 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: poetry/2.1.3 CPython/3.10.18 Linux/4.4.0-22621-Microsoft

File hashes

Hashes for dataflow_sdk-0.1.7-py3-none-any.whl
Algorithm Hash digest
SHA256 9505025debb94786bee3d184ff158c62647837a761ef1658d30c23f759f9adde
MD5 be8e1e76d91183a42a66390135ea935e
BLAKE2b-256 731449ab040636cf18dacfdd87cfa77efbef6f3192e4727b4fc763d90da69bae

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