json-rest-api 1.0.22 → 1.0.23
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CLAUDE.md +1 -2
- package/JSKIT_BACKEND_MIGRATION_TRACKER.txt +180 -0
- package/SINGLE_VALIDATION_CONTRACT_TODO.txt +172 -0
- package/docs/API.md +51 -14
- package/docs/COMPARISON.md +2 -2
- package/docs/GUIDE/GUIDE_1_Initial_Setup.md +28 -1
- package/docs/GUIDE/GUIDE_2_2_Manipulating_And_Searching_Tables.md +5 -1
- package/docs/GUIDE/GUIDE_2_7_Pagination_And_Ordering.md +3 -1
- package/docs/GUIDE/GUIDE_2_8_Effects_of_PUT_and_PATCH.md +12 -60
- package/docs/GUIDE/GUIDE_2_Data_And_Relations.md +2 -2
- package/docs/GUIDE/GUIDE_3_Field_Transformations.md +5 -1
- package/docs/GUIDE/GUIDE_7_Hooks_Data_Management_And_Plugins.md +2 -0
- package/docs/GUIDE/GUIDE_X_Autofiltering.md +355 -0
- package/docs/GUIDE/GUIDE_X_Fastify.md +78 -0
- package/docs/GUIDE/GUIDE_X_Knex_Schema_And_Migrations.md +250 -0
- package/docs/GUIDE/GUIDE_X_Query_Projections.md +159 -0
- package/docs/GUIDE/GUIDE_X_Writing_Plugins.md +199 -0
- package/docs/GUIDE/index.md +18 -9
- package/docs/QUICKSTART.md +5 -1
- package/docs/index.md +1 -1
- package/index.js +3 -2
- package/package.json +2 -2
- package/plugins/core/connectors/express-plugin.js +97 -184
- package/plugins/core/connectors/fastify-plugin.js +206 -0
- package/plugins/core/connectors/lib/connector-core.js +195 -0
- package/plugins/core/connectors/lib/transport-http-helpers.js +122 -0
- package/plugins/core/connectors/lib/transport-route-schemas.js +92 -0
- package/plugins/core/lib/dbIntrospection.js +1078 -0
- package/plugins/core/lib/dbTablesOperations.js +1104 -160
- package/plugins/core/lib/querying/knex-json-api-transformers-querying.js +5 -2
- package/plugins/core/lib/querying/knex-process-includes.js +3 -4
- package/plugins/core/lib/querying/knex-query-helpers.js +17 -71
- package/plugins/core/lib/querying/knex-relationship-includes.js +466 -206
- package/plugins/core/lib/querying/query-builder-utils.js +19 -0
- package/plugins/core/lib/querying/query-field-sort-helpers.js +135 -0
- package/plugins/core/lib/querying/sort-helpers.js +33 -0
- package/plugins/core/lib/querying/storage-adapter-utils.js +51 -0
- package/plugins/core/lib/querying/url-helpers.js +8 -2
- package/plugins/core/lib/querying-writing/compile-schemas.js +12 -1
- package/plugins/core/lib/querying-writing/knex-field-helpers.js +83 -13
- package/plugins/core/lib/querying-writing/knex-json-api-transformers.js +13 -12
- package/plugins/core/lib/querying-writing/query-field-helpers.js +88 -0
- package/plugins/core/lib/querying-writing/request-contracts.js +590 -0
- package/plugins/core/lib/storage/canonical-storage-mapping.js +113 -0
- package/plugins/core/lib/storage/storage-adapter.js +79 -2
- package/plugins/core/lib/storage/storage-mapping.js +204 -0
- package/plugins/core/rest-api-anyapi-knex-plugin.js +355 -228
- package/plugins/core/rest-api-autofilter-plugin.js +414 -0
- package/plugins/core/rest-api-knex-plugin.js +249 -211
- package/plugins/core/rest-api-plugin-hooks/register-relationship-routes.js +10 -5
- package/plugins/core/rest-api-plugin-hooks/register-scope-routes.js +12 -6
- package/plugins/core/rest-api-plugin-methods/apply-query-filters.js +41 -0
- package/plugins/core/rest-api-plugin-methods/common.js +121 -83
- package/plugins/core/rest-api-plugin-methods/enrich-attributes.js +6 -1
- package/plugins/core/rest-api-plugin-methods/get.js +23 -14
- package/plugins/core/rest-api-plugin-methods/patch.js +28 -12
- package/plugins/core/rest-api-plugin-methods/post.js +13 -8
- package/plugins/core/rest-api-plugin-methods/put.js +45 -21
- package/plugins/core/rest-api-plugin-methods/query.js +15 -53
- package/plugins/core/rest-api-plugin.js +2 -0
- package/plugins/core/rest-api-positioning-plugin.js +1 -1
- package/plugins/core/rest-api-query-projections-plugin.js +130 -0
- package/plugins/core/socketio-plugin.js +1 -3
- package/tests/autofilter.test.js +463 -0
- package/tests/custom-id-simplified-post.test.js +75 -0
- package/tests/custom-idproperty-relationships.test.js +33 -0
- package/tests/db-introspection.test.js +518 -0
- package/tests/db-table-operations.test.js +781 -0
- package/tests/fastify-plugin.test.js +141 -0
- package/tests/field-getters.test.js +1 -2
- package/tests/field-setters.test.js +0 -4
- package/tests/fixtures/api-configs.js +188 -219
- package/tests/helpers/fake-fastify.js +99 -0
- package/tests/http-connectors-parity.test.js +235 -0
- package/tests/projected-fields.test.js +319 -0
- package/tests/relationships.test.js +3 -3
- package/tests/searchschema-knex-behavior.test.js +187 -0
- package/tests/searchschema-merge.test.js +21 -69
- package/tests/storage-mapping.test.js +210 -0
- package/audit/00-charter.md +0 -103
- package/audit/01-scope-map.md +0 -84
- package/audit/02-coverage-matrix.csv +0 -174
- package/audit/03-invariants.md +0 -123
- package/audit/04-standards-rubric.md +0 -56
- package/audit/05-competitor-rubric.md +0 -77
- package/audit/06-findings.md +0 -160
- package/audit/07-risk-register.csv +0 -10
- package/audit/08-remediation-roadmap.md +0 -177
- package/audit/09-signoff-check.md +0 -23
- package/audit/10-final-synthesis.md +0 -29
- package/audit/evidence/code/all-files-json-rest-api.txt +0 -168
- package/audit/evidence/code/all-files-json-rest-schema.txt +0 -12
- package/audit/evidence/code/boundary-leak-checks.txt +0 -72
- package/audit/evidence/code/critical-pass1/json-rest-api__plugins__core__bulk-operations-plugin.js.txt +0 -480
- package/audit/evidence/code/critical-pass1/json-rest-api__plugins__core__connectors__express-plugin.js.txt +0 -532
- package/audit/evidence/code/critical-pass1/json-rest-api__plugins__core__connectors__lib__busboy-detector.js.txt +0 -175
- package/audit/evidence/code/critical-pass1/json-rest-api__plugins__core__connectors__lib__formidable-detector.js.txt +0 -138
- package/audit/evidence/code/critical-pass1/json-rest-api__plugins__core__connectors__lib__request-helpers.js.txt +0 -222
- package/audit/evidence/code/critical-pass1/json-rest-api__plugins__core__file-handling-plugin.js.txt +0 -342
- package/audit/evidence/code/critical-pass1/json-rest-api__plugins__core__lib__dbTablesOperations.js.txt +0 -304
- package/audit/evidence/code/critical-pass1/json-rest-api__plugins__core__lib__fractional-positioning.js.txt +0 -188
- package/audit/evidence/code/critical-pass1/json-rest-api__plugins__core__lib__querying-writing__compile-schemas.js.txt +0 -336
- package/audit/evidence/code/critical-pass1/json-rest-api__plugins__core__lib__querying-writing__connectors-query-parser.js.txt +0 -165
- package/audit/evidence/code/critical-pass1/json-rest-api__plugins__core__lib__querying-writing__database-capabilities.js.txt +0 -265
- package/audit/evidence/code/critical-pass1/json-rest-api__plugins__core__lib__querying-writing__database-value-normalizers.js.txt +0 -369
- package/audit/evidence/code/critical-pass1/json-rest-api__plugins__core__lib__querying-writing__default-data-helpers.js.txt +0 -72
- package/audit/evidence/code/critical-pass1/json-rest-api__plugins__core__lib__querying-writing__field-utils.js.txt +0 -139
- package/audit/evidence/code/critical-pass1/json-rest-api__plugins__core__lib__querying-writing__knex-constants.js.txt +0 -45
- package/audit/evidence/code/critical-pass1/json-rest-api__plugins__core__lib__querying-writing__knex-field-helpers.js.txt +0 -396
- package/audit/evidence/code/critical-pass1/json-rest-api__plugins__core__lib__querying-writing__knex-json-api-transformers.js.txt +0 -162
- package/audit/evidence/code/critical-pass1/json-rest-api__plugins__core__lib__querying-writing__payload-validators.js.txt +0 -1314
- package/audit/evidence/code/critical-pass1/json-rest-api__plugins__core__lib__querying-writing__schema-helpers.js.txt +0 -488
- package/audit/evidence/code/critical-pass1/json-rest-api__plugins__core__lib__querying-writing__scope-validations.js.txt +0 -484
- package/audit/evidence/code/critical-pass1/json-rest-api__plugins__core__lib__querying-writing__simplified-helpers.js.txt +0 -857
- package/audit/evidence/code/critical-pass1/json-rest-api__plugins__core__lib__querying__knex-cross-table-search.js.txt +0 -565
- package/audit/evidence/code/critical-pass1/json-rest-api__plugins__core__lib__querying__knex-json-api-transformers-querying.js.txt +0 -485
- package/audit/evidence/code/critical-pass1/json-rest-api__plugins__core__lib__querying__knex-pagination-helpers.js.txt +0 -560
- package/audit/evidence/code/critical-pass1/json-rest-api__plugins__core__lib__querying__knex-process-includes.js.txt +0 -167
- package/audit/evidence/code/critical-pass1/json-rest-api__plugins__core__lib__querying__knex-query-helpers-base.js.txt +0 -109
- package/audit/evidence/code/critical-pass1/json-rest-api__plugins__core__lib__querying__knex-query-helpers.js.txt +0 -1064
- package/audit/evidence/code/critical-pass1/json-rest-api__plugins__core__lib__querying__knex-relationship-includes.js.txt +0 -1983
- package/audit/evidence/code/critical-pass1/json-rest-api__plugins__core__lib__querying__knex-window-queries.js.txt +0 -328
- package/audit/evidence/code/critical-pass1/json-rest-api__plugins__core__lib__querying__url-helpers.js.txt +0 -119
- package/audit/evidence/code/critical-pass1/json-rest-api__plugins__core__lib__storage__storage-adapter.js.txt +0 -160
- package/audit/evidence/code/critical-pass1/json-rest-api__plugins__core__lib__writing__many-to-many-manipulations.js.txt +0 -300
- package/audit/evidence/code/critical-pass1/json-rest-api__plugins__core__lib__writing__relationship-processor.js.txt +0 -245
- package/audit/evidence/code/critical-pass1/json-rest-api__plugins__core__rest-api-access.js.txt +0 -459
- package/audit/evidence/code/critical-pass1/json-rest-api__plugins__core__rest-api-cors-plugin.js.txt +0 -237
- package/audit/evidence/code/critical-pass1/json-rest-api__plugins__core__rest-api-knex-plugin.js.txt +0 -1135
- package/audit/evidence/code/critical-pass1/json-rest-api__plugins__core__rest-api-multihome-plugin.js.txt +0 -314
- package/audit/evidence/code/critical-pass1/json-rest-api__plugins__core__rest-api-plugin-hooks__compile-resource-schemas.js.txt +0 -7
- package/audit/evidence/code/critical-pass1/json-rest-api__plugins__core__rest-api-plugin-hooks__register-relationship-routes.js.txt +0 -71
- package/audit/evidence/code/critical-pass1/json-rest-api__plugins__core__rest-api-plugin-hooks__register-scope-routes.js.txt +0 -102
- package/audit/evidence/code/critical-pass1/json-rest-api__plugins__core__rest-api-plugin-hooks__turn-scope-init-into-vars.js.txt +0 -49
- package/audit/evidence/code/critical-pass1/json-rest-api__plugins__core__rest-api-plugin-hooks__validate-include-configurations.js.txt +0 -39
- package/audit/evidence/code/critical-pass1/json-rest-api__plugins__core__rest-api-plugin-methods__add-route.js.txt +0 -23
- package/audit/evidence/code/critical-pass1/json-rest-api__plugins__core__rest-api-plugin-methods__check-permissions.js.txt +0 -13
- package/audit/evidence/code/critical-pass1/json-rest-api__plugins__core__rest-api-plugin-methods__common.js.txt +0 -639
- package/audit/evidence/code/critical-pass1/json-rest-api__plugins__core__rest-api-plugin-methods__delete-relationship.js.txt +0 -117
- package/audit/evidence/code/critical-pass1/json-rest-api__plugins__core__rest-api-plugin-methods__delete.js.txt +0 -104
- package/audit/evidence/code/critical-pass1/json-rest-api__plugins__core__rest-api-plugin-methods__enrich-attributes.js.txt +0 -199
- package/audit/evidence/code/critical-pass1/json-rest-api__plugins__core__rest-api-plugin-methods__get-related.js.txt +0 -353
- package/audit/evidence/code/critical-pass1/json-rest-api__plugins__core__rest-api-plugin-methods__get-relationship.js.txt +0 -61
- package/audit/evidence/code/critical-pass1/json-rest-api__plugins__core__rest-api-plugin-methods__get.js.txt +0 -184
- package/audit/evidence/code/critical-pass1/json-rest-api__plugins__core__rest-api-plugin-methods__patch-relationship.js.txt +0 -55
- package/audit/evidence/code/critical-pass1/json-rest-api__plugins__core__rest-api-plugin-methods__patch.js.txt +0 -191
- package/audit/evidence/code/critical-pass1/json-rest-api__plugins__core__rest-api-plugin-methods__post-relationship.js.txt +0 -110
- package/audit/evidence/code/critical-pass1/json-rest-api__plugins__core__rest-api-plugin-methods__post.js.txt +0 -168
- package/audit/evidence/code/critical-pass1/json-rest-api__plugins__core__rest-api-plugin-methods__put.js.txt +0 -253
- package/audit/evidence/code/critical-pass1/json-rest-api__plugins__core__rest-api-plugin-methods__query.js.txt +0 -207
- package/audit/evidence/code/critical-pass1/json-rest-api__plugins__core__rest-api-plugin-methods__release.js.txt +0 -12
- package/audit/evidence/code/critical-pass1/json-rest-api__plugins__core__rest-api-plugin.js.txt +0 -165
- package/audit/evidence/code/critical-pass1/json-rest-api__plugins__core__rest-api-positioning-plugin.js.txt +0 -668
- package/audit/evidence/code/critical-pass1/json-rest-api__plugins__core__socketio-plugin.js.txt +0 -621
- package/audit/evidence/code/critical-pass1/json-rest-api__plugins__storage__local-storage.js.txt +0 -218
- package/audit/evidence/code/critical-pass1/json-rest-api__plugins__storage__s3-storage.js.txt +0 -124
- package/audit/evidence/code/critical-pass1/json-rest-schema__src__CorePlugin.js.txt +0 -269
- package/audit/evidence/code/critical-pass1/json-rest-schema__src__Schema.js.txt +0 -242
- package/audit/evidence/code/critical-pass1/json-rest-schema__src__index.js.txt +0 -77
- package/audit/evidence/code/critical-pass1-risk-keywords.txt +0 -238
- package/audit/evidence/code/critical-pass1-summary.csv +0 -67
- package/audit/evidence/code/critical-pass2-summary.csv +0 -67
- package/audit/evidence/code/early-silent-zones-no-test-token.txt +0 -57
- package/audit/evidence/code/error-model-signals.txt +0 -98
- package/audit/evidence/code/git-files-json-rest-api.txt +0 -171
- package/audit/evidence/code/git-files-json-rest-schema.txt +0 -27
- package/audit/evidence/code/hook-flow-signals.txt +0 -282
- package/audit/evidence/code/idproperty-signals.txt +0 -157
- package/audit/evidence/code/import-cycles-non-anyapi.txt +0 -3
- package/audit/evidence/code/import-hotspots-non-anyapi.txt +0 -96
- package/audit/evidence/code/imports-json-rest-api.txt +0 -354
- package/audit/evidence/code/imports-json-rest-schema.txt +0 -15
- package/audit/evidence/code/in-scope-files-json-rest-api.txt +0 -160
- package/audit/evidence/code/in-scope-files-json-rest-schema.txt +0 -13
- package/audit/evidence/code/non-anyapi-core-files.txt +0 -101
- package/audit/evidence/code/permission-signals.txt +0 -193
- package/audit/evidence/code/query-include-signals.txt +0 -687
- package/audit/evidence/code/transaction-signals.txt +0 -28
- package/audit/evidence/code/validation-signals.txt +0 -650
- package/audit/evidence/code/write-path-signals.txt +0 -61
- package/audit/evidence/docs/docs-claims-signals.txt +0 -1075
- package/audit/evidence/docs/schema-docs-claims-signals.txt +0 -179
- package/audit/evidence/external/corpus-freeze.md +0 -21
- package/audit/evidence/external/npm-competitor-metadata.txt +0 -70
- package/audit/evidence/external/npm-download-signals.txt +0 -23
- package/audit/evidence/external/npm-jsonapi-server.txt +0 -8
- package/audit/evidence/external/npm-modern-jsonapi-metadata.txt +0 -38
- package/audit/evidence/external/readme-fortune-signals.txt +0 -26
- package/audit/evidence/external/readme-fortune.md +0 -165
- package/audit/evidence/external/readme-json-api-serializer-signals.txt +0 -80
- package/audit/evidence/external/readme-json-api-serializer.md +0 -690
- package/audit/evidence/external/readme-jsonapi-serde-server-signals.txt +0 -0
- package/audit/evidence/external/readme-jsonapi-serde-server.md +0 -22
- package/audit/evidence/external/readme-jsonapi-serializer-signals.txt +0 -63
- package/audit/evidence/external/readme-jsonapi-serializer.md +0 -315
- package/audit/evidence/external/readme-jsonapi-server-signals.txt +0 -19
- package/audit/evidence/external/readme-jsonapi-server.md +0 -104
- package/audit/evidence/external/readme-nestjs-json-api-signals.txt +0 -4
- package/audit/evidence/external/readme-nestjs-json-api.md +0 -94
- package/audit/evidence/external/readme-yaser-json-api-nestjs-signals.txt +0 -47
- package/audit/evidence/external/readme-yaser-json-api-nestjs.md +0 -447
- package/audit/evidence/external/standard-jsonapi-snippets.txt +0 -84
- package/audit/evidence/external/standard-rfc-snippets.txt +0 -168
- package/audit/evidence/external/standards-sources.txt +0 -6
- package/audit/evidence/runtime/baseline-commits.txt +0 -2
- package/audit/evidence/runtime/db-adapter-assumptions.txt +0 -3
- package/audit/evidence/runtime/environment.txt +0 -4
- package/audit/evidence/runtime/invariant-runtime-mapping.md +0 -38
- package/audit/evidence/runtime/probe-patch-relationship-error.exitcode +0 -1
- package/audit/evidence/runtime/probe-patch-relationship-error.log +0 -76
- package/audit/evidence/runtime/probe-patch-relationship-error.mjs +0 -67
- package/audit/evidence/runtime/probe-patch-relationship-referenceerror.exitcode +0 -1
- package/audit/evidence/runtime/probe-patch-relationship-referenceerror.log +0 -62
- package/audit/evidence/runtime/probe-patch-relationship-referenceerror.mjs +0 -47
- package/audit/evidence/runtime/test-exitcodes.txt +0 -4
- package/audit/evidence/runtime/test-summary.md +0 -107
- package/audit/evidence/runtime/trace-anchors.txt +0 -61
- package/audit/evidence/tests/access-multitenancy-test-signals.txt +0 -125
- package/audit/evidence/tests/failing-tests-summary.txt +0 -25
- package/audit/evidence/tests/npm-test-json-rest-api.exitcode +0 -1
- package/audit/evidence/tests/npm-test-json-rest-api.log +0 -5885
- package/audit/evidence/tests/npm-test-json-rest-schema.exitcode +0 -1
- package/audit/evidence/tests/npm-test-json-rest-schema.log +0 -356
- package/audit/evidence/tests/query-include-test-signals.txt +0 -948
- package/audit/evidence/tests/relationship-test-signals.txt +0 -223
- package/audit/evidence/tests/skipped-tests.txt +0 -10
- package/audit/evidence/tests/test-suite-list-non-anyapi.txt +0 -30
- package/audit/evidence/tests/test-suite-list.txt +0 -32
- package/audit/subsystems/docs-drift.md +0 -49
- package/audit/subsystems/pass2-cross-review.md +0 -131
- package/audit/subsystems/plugins-access.md +0 -51
- package/audit/subsystems/plugins-bulk.md +0 -50
- package/audit/subsystems/plugins-cors.md +0 -48
- package/audit/subsystems/plugins-file.md +0 -53
- package/audit/subsystems/plugins-multihome.md +0 -50
- package/audit/subsystems/plugins-positioning.md +0 -54
- package/audit/subsystems/plugins-socketio.md +0 -50
- package/audit/subsystems/query-engine.md +0 -61
- package/audit/subsystems/relationships.md +0 -55
- package/audit/subsystems/rest-orchestration.md +0 -66
- package/audit/subsystems/schema-core.md +0 -64
- package/audit/subsystems/storage-knex.md +0 -57
- package/audit/subsystems/tests.md +0 -48
- package/audit/subsystems/transport-express.md +0 -55
- package/audit/traces/trace-read-get.md +0 -22
- package/audit/traces/trace-read-query.md +0 -25
- package/audit/traces/trace-relationship-endpoints.md +0 -31
- package/audit/traces/trace-write-delete.md +0 -17
- package/audit/traces/trace-write-patch.md +0 -26
- package/audit/traces/trace-write-post.md +0 -22
- package/audit/traces/trace-write-put.md +0 -23
- package/docs/GUIDE/GUIDE_4_Authentication_And_Permissions.md +0 -707
- package/docs/GUIDE/GUIDE_X_Multihome.md +0 -666
- package/plugins/core/lib/querying-writing/payload-validators.js +0 -1314
- package/plugins/core/rest-api-access.js +0 -459
- package/plugins/core/rest-api-multihome-plugin.js +0 -314
- package/tests/multihome.test.js +0 -553
- package/tests/multihome.test.js.bak +0 -550
- package/tests/ownership-optout.test.js +0 -76
- package/tests/rest-api-access.test.js +0 -206
package/audit/06-findings.md
DELETED
|
@@ -1,160 +0,0 @@
|
|
|
1
|
-
# Consolidated Findings (M6, non-anyapi)
|
|
2
|
-
|
|
3
|
-
## Executive synthesis
|
|
4
|
-
- The non-anyapi architecture is fundamentally sound and modular, with strong coverage breadth and clear layering.
|
|
5
|
-
- Current release risk is dominated by one runtime-confirmed high-severity defect: relationship PATCH failure handling (`RISK-001`).
|
|
6
|
-
- Operational quality is mixed: core CRUD/relationship/read flows are stable, but edge reliability/performance and contract-consistency gaps remain.
|
|
7
|
-
|
|
8
|
-
## Technical synthesis
|
|
9
|
-
- Layering contract is mostly respected (`transport -> methods -> helpers -> storage -> DB`) with limited, intentional plugin-level direct DB use.
|
|
10
|
-
- Invariant status is now fully classified (no unknowns): `2 fail`, `4 pass`, `6 partial`.
|
|
11
|
-
- Runtime corroboration found three concrete failure classes:
|
|
12
|
-
- relationship PATCH error-path defect (high),
|
|
13
|
-
- positioning multifilter regressions (medium),
|
|
14
|
-
- schema export/test contract drift (medium).
|
|
15
|
-
|
|
16
|
-
## Audit synthesis status
|
|
17
|
-
- Repos audited:
|
|
18
|
-
- `/home/merc/Development/current/json-rest-api`
|
|
19
|
-
- `/home/merc/Development/current/json-rest-schema`
|
|
20
|
-
- Baseline commits:
|
|
21
|
-
- `json-rest-api`: `72c08eec75f696a80c70b25608ed7c19eb505698`
|
|
22
|
-
- `json-rest-schema`: `9c30d3ba7317407a69231515fd58196862b25b34`
|
|
23
|
-
- Runtime/test evidence captured in:
|
|
24
|
-
- [test-summary.md](/home/merc/Development/current/json-rest-api/audit/evidence/runtime/test-summary.md)
|
|
25
|
-
- [failing-tests-summary.txt](/home/merc/Development/current/json-rest-api/audit/evidence/tests/failing-tests-summary.txt)
|
|
26
|
-
- [trace-write-patch.md](/home/merc/Development/current/json-rest-api/audit/traces/trace-write-patch.md)
|
|
27
|
-
|
|
28
|
-
## Quality profile (1-5)
|
|
29
|
-
- Correctness: `3.1`
|
|
30
|
-
- Security: `3.4`
|
|
31
|
-
- Resilience: `2.8`
|
|
32
|
-
- Performance: `3.0`
|
|
33
|
-
- Maintainability: `3.6`
|
|
34
|
-
- Observability: `3.0`
|
|
35
|
-
- Test quality: `3.3`
|
|
36
|
-
- Weighted composite (charter weights): `3.2/5`
|
|
37
|
-
|
|
38
|
-
## Findings by severity
|
|
39
|
-
|
|
40
|
-
### High
|
|
41
|
-
|
|
42
|
-
#### F-001 Relationship PATCH error-path defect (runtime-confirmed)
|
|
43
|
-
- Type: defect
|
|
44
|
-
- Assertion: [Verified][C5]
|
|
45
|
-
- Evidence:
|
|
46
|
-
- [patch-relationship.js:53](/home/merc/Development/current/json-rest-api/plugins/core/rest-api-plugin-methods/patch-relationship.js:53)
|
|
47
|
-
- [probe-patch-relationship-referenceerror.log](/home/merc/Development/current/json-rest-api/audit/evidence/runtime/probe-patch-relationship-referenceerror.log)
|
|
48
|
-
- Impact:
|
|
49
|
-
- Masks root errors with `ReferenceError`.
|
|
50
|
-
- Breaks canonical write error handler path and rollback-hook behavior guarantees.
|
|
51
|
-
- Invariant linkage: `INV-001`, `INV-008`.
|
|
52
|
-
- Risk linkage: `RISK-001`.
|
|
53
|
-
|
|
54
|
-
### Medium
|
|
55
|
-
|
|
56
|
-
#### F-002 Positioning multifilter edge cases failing in regression suite
|
|
57
|
-
- Type: defect
|
|
58
|
-
- Assertion: [Verified][C5]
|
|
59
|
-
- Evidence:
|
|
60
|
-
- [failing-tests-summary.txt](/home/merc/Development/current/json-rest-api/audit/evidence/tests/failing-tests-summary.txt)
|
|
61
|
-
- failing tests in `tests/positioning-multifilter.test.js`.
|
|
62
|
-
- Impact:
|
|
63
|
-
- Incorrect ordering/filter semantics for edge cases.
|
|
64
|
-
- Invariant linkage: `INV-010`, `INV-012`.
|
|
65
|
-
- Risk linkage: `RISK-002`.
|
|
66
|
-
|
|
67
|
-
#### F-003 Error envelope inconsistency across paths
|
|
68
|
-
- Type: defect
|
|
69
|
-
- Assertion: [Verified][C4]
|
|
70
|
-
- Evidence:
|
|
71
|
-
- [rest-api-cors-plugin.js:112](/home/merc/Development/current/json-rest-api/plugins/core/rest-api-cors-plugin.js:112)
|
|
72
|
-
- [probe-patch-relationship-referenceerror.log](/home/merc/Development/current/json-rest-api/audit/evidence/runtime/probe-patch-relationship-referenceerror.log)
|
|
73
|
-
- Impact:
|
|
74
|
-
- Client error handling complexity; standards consistency erosion.
|
|
75
|
-
- Invariant linkage: `INV-008`.
|
|
76
|
-
- Risk linkage: `RISK-003`.
|
|
77
|
-
|
|
78
|
-
#### F-004 Schema package test failure indicates export/contract drift
|
|
79
|
-
- Type: defect
|
|
80
|
-
- Assertion: [Verified][C5]
|
|
81
|
-
- Evidence:
|
|
82
|
-
- [npm-test-json-rest-schema.log](/home/merc/Development/current/json-rest-api/audit/evidence/tests/npm-test-json-rest-schema.log)
|
|
83
|
-
- `SyntaxError`: missing `createKnexTable` export in `./src/index.js` import path.
|
|
84
|
-
- Impact:
|
|
85
|
-
- Breaks schema-side test contract and affects migration/table tooling confidence.
|
|
86
|
-
- Invariant linkage: `INV-012`.
|
|
87
|
-
- Risk linkage: `RISK-004`.
|
|
88
|
-
|
|
89
|
-
#### F-005 Documentation drift on write payload behavior (`included`)
|
|
90
|
-
- Type: documentation drift
|
|
91
|
-
- Assertion: [Verified][C4]
|
|
92
|
-
- Evidence:
|
|
93
|
-
- [payload-validators.js](/home/merc/Development/current/json-rest-api/plugins/core/lib/querying-writing/payload-validators.js)
|
|
94
|
-
- [common.js:171](/home/merc/Development/current/json-rest-api/plugins/core/rest-api-plugin-methods/common.js:171)
|
|
95
|
-
- [docs-drift.md](/home/merc/Development/current/json-rest-api/audit/subsystems/docs-drift.md)
|
|
96
|
-
- Impact:
|
|
97
|
-
- Onboarding and integration errors from contradictory guidance.
|
|
98
|
-
- Invariant linkage: `INV-011`.
|
|
99
|
-
- Risk linkage: `RISK-005`.
|
|
100
|
-
|
|
101
|
-
#### F-006 Include performance assurances are incomplete
|
|
102
|
-
- Type: design choice / test gap
|
|
103
|
-
- Assertion: [Inferred][C3]
|
|
104
|
-
- Evidence:
|
|
105
|
-
- include logic code + passing include tests, but no query-count guard tests.
|
|
106
|
-
- [trace-read-query.md](/home/merc/Development/current/json-rest-api/audit/traces/trace-read-query.md)
|
|
107
|
-
- Impact:
|
|
108
|
-
- Potential N+1/performance cliffs under high fanout/depth not bounded by tests.
|
|
109
|
-
- Invariant linkage: `INV-007`, `INV-012`.
|
|
110
|
-
- Risk linkage: `RISK-006`.
|
|
111
|
-
|
|
112
|
-
#### F-007 Multi-tenant bypass resistance is strong but not exhaustively validated
|
|
113
|
-
- Type: design choice / residual risk
|
|
114
|
-
- Assertion: [Inferred][C3]
|
|
115
|
-
- Evidence:
|
|
116
|
-
- access + multihome implementations and passing suites.
|
|
117
|
-
- [plugins-access.md](/home/merc/Development/current/json-rest-api/audit/subsystems/plugins-access.md)
|
|
118
|
-
- [plugins-multihome.md](/home/merc/Development/current/json-rest-api/audit/subsystems/plugins-multihome.md)
|
|
119
|
-
- Impact:
|
|
120
|
-
- Alternate-path bypass risk remains partially unbounded.
|
|
121
|
-
- Invariant linkage: `INV-009`.
|
|
122
|
-
- Risk linkage: `RISK-007`.
|
|
123
|
-
|
|
124
|
-
### Low
|
|
125
|
-
|
|
126
|
-
#### F-008 Bulk optimization hook execution path clarity gap
|
|
127
|
-
- Type: design choice
|
|
128
|
-
- Assertion: [Inferred][C3]
|
|
129
|
-
- Evidence:
|
|
130
|
-
- [plugins-bulk.md](/home/merc/Development/current/json-rest-api/audit/subsystems/plugins-bulk.md)
|
|
131
|
-
- Impact:
|
|
132
|
-
- Maintainability and performance predictability concern.
|
|
133
|
-
- Invariant linkage: `INV-010`.
|
|
134
|
-
- Risk linkage: `RISK-008`.
|
|
135
|
-
|
|
136
|
-
#### F-009 Unknown-error message exposure risk in transport
|
|
137
|
-
- Type: design choice
|
|
138
|
-
- Assertion: [Inferred][C3]
|
|
139
|
-
- Evidence:
|
|
140
|
-
- [express-plugin.js](/home/merc/Development/current/json-rest-api/plugins/core/connectors/express-plugin.js)
|
|
141
|
-
- Impact:
|
|
142
|
-
- Potential internal message leakage.
|
|
143
|
-
- Invariant linkage: `INV-008`.
|
|
144
|
-
- Risk linkage: `RISK-009`.
|
|
145
|
-
|
|
146
|
-
## Architecture and boundary verdict
|
|
147
|
-
- [Verified][C4] Primary layer contract is mostly respected: `transport -> methods -> helpers -> storage -> DB`.
|
|
148
|
-
- [Verified][C4] No direct transport-level DB access found in express connector.
|
|
149
|
-
- [Inferred][C3] Select plugins can access knex directly for specialized behavior (positioning/bulk), acceptable but increases contract-risk surface.
|
|
150
|
-
- Evidence: [boundary-leak-checks.txt](/home/merc/Development/current/json-rest-api/audit/evidence/code/boundary-leak-checks.txt), [import-cycles-non-anyapi.txt](/home/merc/Development/current/json-rest-api/audit/evidence/code/import-cycles-non-anyapi.txt).
|
|
151
|
-
|
|
152
|
-
## Residual uncertainty
|
|
153
|
-
- Query-count behavior under deep include fanout.
|
|
154
|
-
- File-upload + DB rollback compensation.
|
|
155
|
-
- Full multi-tenant bypass matrix across all alternate endpoint combinations.
|
|
156
|
-
- Production-like load behavior for socketio and bulk paths.
|
|
157
|
-
|
|
158
|
-
Confidence summary:
|
|
159
|
-
- High confidence (`C4-C5`): primary defects and failing runtime/test signals.
|
|
160
|
-
- Medium confidence (`C3`): performance/security posture in scenarios not explicitly load-tested.
|
|
@@ -1,10 +0,0 @@
|
|
|
1
|
-
risk_id,title,subsystem,description,trigger,impact,likelihood,detectability,severity_score,confidence,evidence_refs,invariant_refs,owner_candidate,mitigation,verification_test,status
|
|
2
|
-
RISK-001,Relationship PATCH error handler undefined,relationships,"patchRelationship catch path calls undefined handleWriteMethodError causing ReferenceError and masking root errors",Malformed/invalid relationship PATCH payload or downstream PATCH failure,5,4,2,80,C5,"plugins/core/rest-api-plugin-methods/patch-relationship.js:52-54; audit/evidence/runtime/probe-patch-relationship-referenceerror.log",INV-001|INV-008,REST methods maintainer,"Import and wire handleWriteMethodError + log + runHooks arguments exactly as post/delete relationship methods; add regression tests",Add test: patchRelationship invalid payload returns structured REST_API_PAYLOAD error and transaction hooks run,open
|
|
3
|
-
RISK-002,Positioning multi-filter semantic regression,plugins-positioning,"Edge-case filters (empty/null and numeric/string) fail expectations in current suite",Running positioning multifilter scenarios with mixed-type filters,4,4,3,48,C5,"audit/evidence/tests/failing-tests-summary.txt; tests/positioning-multifilter.test.js",INV-010|INV-012,Positioning plugin maintainer,"Fix normalization/comparison logic for multifilter edge cases; preserve existing passing cases",Unskip/retain multifilter edge tests and add additional mixed-value fixtures,open
|
|
4
|
-
RISK-003,Error envelope inconsistency across paths,transport-express+plugins-cors+relationships,"Some error paths do not return consistent JSON:API errors envelope",Blocked CORS origin or relationship PATCH failure path,4,3,3,36,C4,"plugins/core/rest-api-cors-plugin.js:112-117; audit/evidence/runtime/probe-patch-relationship-referenceerror.log",INV-008,Transport+REST maintainers,"Standardize all error responses through central envelope helper",Add transport-level tests asserting `errors[]` shape for blocked CORS and relationship endpoint failures,open
|
|
5
|
-
RISK-004,Schema export/test contract drift,schema-core,"json-rest-schema test imports createKnexTable from src/index.js but export is missing",Running json-rest-schema test suite,4,3,2,48,C5,"audit/evidence/tests/npm-test-json-rest-schema.log",INV-012,Schema maintainer,"Either restore exported API contract or update tests/docs to current API surface",Add contract test for expected public exports in src/index.js,open
|
|
6
|
-
RISK-005,Docs-write-payload drift (`included`),docs-drift,"Docs/comments imply included payload support while common write setup rejects included for writes",Users send included arrays in write payloads based on docs examples/comments,3,4,4,24,C4,"plugins/core/lib/querying-writing/payload-validators.js; plugins/core/rest-api-plugin-methods/common.js:171-176; audit/subsystems/docs-drift.md",INV-011,Docs owner + core maintainer,"Align docs/comments with runtime or implement explicitly supported behavior",Add executable docs test for write payload contract,open
|
|
7
|
-
RISK-006,Include performance guardrail gap,query-engine,"No explicit query-count budget tests for deep/high-cardinality includes",High-fanout include queries in production-sized datasets,4,3,2,48,C3,"plugins/core/lib/querying/knex-relationship-includes.js; audit/traces/trace-read-query.md",INV-007|INV-012,Query engine maintainer,"Add query-count instrumentation tests and bounded include strategy checks",Add tests asserting max query count for representative include graphs,open
|
|
8
|
-
RISK-007,Multi-tenant bypass matrix incomplete,plugins-access+plugins-multihome,"Core enforcement exists but alternate-path bypass attempts are not exhaustively tested",Complex combinations of relationship endpoints/includes/custom filters,5,2,2,40,C3,"plugins/core/rest-api-access.js; plugins/core/rest-api-multihome-plugin.js; tests/multihome.test.js",INV-009,Access/multitenancy maintainer,"Expand negative-path matrix across all endpoint families",Add red-team style integration suite covering query/get/relationship/include paths per tenant,open
|
|
9
|
-
RISK-008,Bulk optimization hook path ambiguity,plugins-bulk,"beforeBulkPost optimization path appears under-specified in runtime flow",High-volume bulk POST with expected optimization,2,3,2,24,C3,"plugins/core/bulk-operations-plugin.js; audit/subsystems/plugins-bulk.md",INV-010,Bulk plugin maintainer,"Document or wire optimization path explicitly and test activation",Add explicit hook-activation test proving optimized/non-optimized branch behavior,open
|
|
10
|
-
RISK-009,Raw unexpected error message exposure,transport-express,"Unknown errors may expose raw internal messages in API responses",Unhandled exception from plugin/helper path,3,3,3,27,C3,"plugins/core/connectors/express-plugin.js",INV-008,Transport maintainer,"Sanitize unknown error details and include correlation id for internals",Add test ensuring unknown exceptions return generic client-safe detail,open
|
|
@@ -1,177 +0,0 @@
|
|
|
1
|
-
# Remediation Roadmap (non-anyapi)
|
|
2
|
-
|
|
3
|
-
## Lane A (0-2 weeks): high-severity quick wins, low blast radius
|
|
4
|
-
|
|
5
|
-
### ROADMAP-A-001 Fix relationship PATCH error-path handler wiring
|
|
6
|
-
- Problem: `patchRelationship` catch path uses undefined `handleWriteMethodError` and missing handler args.
|
|
7
|
-
- Rationale: Resolves highest-severity defect and failed invariants (`INV-001`, `INV-008`).
|
|
8
|
-
- Proposed change:
|
|
9
|
-
- Import `handleWriteMethodError` from `common.js`.
|
|
10
|
-
- Accept/pass `log` and `runHooks` into catch handler consistently with post/delete relationship methods.
|
|
11
|
-
- Files touched:
|
|
12
|
-
- [patch-relationship.js](/home/merc/Development/current/json-rest-api/plugins/core/rest-api-plugin-methods/patch-relationship.js)
|
|
13
|
-
- [relationship-endpoints.test.js](/home/merc/Development/current/json-rest-api/tests/relationship-endpoints.test.js)
|
|
14
|
-
- Tests to add/update:
|
|
15
|
-
- Add regression for malformed relationship payload and forced downstream failure to confirm structured error + rollback hooks.
|
|
16
|
-
- Rollback plan:
|
|
17
|
-
- Revert method-level catch changes and restore previous behavior if compatibility break appears; keep added tests to document expected behavior.
|
|
18
|
-
- Exit criteria:
|
|
19
|
-
- Probe no longer emits `ReferenceError`.
|
|
20
|
-
- New regression tests pass.
|
|
21
|
-
- `INV-001` moves from fail to pass/partial with evidence.
|
|
22
|
-
|
|
23
|
-
### ROADMAP-A-002 Resolve positioning multi-filter failing edge cases
|
|
24
|
-
- Problem: Two failing assertions in `tests/positioning-multifilter.test.js`.
|
|
25
|
-
- Rationale: Existing regression failures reduce correctness confidence and block clean baseline.
|
|
26
|
-
- Proposed change:
|
|
27
|
-
- Align filter normalization/typing rules for empty/null and numeric/string comparisons.
|
|
28
|
-
- Files touched:
|
|
29
|
-
- [rest-api-positioning-plugin.js](/home/merc/Development/current/json-rest-api/plugins/core/rest-api-positioning-plugin.js)
|
|
30
|
-
- [positioning-multifilter.test.js](/home/merc/Development/current/json-rest-api/tests/positioning-multifilter.test.js)
|
|
31
|
-
- Tests to add/update:
|
|
32
|
-
- Keep existing failing cases as fixed regressions; add one mixed-null-string and one mixed-number-string case.
|
|
33
|
-
- Rollback plan:
|
|
34
|
-
- Revert normalization change and isolate behind explicit config flag if behavior change is too broad.
|
|
35
|
-
- Exit criteria:
|
|
36
|
-
- `npm test` in json-rest-api has 0 fails for positioning suite.
|
|
37
|
-
|
|
38
|
-
### ROADMAP-A-003 Add missing relationship PATCH endpoint coverage
|
|
39
|
-
- Problem: Patch relationship endpoint lacks direct success/failure lifecycle tests.
|
|
40
|
-
- Rationale: Prevent recurrence of endpoint-specific error-path defects.
|
|
41
|
-
- Proposed change:
|
|
42
|
-
- Add explicit `patchRelationship` success and failure tests, including rollback assertions.
|
|
43
|
-
- Files touched:
|
|
44
|
-
- [relationship-endpoints.test.js](/home/merc/Development/current/json-rest-api/tests/relationship-endpoints.test.js)
|
|
45
|
-
- Tests to add/update:
|
|
46
|
-
- Success patch semantics test.
|
|
47
|
-
- Failure-path envelope + transaction cleanup test.
|
|
48
|
-
- Rollback plan:
|
|
49
|
-
- Keep tests even if implementation needs phased rollout; gate temporary exceptions with clear TODO.
|
|
50
|
-
- Exit criteria:
|
|
51
|
-
- Direct patch endpoint tests present and passing.
|
|
52
|
-
- `INV-004`/`INV-012` confidence upgraded.
|
|
53
|
-
|
|
54
|
-
## Lane B (2-6 weeks): medium complexity structural fixes
|
|
55
|
-
|
|
56
|
-
### ROADMAP-B-001 Clarify or wire bulk optimization hook execution
|
|
57
|
-
- Problem: `beforeBulkPost` optimization path appears under-specified/dead in current flow.
|
|
58
|
-
- Rationale: Reduces maintainability ambiguity and performance unpredictability.
|
|
59
|
-
- Proposed change:
|
|
60
|
-
- Either explicitly invoke optimization hook path or remove dead branch and document canonical behavior.
|
|
61
|
-
- Files touched:
|
|
62
|
-
- [bulk-operations-plugin.js](/home/merc/Development/current/json-rest-api/plugins/core/bulk-operations-plugin.js)
|
|
63
|
-
- [GUIDE_X_Bulk_Operations.md](/home/merc/Development/current/json-rest-api/docs/GUIDE/GUIDE_X_Bulk_Operations.md)
|
|
64
|
-
- Tests to add/update:
|
|
65
|
-
- Hook activation proof test for optimization path.
|
|
66
|
-
- Rollback plan:
|
|
67
|
-
- Revert to current explicit per-item path if optimization creates regressions.
|
|
68
|
-
- Exit criteria:
|
|
69
|
-
- Hook behavior is deterministic and test-asserted.
|
|
70
|
-
|
|
71
|
-
### ROADMAP-B-002 Standardize error envelope contract across all transport/plugin failures
|
|
72
|
-
- Problem: Mixed envelope shapes (`errors[]` vs `{error}`/raw exceptions).
|
|
73
|
-
- Rationale: Improves standards alignment and client reliability.
|
|
74
|
-
- Proposed change:
|
|
75
|
-
- Centralize error serialization and enforce it in transport + CORS + relationship endpoint handlers.
|
|
76
|
-
- Files touched:
|
|
77
|
-
- [express-plugin.js](/home/merc/Development/current/json-rest-api/plugins/core/connectors/express-plugin.js)
|
|
78
|
-
- [rest-api-cors-plugin.js](/home/merc/Development/current/json-rest-api/plugins/core/rest-api-cors-plugin.js)
|
|
79
|
-
- [common.js](/home/merc/Development/current/json-rest-api/plugins/core/rest-api-plugin-methods/common.js)
|
|
80
|
-
- Tests to add/update:
|
|
81
|
-
- Contract tests for blocked origin, unknown exceptions, relationship endpoint failures.
|
|
82
|
-
- Rollback plan:
|
|
83
|
-
- Feature flag strict envelope mode if downstream clients rely on legacy shape.
|
|
84
|
-
- Exit criteria:
|
|
85
|
-
- `INV-008` becomes pass with transport and method-path test evidence.
|
|
86
|
-
|
|
87
|
-
### ROADMAP-B-003 Add include performance guard tests (query-count budgets)
|
|
88
|
-
- Problem: Include correctness is tested, but N+1 bounds are not.
|
|
89
|
-
- Rationale: Converts performance unknown into measurable guardrails.
|
|
90
|
-
- Proposed change:
|
|
91
|
-
- Add query instrumentation in test harness and enforce max-query thresholds for representative include graphs.
|
|
92
|
-
- Files touched:
|
|
93
|
-
- [knex-relationship-includes.js](/home/merc/Development/current/json-rest-api/plugins/core/lib/querying/knex-relationship-includes.js)
|
|
94
|
-
- [includes.test.js](/home/merc/Development/current/json-rest-api/tests/includes.test.js)
|
|
95
|
-
- [nested-includes.test.js](/home/merc/Development/current/json-rest-api/tests/nested-includes.test.js)
|
|
96
|
-
- Tests to add/update:
|
|
97
|
-
- Query-count assertions for single-level and nested include scenarios.
|
|
98
|
-
- Rollback plan:
|
|
99
|
-
- Start in soft-threshold mode if DB-dialect variance causes instability.
|
|
100
|
-
- Exit criteria:
|
|
101
|
-
- `INV-007` moves from partial to pass/known-partial with quantified limits.
|
|
102
|
-
|
|
103
|
-
### ROADMAP-B-004 Expand multitenancy bypass matrix
|
|
104
|
-
- Problem: alternate endpoint combinations not exhaustively validated for tenant isolation.
|
|
105
|
-
- Rationale: High-impact security invariant deserves explicit matrix tests.
|
|
106
|
-
- Proposed change:
|
|
107
|
-
- Add matrix suite covering query/get/relationship/include paths across tenants and ownership roles.
|
|
108
|
-
- Files touched:
|
|
109
|
-
- [multihome.test.js](/home/merc/Development/current/json-rest-api/tests/multihome.test.js)
|
|
110
|
-
- [rest-api-access.test.js](/home/merc/Development/current/json-rest-api/tests/rest-api-access.test.js)
|
|
111
|
-
- Tests to add/update:
|
|
112
|
-
- Negative tests for each endpoint family and include variant.
|
|
113
|
-
- Rollback plan:
|
|
114
|
-
- Isolate failing matrix cases with temporary allowlist while fixing implementation.
|
|
115
|
-
- Exit criteria:
|
|
116
|
-
- `INV-009` confidence upgraded to C4+ with comprehensive negative coverage.
|
|
117
|
-
|
|
118
|
-
### ROADMAP-B-005 Align docs/comments with observed critical behavior
|
|
119
|
-
- Problem: docs drift on `included` write behavior and standards claims tone.
|
|
120
|
-
- Rationale: lowers integration friction and trust risk.
|
|
121
|
-
- Proposed change:
|
|
122
|
-
- Update docs/comments to match runtime behavior or explicitly document feature flags/limits.
|
|
123
|
-
- Files touched:
|
|
124
|
-
- [payload-validators.js](/home/merc/Development/current/json-rest-api/plugins/core/lib/querying-writing/payload-validators.js)
|
|
125
|
-
- [common.js](/home/merc/Development/current/json-rest-api/plugins/core/rest-api-plugin-methods/common.js)
|
|
126
|
-
- [docs/API.md](/home/merc/Development/current/json-rest-api/docs/API.md)
|
|
127
|
-
- relevant guide pages under `docs/GUIDE/`.
|
|
128
|
-
- Tests to add/update:
|
|
129
|
-
- Executable docs examples for critical write/error semantics.
|
|
130
|
-
- Rollback plan:
|
|
131
|
-
- Keep previous docs in changelog appendix if downstream teams need transition period.
|
|
132
|
-
- Exit criteria:
|
|
133
|
-
- `INV-011` upgraded with docs-to-runtime contract checks.
|
|
134
|
-
|
|
135
|
-
## Lane C (6+ weeks): larger architectural improvements
|
|
136
|
-
|
|
137
|
-
### ROADMAP-C-001 Compatibility contract suite and deprecation policy
|
|
138
|
-
- Problem: backward compatibility posture is implicit.
|
|
139
|
-
- Rationale: stabilizes external contract and release risk.
|
|
140
|
-
- Proposed change:
|
|
141
|
-
- Introduce contract-test suite + semver/deprecation policy doc for API behavior.
|
|
142
|
-
- Files touched:
|
|
143
|
-
- new compatibility tests under `tests/`.
|
|
144
|
-
- docs policy section under `docs/`.
|
|
145
|
-
- Tests to add/update:
|
|
146
|
-
- Golden response tests for core endpoints and error envelopes.
|
|
147
|
-
- Rollback plan:
|
|
148
|
-
- Keep compatibility suite as non-blocking for one cycle before enforcing.
|
|
149
|
-
- Exit criteria:
|
|
150
|
-
- Explicit compatibility guarantees published and CI-enforced.
|
|
151
|
-
|
|
152
|
-
### ROADMAP-C-002 Operational observability hardening
|
|
153
|
-
- Problem: limited invariant-level telemetry and correlation IDs for unexpected errors.
|
|
154
|
-
- Rationale: improves incident detectability and MTTR.
|
|
155
|
-
- Proposed change:
|
|
156
|
-
- Add structured error IDs, invariant tags, and optional query performance telemetry hooks.
|
|
157
|
-
- Files touched:
|
|
158
|
-
- [express-plugin.js](/home/merc/Development/current/json-rest-api/plugins/core/connectors/express-plugin.js)
|
|
159
|
-
- selected method/common hook modules.
|
|
160
|
-
- Tests to add/update:
|
|
161
|
-
- Assertions for correlation IDs and stable structured log fields in failure paths.
|
|
162
|
-
- Rollback plan:
|
|
163
|
-
- Keep telemetry additions behind config flags to avoid log-volume shocks.
|
|
164
|
-
- Exit criteria:
|
|
165
|
-
- Detectability score improvements in next audit cycle.
|
|
166
|
-
|
|
167
|
-
## Invariant-to-roadmap coverage check
|
|
168
|
-
- Failed invariants:
|
|
169
|
-
- `INV-001` -> `ROADMAP-A-001`
|
|
170
|
-
- `INV-008` -> `ROADMAP-A-001`, `ROADMAP-B-002`
|
|
171
|
-
- Partial invariants with direct roadmap items:
|
|
172
|
-
- `INV-004` -> `ROADMAP-A-003`
|
|
173
|
-
- `INV-007` -> `ROADMAP-B-003`
|
|
174
|
-
- `INV-009` -> `ROADMAP-B-004`
|
|
175
|
-
- `INV-010` -> `ROADMAP-A-002`, `ROADMAP-B-001`
|
|
176
|
-
- `INV-011` -> `ROADMAP-B-005`
|
|
177
|
-
- `INV-012` -> `ROADMAP-A-003`, `ROADMAP-B-003`, `ROADMAP-C-001`
|
|
@@ -1,23 +0,0 @@
|
|
|
1
|
-
# Signoff Check
|
|
2
|
-
|
|
3
|
-
Generated: 2026-03-01 (local run)
|
|
4
|
-
|
|
5
|
-
## Metric snapshot
|
|
6
|
-
- Critical files total: 66
|
|
7
|
-
- Critical pass1 yes: 66
|
|
8
|
-
- Critical pass2 yes: 66
|
|
9
|
-
- Invariant statuses: pass=4, fail=2, partial=6, unknown=0
|
|
10
|
-
- High severity risks: 1
|
|
11
|
-
- High severity risks with mitigation+verification: 1
|
|
12
|
-
|
|
13
|
-
## Final signoff criteria
|
|
14
|
-
1. 100% critical-file dual-pass coverage: PASS
|
|
15
|
-
2. 100% invariants not left unknown: PASS
|
|
16
|
-
3. 100% high-severity risks have mitigation + verification test: PASS
|
|
17
|
-
4. Standards and competitor matrices complete with evidence: PASS
|
|
18
|
-
5. Prioritized roadmap complete with exit criteria: PASS
|
|
19
|
-
6. Final report includes residual risk and confidence summary: PASS
|
|
20
|
-
|
|
21
|
-
## Notes
|
|
22
|
-
- Criteria 4-6 are document-completeness checks validated against `audit/04-08` and `audit/06` content.
|
|
23
|
-
- anyapi-specific paths were excluded from all scoring conclusions.
|
|
@@ -1,29 +0,0 @@
|
|
|
1
|
-
# Final Executive + Technical Synthesis (non-anyapi)
|
|
2
|
-
|
|
3
|
-
## Executive summary
|
|
4
|
-
- Overall architecture quality is solid, modular, and extensible, but current release risk is not low due to one runtime-confirmed high-severity defect in relationship PATCH failure handling.
|
|
5
|
-
- Test breadth is strong (324 passing tests in `json-rest-api`), but there are active failures (2 positioning tests) and one schema-side contract test failure.
|
|
6
|
-
- Standards alignment is mixed: core behavior is mostly consistent, but error envelope and failure-path consistency gaps remain.
|
|
7
|
-
- Competitive position is strong versus serializer-only libraries on end-to-end server capabilities, with weaker reliability posture on edge failure semantics.
|
|
8
|
-
|
|
9
|
-
## Technical summary
|
|
10
|
-
- Invariants: `4 pass`, `2 fail`, `6 partial`, `0 unknown`.
|
|
11
|
-
- Highest-risk issue:
|
|
12
|
-
- `RISK-001` (`severity_score=80`, `C5`): `patchRelationship` catch path references undefined handler.
|
|
13
|
-
- Additional material issues:
|
|
14
|
-
- positioning multifilter edge failures,
|
|
15
|
-
- schema export/test contract drift,
|
|
16
|
-
- error envelope inconsistency,
|
|
17
|
-
- performance guardrail gaps for include query counts.
|
|
18
|
-
|
|
19
|
-
## Residual risk
|
|
20
|
-
- Remaining uncertainty is concentrated in load/performance and bypass-matrix depth, not in baseline CRUD correctness.
|
|
21
|
-
- Residual risk level: **moderate** after immediate fixes; **high** if `RISK-001` remains unresolved.
|
|
22
|
-
|
|
23
|
-
## Confidence summary
|
|
24
|
-
- High confidence (`C4-C5`) for primary defects and major architecture assertions (code + runtime corroboration).
|
|
25
|
-
- Medium confidence (`C3`) for performance and security posture under production-scale scenario classes not fully load-tested.
|
|
26
|
-
|
|
27
|
-
## Go/No-go recommendation
|
|
28
|
-
- **No-go for strict production hardening** until `ROADMAP-A-001` and `ROADMAP-A-002` are complete.
|
|
29
|
-
- **Conditional go for controlled environments** if relationship PATCH endpoint is not exposed and known failures are accepted short-term.
|
|
@@ -1,168 +0,0 @@
|
|
|
1
|
-
AGENTS.md
|
|
2
|
-
CLAUDE.md
|
|
3
|
-
CRUSH.md
|
|
4
|
-
LICENSE
|
|
5
|
-
README.md
|
|
6
|
-
TODO.todo
|
|
7
|
-
audit/evidence/code/all-files-json-rest-api.txt
|
|
8
|
-
connectors_ideas/fastify.js
|
|
9
|
-
connectors_ideas/koa-plugin.js
|
|
10
|
-
docs/API.md
|
|
11
|
-
docs/COMPARISON.md
|
|
12
|
-
docs/GUIDE/GUIDE_1_Initial_Setup.md
|
|
13
|
-
docs/GUIDE/GUIDE_2_1_The_Starting_Point.md
|
|
14
|
-
docs/GUIDE/GUIDE_2_2_Manipulating_And_Searching_Tables.md
|
|
15
|
-
docs/GUIDE/GUIDE_2_3_BelongsTo_Relationships.md
|
|
16
|
-
docs/GUIDE/GUIDE_2_4_HasMany_Records.md
|
|
17
|
-
docs/GUIDE/GUIDE_2_5_HasMany_Polymorphic.md
|
|
18
|
-
docs/GUIDE/GUIDE_2_6_Many_To_Many.md
|
|
19
|
-
docs/GUIDE/GUIDE_2_7_Pagination_And_Ordering.md
|
|
20
|
-
docs/GUIDE/GUIDE_2_8_Effects_of_PUT_and_PATCH.md
|
|
21
|
-
docs/GUIDE/GUIDE_2_9_Relationships_Urls.md
|
|
22
|
-
docs/GUIDE/GUIDE_2_Data_And_Relations.md
|
|
23
|
-
docs/GUIDE/GUIDE_3_Field_Transformations.md
|
|
24
|
-
docs/GUIDE/GUIDE_4_Authentication_And_Permissions.md
|
|
25
|
-
docs/GUIDE/GUIDE_5_Non-Db_Resources.md
|
|
26
|
-
docs/GUIDE/GUIDE_6_Positioning.md
|
|
27
|
-
docs/GUIDE/GUIDE_7_Hooks_Data_Management_And_Plugins.md
|
|
28
|
-
docs/GUIDE/GUIDE_X_Bulk_Operations.md
|
|
29
|
-
docs/GUIDE/GUIDE_X_Cors.md
|
|
30
|
-
docs/GUIDE/GUIDE_X_File_Uploads.md
|
|
31
|
-
docs/GUIDE/GUIDE_X_Multihome.md
|
|
32
|
-
docs/GUIDE/GUIDE_X_SocketIO.md
|
|
33
|
-
docs/GUIDE/GUIDE_X_URL_Management.md
|
|
34
|
-
docs/GUIDE/GUIDE_Y_Appendices.md
|
|
35
|
-
docs/GUIDE/index.md
|
|
36
|
-
docs/Gemfile
|
|
37
|
-
docs/Gemfile.lock
|
|
38
|
-
docs/ONBOARDING.md
|
|
39
|
-
docs/QUICKSTART.md
|
|
40
|
-
docs/_config.yml
|
|
41
|
-
docs/_layouts/default.html
|
|
42
|
-
docs/apple-touch-icon.svg
|
|
43
|
-
docs/assets/css/style.scss
|
|
44
|
-
docs/favicon.svg
|
|
45
|
-
docs/index.md
|
|
46
|
-
docs/mini-guides/file-uploads-complete.md
|
|
47
|
-
eslint.config.js
|
|
48
|
-
examples/url-override-example.js
|
|
49
|
-
index.js
|
|
50
|
-
lib/enhanced-logger.js
|
|
51
|
-
lib/error-formatter.js
|
|
52
|
-
lib/rest-api-errors.js
|
|
53
|
-
package-lock.json
|
|
54
|
-
package.json
|
|
55
|
-
plugins/core/bulk-operations-plugin.js
|
|
56
|
-
plugins/core/connectors/express-plugin.js
|
|
57
|
-
plugins/core/connectors/lib/busboy-detector.js
|
|
58
|
-
plugins/core/connectors/lib/formidable-detector.js
|
|
59
|
-
plugins/core/connectors/lib/request-helpers.js
|
|
60
|
-
plugins/core/file-handling-plugin.js
|
|
61
|
-
plugins/core/lib/anyapi/anyapi-registry.js
|
|
62
|
-
plugins/core/lib/anyapi/query/anyapi-query-adapter.js
|
|
63
|
-
plugins/core/lib/anyapi/schema-utils.js
|
|
64
|
-
plugins/core/lib/anyapi/utils/descriptor-helpers.js
|
|
65
|
-
plugins/core/lib/dbTablesOperations.js
|
|
66
|
-
plugins/core/lib/fractional-positioning.js
|
|
67
|
-
plugins/core/lib/querying-writing/compile-schemas.js
|
|
68
|
-
plugins/core/lib/querying-writing/connectors-query-parser.js
|
|
69
|
-
plugins/core/lib/querying-writing/database-capabilities.js
|
|
70
|
-
plugins/core/lib/querying-writing/database-value-normalizers.js
|
|
71
|
-
plugins/core/lib/querying-writing/default-data-helpers.js
|
|
72
|
-
plugins/core/lib/querying-writing/field-utils.js
|
|
73
|
-
plugins/core/lib/querying-writing/knex-constants.js
|
|
74
|
-
plugins/core/lib/querying-writing/knex-field-helpers.js
|
|
75
|
-
plugins/core/lib/querying-writing/knex-json-api-transformers.js
|
|
76
|
-
plugins/core/lib/querying-writing/payload-validators.js
|
|
77
|
-
plugins/core/lib/querying-writing/schema-helpers.js
|
|
78
|
-
plugins/core/lib/querying-writing/scope-validations.js
|
|
79
|
-
plugins/core/lib/querying-writing/simplified-helpers.js
|
|
80
|
-
plugins/core/lib/querying/knex-cross-table-search.js
|
|
81
|
-
plugins/core/lib/querying/knex-json-api-transformers-querying.js
|
|
82
|
-
plugins/core/lib/querying/knex-pagination-helpers.js
|
|
83
|
-
plugins/core/lib/querying/knex-process-includes.js
|
|
84
|
-
plugins/core/lib/querying/knex-query-helpers-base.js
|
|
85
|
-
plugins/core/lib/querying/knex-query-helpers.js
|
|
86
|
-
plugins/core/lib/querying/knex-relationship-includes.js
|
|
87
|
-
plugins/core/lib/querying/knex-window-queries.js
|
|
88
|
-
plugins/core/lib/querying/url-helpers.js
|
|
89
|
-
plugins/core/lib/storage/storage-adapter.js
|
|
90
|
-
plugins/core/lib/writing/knex-json-api-transformers-writing.js
|
|
91
|
-
plugins/core/lib/writing/many-to-many-manipulations.js
|
|
92
|
-
plugins/core/lib/writing/relationship-processor.js
|
|
93
|
-
plugins/core/rest-api-access.js
|
|
94
|
-
plugins/core/rest-api-anyapi-knex-plugin.js
|
|
95
|
-
plugins/core/rest-api-cors-plugin.js
|
|
96
|
-
plugins/core/rest-api-knex-plugin.js
|
|
97
|
-
plugins/core/rest-api-label-plugin.js
|
|
98
|
-
plugins/core/rest-api-multihome-plugin.js
|
|
99
|
-
plugins/core/rest-api-plugin-hooks/compile-resource-schemas.js
|
|
100
|
-
plugins/core/rest-api-plugin-hooks/register-relationship-routes.js
|
|
101
|
-
plugins/core/rest-api-plugin-hooks/register-scope-routes.js
|
|
102
|
-
plugins/core/rest-api-plugin-hooks/turn-scope-init-into-vars.js
|
|
103
|
-
plugins/core/rest-api-plugin-hooks/validate-include-configurations.js
|
|
104
|
-
plugins/core/rest-api-plugin-methods/add-route.js
|
|
105
|
-
plugins/core/rest-api-plugin-methods/check-permissions.js
|
|
106
|
-
plugins/core/rest-api-plugin-methods/common.js
|
|
107
|
-
plugins/core/rest-api-plugin-methods/delete-relationship.js
|
|
108
|
-
plugins/core/rest-api-plugin-methods/delete.js
|
|
109
|
-
plugins/core/rest-api-plugin-methods/enrich-attributes.js
|
|
110
|
-
plugins/core/rest-api-plugin-methods/get-related.js
|
|
111
|
-
plugins/core/rest-api-plugin-methods/get-relationship.js
|
|
112
|
-
plugins/core/rest-api-plugin-methods/get.js
|
|
113
|
-
plugins/core/rest-api-plugin-methods/patch-relationship.js
|
|
114
|
-
plugins/core/rest-api-plugin-methods/patch.js
|
|
115
|
-
plugins/core/rest-api-plugin-methods/post-relationship.js
|
|
116
|
-
plugins/core/rest-api-plugin-methods/post.js
|
|
117
|
-
plugins/core/rest-api-plugin-methods/put.js
|
|
118
|
-
plugins/core/rest-api-plugin-methods/query.js
|
|
119
|
-
plugins/core/rest-api-plugin-methods/release.js
|
|
120
|
-
plugins/core/rest-api-plugin.js
|
|
121
|
-
plugins/core/rest-api-positioning-plugin.js
|
|
122
|
-
plugins/core/socketio-plugin.js
|
|
123
|
-
plugins/storage/local-storage.js
|
|
124
|
-
plugins/storage/s3-storage.js
|
|
125
|
-
quickTest.js
|
|
126
|
-
scripts/debug-anyapi-review-filter.mjs
|
|
127
|
-
scripts/inspect-anyapi-descriptor-country.mjs
|
|
128
|
-
scripts/inspect-anyapi-descriptor.mjs
|
|
129
|
-
scripts/run-docs.js
|
|
130
|
-
test-debug.js
|
|
131
|
-
tests/README.md
|
|
132
|
-
tests/TEST_TEMPLATE.test.js
|
|
133
|
-
tests/anyapi-basic.test.js
|
|
134
|
-
tests/anyapi-cursor-pagination.test.js
|
|
135
|
-
tests/bulk-operations.test.js
|
|
136
|
-
tests/computed-fields.test.js
|
|
137
|
-
tests/cors.test.js
|
|
138
|
-
tests/curl.test.js
|
|
139
|
-
tests/custom-idproperty-relationships.test.js
|
|
140
|
-
tests/field-getters.test.js
|
|
141
|
-
tests/field-setters.test.js
|
|
142
|
-
tests/fixtures/api-configs.js
|
|
143
|
-
tests/helpers/storage-mode.js
|
|
144
|
-
tests/helpers/test-utils.js
|
|
145
|
-
tests/include-depth-validation.test.js
|
|
146
|
-
tests/includes.test.js
|
|
147
|
-
tests/multihome.test.js
|
|
148
|
-
tests/multihome.test.js.bak
|
|
149
|
-
tests/nested-includes.test.js
|
|
150
|
-
tests/ownership-optout.test.js
|
|
151
|
-
tests/pagination-cursor-multifield.test.js
|
|
152
|
-
tests/pagination-enhanced.test.js
|
|
153
|
-
tests/polymorphic-relationships.test.js
|
|
154
|
-
tests/polymorphic-simple.test.js
|
|
155
|
-
tests/positioning-advanced.test.js
|
|
156
|
-
tests/positioning-extended.test.js
|
|
157
|
-
tests/positioning-multifilter.test.js
|
|
158
|
-
tests/positioning.test.js
|
|
159
|
-
tests/queries.test.js
|
|
160
|
-
tests/query-limits.test.js
|
|
161
|
-
tests/relationship-endpoints.test.js
|
|
162
|
-
tests/relationships.test.js
|
|
163
|
-
tests/rest-api-access.test.js
|
|
164
|
-
tests/rest-api.test.js
|
|
165
|
-
tests/searchschema-merge.test.js
|
|
166
|
-
tests/socketio.test.js
|
|
167
|
-
tests/test-development-guide.md
|
|
168
|
-
tests/virtual-fields.test.js
|