persistentidgenerator


Namepersistentidgenerator JSON
Version 1.1.5 PyPI version JSON
download
home_pagehttps://github.com/debmishra-daedal/stormwind/persistentidgenerator
SummaryThis packages allows creating squential ids for financial entities. It's a fairly simple program that allocates 1 billion ids for each entity.
upload_time2024-09-18 23:33:10
maintainerNone
docs_urlNone
authorDeb Mishra
requires_python<4.0,>=3.11
licenseGNU General Public License v3.0
keywords guid uniqueid uuid sequentialid
VCS
bugtrack_url
requirements No requirements were recorded.
Travis-CI No Travis.
coveralls test coverage No coveralls.
            # Sequential ID Generator

This Python program provides a robust solution for generating sequential IDs for various entities. It supports up to a billion IDs per entity with the option to expand further. Additionally, it allows for the deletion and reuse of IDs.

## Features

1. **ID Allocation**: Allocate up to a billion IDs per entity with the option to expand.
2. **Entity Selection**: Choose from the following entities for ID generation:
   - `fx`: 1 (fx)
   - `prices`: 2 (hp)
   - `static`: 3 (sec)
   - `index`: 4 (idx)
   - `benchmarks`: 5 (bmrk)
   - `holdings`: 6 (hld)
   - `portfolio`: 7 (por)
   - `entity`: 8 (ent)
   - `other`:0 (oth)
3. **ID Deletion and Reuse**: Option to delete an ID and have it reused.

## Installation

  Ensure that you have SLITE_DB_PATH environment variable set. If not it'll store in profile and wont be persistent
  if you have concurrent users.

## Usage

It has a class and multiple methods

1. **Classes**

    - `guidgen` : All methods of the program are written here

2. **Methods**

    - `generate_id()` : Creates the sqlite database for persistent storage
    - `drop_id()` : Checks if the table exists
    - `logger()` : Creates new table, if table doesn't exist in database

3. **Examples**

    - ***get a unique master id*** - guidgen.generate_id("fx").masterId
    - ***get a unique numeric id*** - guidgen.generate_id("fx").numericId
    - ***drop a numeric id*** - guidgen.drop_id(21,"fx")
    - ***get a log details*** - guidgen.generate_id("fx").logOuput.stdout_log/stderr_log

## Contributing

Contributions are welcome! Please fork the repository and submit a pull request.

## License

This project is licensed under the MIT License. See the LICENSE file for details.

## Contact

For any questions or suggestions, please contact <email@debmishra.me>.

            

