syncstream


Namesyncstream JSON
Version 1.2.0 PyPI version JSON
download
home_pagehttps://github.com/cainmagi/sync-stream
SummaryA python tool for synchronize the messages from different threads, processes or hosts.
upload_time2024-02-27 19:21:39
maintainerYuchen Jin
docs_urlNone
authorYuchen Jin
requires_python>=3.6
licenseMIT
keywords python python3 python-library stdout stdout-redirection multiprocessing synchronization stream
VCS
bugtrack_url
requirements No requirements were recorded.
Travis-CI No Travis.
coveralls test coverage No coveralls.
            # Sync-stream

This project is designed for providing the synchoronization of the stdout / stderr among different threads, processes, devices or hosts. The package could be used for the following cases:

1. Use `syncstream.LineBuffer`: Multiple threads are created. The messages (stdout) from different threads are required to be collected.
2. Use `syncstream.LineProcBuffer` in the main process, and `syncstream.LineProcMirror` in the sub-processes: Multiple sub-processes are created on the same device. The stdout / stderr of each process is redirected to a `LineProcMirror`, and the results are collected by `LineProcBuffer`.
3. Use `syncstream.LineFileBuffer`: Multiple processes are created. These processes may be deployed on different devices (even with different platforms), but all devices could get accessed to the same shared disk. In this case, the message could be shared by locked files. Each process would hold an independent `LineFileBuffer` pointing to the same log files.
4. Use `syncstream.LineHostBuffer` on the server side, and `syncstream.LineHostMirror` on the client side: Multiple processes are deployed on different devices, and they could not share the same disk. In this case, the message are synchronized by the web service. Each process would hold a `LineHostMirror`, and the results would be collected by `LineHostBuffer`.

The basic package would not contain the `file` and `host` modules. To install the package, please use the following options:

```bash
pip install syncstream[option1,option2...]
```

| Option  | Supports |
| :-----: | :------- |
| `file` | Install dependencies for the `file` module. The module provides `syncstream.LineFileBuffer`. |
| `host` | Install dependencies for the `host` module. The module provides `syncstream.LineHostBuffer`, and `syncstream.LineHostMirror`. |
| `test` | Install dependencies for running tests. |
| `dev`  | Install dependencies for developers. |

## Documentation

