Skip to main content

Hyperf 多路复用 RPC 组件 Python 版本

Project description

Hyperf 多路复用 RPC 组件 Python 版本

如何使用

import asyncio

from roc.request import Request
from roc.socket import Client


async def main():
    client = Client(host="127.0.0.1", port=9502)
    while True:
        req = Request(path="/test/test",
                      params={"mobile": "123123", "data": "HelloWorld"})
        res = await client.request(req)
        print(res.result)
        await asyncio.sleep(1)


if __name__ == '__main__':
    asyncio.run(main())

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

roc_py-0.1.0.tar.gz (4.4 kB view details)

Uploaded Source

File details

Details for the file roc_py-0.1.0.tar.gz.

File metadata

  • Download URL: roc_py-0.1.0.tar.gz
  • Upload date:
  • Size: 4.4 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/5.1.1 CPython/3.12.7

File hashes

Hashes for roc_py-0.1.0.tar.gz
Algorithm Hash digest
SHA256 f0c198d8069bd03a4122d64784ccae40d84e334e31aa321e0999f53beb9b90c3
MD5 9cbbdd59b9deb58a7adaf79434c9376b
BLAKE2b-256 6d6c08961911dd85502aabd733ef4d68b0a03bcea4cd3a0d2fdcb0c096154984

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