{"id":31740487,"url":"https://github.com/longrunning/longrunning","last_synced_at":"2025-10-09T10:19:47.706Z","repository":{"id":28521598,"uuid":"32038368","full_name":"LongRunning/LongRunning","owner":"LongRunning","description":"Mono repository for everything long running","archived":false,"fork":false,"pushed_at":"2024-01-31T16:55:16.000Z","size":206,"stargazers_count":192,"open_issues_count":4,"forks_count":18,"subscribers_count":7,"default_branch":"main","last_synced_at":"2025-09-21T01:29:44.792Z","etag":null,"topics":["php"],"latest_commit_sha":null,"homepage":"","language":"PHP","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/LongRunning.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2015-03-11T20:02:04.000Z","updated_at":"2024-10-27T17:49:33.000Z","dependencies_parsed_at":"2024-06-18T13:55:46.196Z","dependency_job_id":"4e0ef66e-45d6-443e-b72b-27a044ea4c4f","html_url":"https://github.com/LongRunning/LongRunning","commit_stats":{"total_commits":171,"total_committers":12,"mean_commits":14.25,"dds":0.368421052631579,"last_synced_commit":"0f2000a5160bb3e50881007030432e23dccaa652"},"previous_names":[],"tags_count":14,"template":false,"template_full_name":null,"purl":"pkg:github/LongRunning/LongRunning","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/LongRunning%2FLongRunning","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/LongRunning%2FLongRunning/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/LongRunning%2FLongRunning/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/LongRunning%2FLongRunning/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/LongRunning","download_url":"https://codeload.github.com/LongRunning/LongRunning/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/LongRunning%2FLongRunning/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":279001313,"owners_count":26083040,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","status":"online","status_checked_at":"2025-10-09T02:00:07.460Z","response_time":59,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":true,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["php"],"created_at":"2025-10-09T10:19:46.585Z","updated_at":"2025-10-09T10:19:47.701Z","avatar_url":"https://github.com/LongRunning.png","language":"PHP","funding_links":[],"categories":[],"sub_categories":[],"readme":"# LongRunning\n\n![Tests](https://github.com/LongRunning/LongRunning/workflows/Tests/badge.svg?branch=main)\n\nThis is the LongRunning mono repository for the following packages:\n\n* [core](https://github.com/LongRunning/core)\n* [doctrine-orm](https://github.com/LongRunning/doctrine-orm)\n* [sentry](https://github.com/LongRunning/sentry)\n\n## Installation\n\n:warning: Instead of installing this mono repository we recommend you to install the sub packages instead. See above.\n\n```\ncomposer require long-running/long-running\n```\n\n## Symfony\n\nIf you are using Symfony, make sure to enable the bundle:\n```php\n\u003c?php\n// config/bundles.php\n\nreturn [\n    // ...\n    LongRunning\\Core\\Bundle\\LongRunningBundle::class =\u003e ['all' =\u003e true],\n];\n```\n\n## How to use?\n\n```php\n\u003c?php\n\nfinal class MyCleaner implements \\LongRunning\\Core\\Cleaner\n{\n    public function cleanUp() : void\n    {\n        echo \"Cleaning up memory!\";\n    }\n}\n\n$cleaner = new \\LongRunning\\Core\\DelegatingCleaner([\n    new MyCleaner(),\n]);\n\nwhile (true) {\n    // Do heavy work, like processing jobs from a queue\n    echo \"Doing heavy work\";\n    sleep(1);\n    echo \"Done with heavy work\";\n\n    // Cleanup things\n    $cleaner-\u003ecleanUp();\n}\n```\n\nIf you are using Symfony, any service that implements the `LongRunning\\Core\\Cleaner` interface\nwill be autoconfigured and added to the `LongRunning\\Core\\DelegatingCleaner`.\n\nThe `LongRunning\\Core\\DelegatingCleaner` is aliased to `LongRunning\\Core\\Cleaner`.\n\nThat means that you can inject the `LongRunning\\Core\\Cleaner` service in your worker and it will\ncall all configured cleaners on `cleanUp()`:\n```php\n\u003c?php\n\nnamespace App;\n\nuse LongRunning\\Core\\Cleaner;\n\nfinal class Worker\n{\n    private Cleaner $cleaner;\n\n    public function __construct(Cleaner $cleaner)\n    {\n        $this-\u003ecleaner = $cleaner;\n    }\n\n    public function doWork() : void\n    {\n        while (true) {\n            // Do heavy work, like processing jobs from a queue\n            echo \"Doing heavy work\";\n            sleep(1);\n            echo \"Done with heavy work\";\n\n            // Cleanup things\n            $this-\u003ecleaner-\u003ecleanUp();\n        }\n    }\n}\n```\n\n## Existing cleaners\n\nLongRunning provides 2 packages that add additional cleaners:\n\n* [doctrine-orm](https://github.com/LongRunning/doctrine-orm)\n* [sentry](https://github.com/LongRunning/sentry)\n\n\n## Upgrading\n\nIf you are coming from LongRunning 0.5.0 please refer to [UPGRADING.md](UPGRADING.md).\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Flongrunning%2Flongrunning","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Flongrunning%2Flongrunning","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Flongrunning%2Flongrunning/lists"}