{"id":49866272,"url":"https://github.com/jooservices/laravel-config","last_synced_at":"2026-05-15T03:02:35.033Z","repository":{"id":357243502,"uuid":"1181357584","full_name":"jooservices/laravel-config","owner":"jooservices","description":"Laravel package for MongoDB-backed application configuration with typed values, cache support, and runtime config management.","archived":false,"fork":false,"pushed_at":"2026-05-11T23:47:20.000Z","size":42,"stargazers_count":0,"open_issues_count":0,"forks_count":1,"subscribers_count":0,"default_branch":"develop","last_synced_at":"2026-05-12T01:33:48.813Z","etag":null,"topics":["cache","config","configuration","jooservices","laravel","laravel-package","mongodb","php","php85","runtime-configuration"],"latest_commit_sha":null,"homepage":"https://github.com/jooservices/laravel-config","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/jooservices.png","metadata":{"files":{"readme":"README.md","changelog":"CHANGELOG.md","contributing":"CONTRIBUTING.md","funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":"SECURITY.md","support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null,"notice":null,"maintainers":null,"copyright":null,"agents":"AGENTS.md","dco":null,"cla":null}},"created_at":"2026-03-14T03:19:12.000Z","updated_at":"2026-05-11T23:47:24.000Z","dependencies_parsed_at":null,"dependency_job_id":null,"html_url":"https://github.com/jooservices/laravel-config","commit_stats":null,"previous_names":["jooservices/laravel-config"],"tags_count":2,"template":false,"template_full_name":null,"purl":"pkg:github/jooservices/laravel-config","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/jooservices%2Flaravel-config","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/jooservices%2Flaravel-config/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/jooservices%2Flaravel-config/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/jooservices%2Flaravel-config/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/jooservices","download_url":"https://codeload.github.com/jooservices/laravel-config/tar.gz/refs/heads/develop","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/jooservices%2Flaravel-config/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":33051875,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-05-13T13:14:54.681Z","status":"online","status_checked_at":"2026-05-15T02:00:06.351Z","response_time":103,"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":["cache","config","configuration","jooservices","laravel","laravel-package","mongodb","php","php85","runtime-configuration"],"created_at":"2026-05-15T03:02:28.140Z","updated_at":"2026-05-15T03:02:35.023Z","avatar_url":"https://github.com/jooservices.png","language":"PHP","funding_links":[],"categories":[],"sub_categories":[],"readme":"# JOOservices Laravel Config\n\n[![CI](https://github.com/jooservices/laravel-config/actions/workflows/ci.yml/badge.svg?branch=develop)](https://github.com/jooservices/laravel-config/actions/workflows/ci.yml)\n[![OpenSSF Scorecard](https://api.securityscorecards.dev/projects/github.com/jooservices/laravel-config/badge)](https://securityscorecards.dev/viewer/?uri=github.com/jooservices/laravel-config)\n[![PHP Version](https://img.shields.io/badge/PHP-8.5%2B-blue.svg)](https://www.php.net/)\n[![License: MIT](https://img.shields.io/badge/License-MIT-yellow.svg)](./LICENSE)\n[![Packagist Version](https://img.shields.io/packagist/v/jooservices/laravel-config)](https://packagist.org/packages/jooservices/laravel-config)\n\nThe JOOservices Laravel Config package stores Laravel application configuration in MongoDB and exposes typed runtime access through `JOOservices\\\\LaravelConfig\\\\Facades\\\\Config`.\n\nPackage name: `jooservices/laravel-config`\n\n## Install\n\n```bash\ncomposer require jooservices/laravel-config\n```\n\nPublish configuration:\n\n```bash\nphp artisan vendor:publish --tag=config-store-config\n```\n\n## Requirements\n\n- PHP 8.5+\n- Laravel 11 or 12\n- MongoDB via `mongodb/laravel-mongodb`\n- MongoDB PHP extension\n\n## What the package does\n\n- stores values as `group`, `key`, `value`, and `type` documents in MongoDB\n- loads a full in-memory map on first read and optionally caches that map\n- supports typed normalization for `string`, `int`, `float`, `bool`, `array`, `json`, and `null`\n- provides runtime `get`, `set`, `forget`, `group`, `all`, `refresh`, and `fresh` operations\n- ships Artisan commands for common operator tasks\n\n## Quick example\n\n```php\nuse JOOservices\\LaravelConfig\\Facades\\Config;\n\nConfig::set('system.site_name', 'XCrawler');\nConfig::set('system.enabled', true);\nConfig::set('payment.retry_times', 3);\n\n$siteName = Config::get('system.site_name');\n$system = Config::group('system');\n$fresh = Config::fresh('system.site_name');\n```\n\n## Path format and validation\n\nPaths must use the `group.key` format.\n\nRejected values include:\n\n- empty paths\n- missing dots\n- leading dots\n- trailing dots\n- double dots\n- empty group or empty key segments\n\nExamples:\n\n- valid: `system.site_name`\n- valid: `payment.retry_times`\n- invalid: `system`\n- invalid: `.system.site_name`\n- invalid: `system.`\n- invalid: `system..site_name`\n\n## Cache and memory behavior\n\n- `get`, `has`, `group`, and `all` load from memory first\n- when memory is cold, the service reads the cached full map first, then MongoDB on cache miss\n- `set` and `forget` update MongoDB and keep the cache coherent without overwriting unrelated keys\n- `refresh` clears in-memory state and the configured cache key, then reloads from MongoDB\n- `fresh` bypasses the in-memory map and cache for a direct MongoDB read\n\nImportant limitation:\n\n- the in-memory map is process-local, so long-running workers, Horizon processes, Octane workers, or multiple PHP-FPM workers can hold stale state until `refresh()` is called or the process is recycled\n\n## MongoDB index requirement\n\nCreate a unique compound index on `group` and `key` so each config path remains unique.\n\n```bash\nphp artisan config-store:ensure-index\n```\n\nEquivalent Mongo shell command:\n\n```javascript\ndb.configs.createIndex(\n  { group: 1, key: 1 },\n  { name: 'config_group_key_unique', unique: true }\n);\n```\n\n## Artisan commands\n\n```bash\nphp artisan config-store:get system.site_name --default=\"Default\"\nphp artisan config-store:set system.site_name XCrawler\nphp artisan config-store:set system.enabled true --type=bool\nphp artisan config-store:forget system.site_name\nphp artisan config-store:refresh\nphp artisan config-store:ensure-index\n```\n\n## Security note\n\nThis package can store sensitive values, but it does not encrypt stored values by default. Do not place credentials or secrets in this store unless your MongoDB deployment, backups, and access controls already satisfy your security requirements.\n\n## Upgrade note\n\nThe canonical namespace for this package is now `JOOservices\\\\LaravelConfig\\\\`. Existing code that imports `JooServices\\\\LaravelConfig\\\\...` must be updated. This repository does not currently ship a compatibility alias layer.\n\n## Documentation\n\nStart with:\n\n- [Documentation Hub](./docs/README.md)\n- [Installation](./docs/01-getting-started/01-installation.md)\n- [Quick Start](./docs/01-getting-started/02-quick-start.md)\n- [Configuration](./docs/02-user-guide/01-configuration.md)\n- [Usage Guide](./docs/02-user-guide/02-usage-guide.md)\n- [Release Process](./docs/04-development/06-release-process.md)\n- [Risks, Legacy, and Gaps](./docs/05-maintenance/01-risks-legacy-and-gaps.md)\n- [Changelog](./CHANGELOG.md)\n\n## AI support\n\nThis repository includes AI contributor guidance and skill files.\n\nStart with:\n\n- [AGENTS.md](./AGENTS.md)\n- [CLAUDE.md](./CLAUDE.md)\n- [AI Skills Map](./ai/skills/README.md)\n- [AI Skills Usage Guide](./ai/skills/USAGE.md)\n\n## Development\n\n```bash\ncomposer lint\ncomposer lint:all\ncomposer test\ncomposer test:coverage\ncomposer check\ncomposer ci\n```\n\nMongoDB must be available for integration tests.\n\n## Community\n\n- [Contributing](./CONTRIBUTING.md)\n- [Security Policy](./SECURITY.md)\n- [License](./LICENSE)\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fjooservices%2Flaravel-config","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fjooservices%2Flaravel-config","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fjooservices%2Flaravel-config/lists"}