Raw data

            {
    "_id": null,
    "home_page": "https://github.com/debmishra-daedal/stormwind/persistentidgenerator",
    "name": "persistentidgenerator",
    "maintainer": null,
    "docs_url": null,
    "requires_python": "<4.0,>=3.11",
    "maintainer_email": null,
    "keywords": "guid, uniqueid, uuid, sequentialid",
    "author": "Deb Mishra",
    "author_email": "email@debmishra.me",
    "download_url": "https://files.pythonhosted.org/packages/c9/a5/0af2298c2606de04ca49940f75d9f9f0073779222b0556878e69c8259d5a/persistentidgenerator-1.1.5.tar.gz",
    "platform": null,
    "description": "# Sequential ID Generator\n\nThis Python program provides a robust solution for generating sequential IDs for various entities. It supports up to a billion IDs per entity with the option to expand further. Additionally, it allows for the deletion and reuse of IDs.\n\n## Features\n\n1. **ID Allocation**: Allocate up to a billion IDs per entity with the option to expand.\n2. **Entity Selection**: Choose from the following entities for ID generation:\n   - `fx`: 1 (fx)\n   - `prices`: 2 (hp)\n   - `static`: 3 (sec)\n   - `index`: 4 (idx)\n   - `benchmarks`: 5 (bmrk)\n   - `holdings`: 6 (hld)\n   - `portfolio`: 7 (por)\n   - `entity`: 8 (ent)\n   - `other`:0 (oth)\n3. **ID Deletion and Reuse**: Option to delete an ID and have it reused.\n\n## Installation\n\n  Ensure that you have SLITE_DB_PATH environment variable set. If not it'll store in profile and wont be persistent\n  if you have concurrent users.\n\n## Usage\n\nIt has a class and multiple methods\n\n1. **Classes**\n\n    - `guidgen` : All methods of the program are written here\n\n2. **Methods**\n\n    - `generate_id()` : Creates the sqlite database for persistent storage\n    - `drop_id()` : Checks if the table exists\n    - `logger()` : Creates new table, if table doesn't exist in database\n\n3. **Examples**\n\n    - ***get a unique master id*** - guidgen.generate_id(\"fx\").masterId\n    - ***get a unique numeric id*** - guidgen.generate_id(\"fx\").numericId\n    - ***drop a numeric id*** - guidgen.drop_id(21,\"fx\")\n    - ***get a log details*** - guidgen.generate_id(\"fx\").logOuput.stdout_log/stderr_log\n\n## Contributing\n\nContributions are welcome! Please fork the repository and submit a pull request.\n\n## License\n\nThis project is licensed under the MIT License. See the LICENSE file for details.\n\n## Contact\n\nFor any questions or suggestions, please contact <email@debmishra.me>.\n",
    "bugtrack_url": null,
    "license": "GNU General Public License v3.0",
    "summary": "This packages allows creating squential ids for financial entities. It's a fairly simple program that allocates 1 billion ids for each entity.",
    "version": "1.1.5",
    "project_urls": {
        "Homepage": "https://github.com/debmishra-daedal/stormwind/persistentidgenerator",
        "Repository": "https://github.com/debmishra-daedal/stormwind"
    },
    "split_keywords": [
        "guid",
        " uniqueid",
        " uuid",
        " sequentialid"
    ],
    "urls": [
        {
            "comment_text": "",
            "digests": {
                "blake2b_256": "e3a4bbf18133602841297fa256bd6ffb7fec9f015686a8c6e1594b16fefa4c48",
                "md5": "c278227e1db452c17d4b850d53066df3",
                "sha256": "524f3da8a0bc698c2dc4144b91e8a16f27620293fe8bd4b24c55ad54a8577565"
            },
            "downloads": -1,
            "filename": "persistentidgenerator-1.1.5-py3-none-any.whl",
            "has_sig": false,
            "md5_digest": "c278227e1db452c17d4b850d53066df3",
            "packagetype": "bdist_wheel",
            "python_version": "py3",
            "requires_python": "<4.0,>=3.11",
            "size": 16927,
            "upload_time": "2024-09-18T23:33:08",
            "upload_time_iso_8601": "2024-09-18T23:33:08.801603Z",
            "url": "https://files.pythonhosted.org/packages/e3/a4/bbf18133602841297fa256bd6ffb7fec9f015686a8c6e1594b16fefa4c48/persistentidgenerator-1.1.5-py3-none-any.whl",
            "yanked": false,
            "yanked_reason": null
        },
        {
            "comment_text": "",
            "digests": {
                "blake2b_256": "c9a50af2298c2606de04ca49940f75d9f9f0073779222b0556878e69c8259d5a",
                "md5": "4d58e6d88822aacac4b66450ed8e7514",
                "sha256": "765ba0e0b1cea3b2d2b7c4a0366be554f097a701c44a8d80efa61ee8a5c3872f"
            },
            "downloads": -1,
            "filename": "persistentidgenerator-1.1.5.tar.gz",
            "has_sig": false,
            "md5_digest": "4d58e6d88822aacac4b66450ed8e7514",
            "packagetype": "sdist",
            "python_version": "source",
            "requires_python": "<4.0,>=3.11",
            "size": 15569,
            "upload_time": "2024-09-18T23:33:10",
            "upload_time_iso_8601": "2024-09-18T23:33:10.239536Z",
            "url": "https://files.pythonhosted.org/packages/c9/a5/0af2298c2606de04ca49940f75d9f9f0073779222b0556878e69c8259d5a/persistentidgenerator-1.1.5.tar.gz",
            "yanked": false,
            "yanked_reason": null
        }
    ],
    "upload_time": "2024-09-18 23:33:10",
    "github": true,
    "gitlab": false,
    "bitbucket": false,
    "codeberg": false,
    "github_user": "debmishra-daedal",
    "github_project": "stormwind",
    "travis_ci": false,
    "coveralls": false,
    "github_actions": false,
    "lcname": "persistentidgenerator"
}
        
Elapsed time: 0.40235s