Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
26 commits
Select commit Hold shift + click to select a range
e9def4c
feat(cache): canonical row cache keys, alias entries, and table gener…
alexstandiford Jul 12, 2026
5318b3c
fix(cache): address pr-audit findings — snapshot generations per oper…
alexstandiford Jul 12, 2026
c79715d
refactor(cache): extract DatastoreRowCache collaborator from the data…
alexstandiford Jul 12, 2026
de5a9b2
fix(cache): verify alias-resolved rows against the lookup key; harden…
alexstandiford Jul 12, 2026
3e284a7
fix(cache): guard post-write invalidation on every write path; finish…
alexstandiford Jul 12, 2026
74225f3
refactor(cache): complete the RowCache boundary; prove the failure paths
alexstandiford Jul 12, 2026
23f4750
fix(cache): close the identity-resolution fallback fan-out; survive r…
alexstandiford Jul 12, 2026
725819d
fix(cache): make reads outage-proof end to end; drop create's pre-warm
alexstandiford Jul 12, 2026
79cc288
fix(cache): honor the no-throw contract in invalidateAfterWrite; fix …
alexstandiford Jul 12, 2026
5e318b4
fix(cache): table-identity duplicate filtering; rotation-conditioned …
alexstandiford Jul 12, 2026
c014ffb
fix(cache): keep list survivors when rows vanish mid-read; raw values…
alexstandiford Jul 12, 2026
c62f69c
test(cache): prove deleteWhere's failure guarantees; skip write-backs…
alexstandiford Jul 12, 2026
a451162
fix(ci): static data providers for PHPUnit 10; level-9-clean new files
alexstandiford Jul 12, 2026
20d0cde
fix(ci): pin PHPUnit 9.6 and PHP 8.2 so the gates test what the packa…
alexstandiford Jul 12, 2026
31ce6ac
chore(analysis): all PR-authored files pass PHPStan level 9
alexstandiford Jul 12, 2026
d40e7ac
chore(analysis): type the datastore trait's public surface; finish th…
alexstandiford Jul 12, 2026
83586f5
chore(spellcheck): last two README words
alexstandiford Jul 12, 2026
0d2842a
refactor(cache): reshape to the documented Novatorius class patterns
alexstandiford Jul 12, 2026
ec42e94
fix(cache): restore per-field lookup strictness; harden the reshaped …
alexstandiford Jul 12, 2026
cc19b5a
test(cache): restore reshape-lost coverage; chore: level-9 cleanup in…
alexstandiford Jul 12, 2026
1548aae
fix(cache): repair poisoned canonical entries; align naming with repo…
alexstandiford Jul 12, 2026
711f0aa
refactor(cache): give the adapter full ownership of context and token…
alexstandiford Jul 12, 2026
d7b0697
test(cache): pin the ephemeral no-op guarantee and alias-slot repair
alexstandiford Jul 12, 2026
4e1020e
chore(cache): coherence sweep after the audit rounds
alexstandiford Jul 12, 2026
e6d3267
fix(cache): discriminate contexts by table name; polish the last audi…
alexstandiford Jul 12, 2026
40de4f5
test(cache): pin the poisoned estimated-count bypass
alexstandiford Jul 12, 2026
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion .github/workflows/phpstan.yml
Original file line number Diff line number Diff line change
Expand Up @@ -14,4 +14,4 @@ jobs:
with:
path: lib/ tests/
level: 9
php_version: 8.1
php_version: "8.2"
7 changes: 6 additions & 1 deletion .github/workflows/phpunit.yml
Original file line number Diff line number Diff line change
Expand Up @@ -14,4 +14,9 @@ jobs:
- name: PHPUnit Tests
uses: php-actions/phpunit@v3
with:
configuration: phpunit.xml
configuration: phpunit.xml
# Pin to the PHPUnit major the package targets (composer dev deps
# resolve 9.6): the action's default phar is PHPUnit 11+, which
# ignores @dataProvider annotations and silently skips those tests.
version: "9.6"
php_version: "8.2"
18 changes: 17 additions & 1 deletion .wordlist.txt
Original file line number Diff line number Diff line change
Expand Up @@ -23,4 +23,20 @@ Traceback
nodejs
npm
fediverse
readme
readme
getUnprefixedName
lookups
phpnomad
PrimaryKeyFactory
schemas
txt
WithDatastoreHandlerMethods
datastore
PHPNomad
PostDatabaseDatastoreHandler
TableSchemaService
DateModifiedFactory
IdentifiableDatabaseDatastoreHandler
PostsTable
DatabaseServiceProvider
DateCreatedFactory
3 changes: 2 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -125,7 +125,8 @@ The `QueryBuilder` turns that array into parameterized SQL and runs it through w
- Extend `IdentifiableDatabaseDatastoreHandler` as the base for any handler keyed by a single `id` column
- Use the `WithDatastoreHandlerMethods` trait for CRUD, cache reads, cache invalidation, and event dispatch
- Build reads and writes through `QueryBuilder` and `ClauseBuilder` with condition arrays instead of raw SQL
- Inject `DatabaseServiceProvider` into every handler to access `QueryBuilder`, `QueryStrategy`, `ClauseBuilder`, `CacheableService`, `EventStrategy`, and `LoggerStrategy`
- Inject `DatabaseServiceProvider` into every handler to access `QueryBuilder`, `QueryStrategy`, `ClauseBuilder`, `CacheableService`, `EventStrategy`, and `LoggerStrategy`; each handler derives its own `RowCacheContextAdapter` for cache-key vocabulary
- Rows are cached under canonical table-identity keys with per-table generation tokens; override `shouldUseTableGenerations()` on a handler to trade the generation token's race protection for a higher hit rate on write-hot tables
- Use column factories like `PrimaryKeyFactory`, `DateCreatedFactory`, `DateModifiedFactory`, and `ForeignKeyFactory` for common column patterns
- Model many-to-many relationships with `JunctionTable`, which handles compound primary keys and foreign key constraints

Expand Down
7 changes: 6 additions & 1 deletion composer.json
Original file line number Diff line number Diff line change
Expand Up @@ -25,19 +25,24 @@
}
],
"require": {
"php": ">=8.2",
"phpnomad/utils": "^1.0",
"phpnomad/cache": "^1.0",
"phpnomad/chrono": "^1.0",
"phpnomad/datastore": "^2.0",
"phpnomad/singleton": "^1.0",
"phpnomad/logger": "^1.0"
"phpnomad/logger": "^1.0",
"phpnomad/event": "^1.0"
},
"require-dev": {
"phpnomad/tests": "^0.1.0 || ^0.3.0"
},
"config": {
"allow-plugins": {
"phpstan/extension-installer": true
},
"platform": {
"php": "8.2.0"
}
}
}
Loading
Loading