View the documentation here: [:blue_book: https://cainmagi.github.io/sync-stream/](https://cainmagi.github.io/sync-stream/)

## Update reports

See the versions in the [CHANGELOG :spiral_notepad:](./CHANGELOG.md) file.

            

Raw data

            {
    "_id": null,
    "home_page": "https://github.com/cainmagi/sync-stream",
    "name": "syncstream",
    "maintainer": "Yuchen Jin",
    "docs_url": null,
    "requires_python": ">=3.6",
    "maintainer_email": "cainmagi@gmail.com",
    "keywords": "python,python3,python-library,stdout,stdout-redirection,multiprocessing,synchronization,stream",
    "author": "Yuchen Jin",
    "author_email": "cainmagi@gmail.com",
    "download_url": "https://files.pythonhosted.org/packages/38/6f/e9c728f68555b5e866c884c93236893215b042b59efda588a6f62ac595e6/syncstream-1.2.0.tar.gz",
    "platform": null,
    "description": "# Sync-stream\n\nThis project is designed for providing the synchoronization of the stdout / stderr among different threads, processes, devices or hosts. The package could be used for the following cases:\n\n1. Use `syncstream.LineBuffer`: Multiple threads are created. The messages (stdout) from different threads are required to be collected.\n2. Use `syncstream.LineProcBuffer` in the main process, and `syncstream.LineProcMirror` in the sub-processes: Multiple sub-processes are created on the same device. The stdout / stderr of each process is redirected to a `LineProcMirror`, and the results are collected by `LineProcBuffer`.\n3. Use `syncstream.LineFileBuffer`: Multiple processes are created. These processes may be deployed on different devices (even with different platforms), but all devices could get accessed to the same shared disk. In this case, the message could be shared by locked files. Each process would hold an independent `LineFileBuffer` pointing to the same log files.\n4. Use `syncstream.LineHostBuffer` on the server side, and `syncstream.LineHostMirror` on the client side: Multiple processes are deployed on different devices, and they could not share the same disk. In this case, the message are synchronized by the web service. Each process would hold a `LineHostMirror`, and the results would be collected by `LineHostBuffer`.\n\nThe basic package would not contain the `file` and `host` modules. To install the package, please use the following options:\n\n```bash\npip install syncstream[option1,option2...]\n```\n\n| Option  | Supports |\n| :-----: | :------- |\n| `file` | Install dependencies for the `file` module. The module provides `syncstream.LineFileBuffer`. |\n| `host` | Install dependencies for the `host` module. The module provides `syncstream.LineHostBuffer`, and `syncstream.LineHostMirror`. |\n| `test` | Install dependencies for running tests. |\n| `dev`  | Install dependencies for developers. |\n\n## Documentation\n\nView the documentation here: [:blue_book: https://cainmagi.github.io/sync-stream/](https://cainmagi.github.io/sync-stream/)\n\n## Update reports\n\nSee the versions in the [CHANGELOG :spiral_notepad:](./CHANGELOG.md) file.\n",
    "bugtrack_url": null,
    "license": "MIT",
    "summary": "A python tool for synchronize the messages from different threads, processes or hosts.",
    "version": "1.2.0",
    "project_urls": {
        "Bug Tracker": "https://github.com/cainmagi/sync-stream/issues",
        "Documentation": "https://cainmagi.github.io/sync-stream/",
        "Homepage": "https://github.com/cainmagi/sync-stream"
    },
    "split_keywords": [
        "python",
        "python3",
        "python-library",
        "stdout",
        "stdout-redirection",
        "multiprocessing",
        "synchronization",
        "stream"
    ],
    "urls": [
        {
            "comment_text": "",
            "digests": {
                "blake2b_256": "a11178b061de72deeae6c33175513f756da79ec6bd15f20e3c0142e874b133ff",
                "md5": "5cfb6a2e5e2375b395c7f57f812396e4",
                "sha256": "8456022911416a033525ea0d546a9ba3f0b50c6a74483d7cd25b77d166e2ed99"
            },
            "downloads": -1,
            "filename": "syncstream-1.2.0-py3-none-any.whl",
            "has_sig": false,
            "md5_digest": "5cfb6a2e5e2375b395c7f57f812396e4",
            "packagetype": "bdist_wheel",
            "python_version": "py3",
            "requires_python": ">=3.6",
            "size": 33518,
            "upload_time": "2024-02-27T19:21:37",
            "upload_time_iso_8601": "2024-02-27T19:21:37.518318Z",
            "url": "https://files.pythonhosted.org/packages/a1/11/78b061de72deeae6c33175513f756da79ec6bd15f20e3c0142e874b133ff/syncstream-1.2.0-py3-none-any.whl",
            "yanked": false,
            "yanked_reason": null
        },
        {
            "comment_text": "",
            "digests": {
                "blake2b_256": "386fe9c728f68555b5e866c884c93236893215b042b59efda588a6f62ac595e6",
                "md5": "0537ef7cf4c6b23bf6fd4f4c4347d8e8",
                "sha256": "dfffbc13c136821994362cc2627cd78f2502a538c1e5a47dd75a8cf87e88d792"
            },
            "downloads": -1,
            "filename": "syncstream-1.2.0.tar.gz",
            "has_sig": false,
            "md5_digest": "0537ef7cf4c6b23bf6fd4f4c4347d8e8",
            "packagetype": "sdist",
            "python_version": "source",
            "requires_python": ">=3.6",
            "size": 36456,
            "upload_time": "2024-02-27T19:21:39",
            "upload_time_iso_8601": "2024-02-27T19:21:39.213740Z",
            "url": "https://files.pythonhosted.org/packages/38/6f/e9c728f68555b5e866c884c93236893215b042b59efda588a6f62ac595e6/syncstream-1.2.0.tar.gz",
            "yanked": false,
            "yanked_reason": null
        }
    ],
    "upload_time": "2024-02-27 19:21:39",
    "github": true,
    "gitlab": false,
    "bitbucket": false,
    "codeberg": false,
    "github_user": "cainmagi",
    "github_project": "sync-stream",
    "travis_ci": false,
    "coveralls": false,
    "github_actions": true,
    "requirements": [],
    "lcname": "syncstream"
}
        
Elapsed time: 0.18898s