@techspokes/typescript-wsdl-client 1.1.3 → 1.1.5
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/README.md +50 -1
- package/dist/app/generateApp.d.ts.map +1 -1
- package/dist/app/generateApp.js +8 -6
- package/dist/cli.js +49 -5
- package/dist/client/checkedDirectRuntime.d.ts +59 -0
- package/dist/client/checkedDirectRuntime.d.ts.map +1 -0
- package/dist/client/checkedDirectRuntime.js +23 -0
- package/dist/client/directClientRuntime.d.ts +49 -0
- package/dist/client/directClientRuntime.d.ts.map +1 -0
- package/dist/client/directClientRuntime.js +112 -0
- package/dist/client/directClientVersion.d.ts +4 -0
- package/dist/client/directClientVersion.d.ts.map +1 -0
- package/dist/client/directClientVersion.js +3 -0
- package/dist/client/generateClient.d.ts.map +1 -1
- package/dist/client/generateClient.js +22 -9
- package/dist/client/generateDirectClient.d.ts +14 -0
- package/dist/client/generateDirectClient.d.ts.map +1 -0
- package/dist/client/generateDirectClient.js +136 -0
- package/dist/compiler/buildCanonicalGraph.d.ts +7 -0
- package/dist/compiler/buildCanonicalGraph.d.ts.map +1 -0
- package/dist/compiler/buildCanonicalGraph.js +381 -0
- package/dist/compiler/canonicalGraph.d.ts +198 -0
- package/dist/compiler/canonicalGraph.d.ts.map +1 -0
- package/dist/compiler/canonicalGraph.js +37 -0
- package/dist/compiler/catalogErrors.d.ts +18 -0
- package/dist/compiler/catalogErrors.d.ts.map +1 -0
- package/dist/compiler/catalogErrors.js +86 -0
- package/dist/compiler/catalogProvenance.d.ts +15 -0
- package/dist/compiler/catalogProvenance.d.ts.map +1 -0
- package/dist/compiler/catalogProvenance.js +229 -0
- package/dist/compiler/checkedAssessment.d.ts +91 -0
- package/dist/compiler/checkedAssessment.d.ts.map +1 -0
- package/dist/compiler/checkedAssessment.js +300 -0
- package/dist/compiler/checkedSourcePreparation.d.ts +35 -0
- package/dist/compiler/checkedSourcePreparation.d.ts.map +1 -0
- package/dist/compiler/checkedSourcePreparation.js +131 -0
- package/dist/compiler/complexTypeContent.d.ts +59 -0
- package/dist/compiler/complexTypeContent.d.ts.map +1 -0
- package/dist/compiler/complexTypeContent.js +558 -0
- package/dist/compiler/composeCanonicalGraph.d.ts +69 -0
- package/dist/compiler/composeCanonicalGraph.d.ts.map +1 -0
- package/dist/compiler/composeCanonicalGraph.js +252 -0
- package/dist/compiler/dataOwnership.d.ts +22 -0
- package/dist/compiler/dataOwnership.d.ts.map +1 -0
- package/dist/compiler/dataOwnership.js +157 -0
- package/dist/compiler/datatypeValues.d.ts +47 -0
- package/dist/compiler/datatypeValues.d.ts.map +1 -0
- package/dist/compiler/datatypeValues.js +275 -0
- package/dist/compiler/directCodec.d.ts +59 -0
- package/dist/compiler/directCodec.d.ts.map +1 -0
- package/dist/compiler/directCodec.js +192 -0
- package/dist/compiler/directExecutionPolicy.d.ts +10 -0
- package/dist/compiler/directExecutionPolicy.d.ts.map +1 -0
- package/dist/compiler/directExecutionPolicy.js +17 -0
- package/dist/compiler/directOperation.d.ts +72 -0
- package/dist/compiler/directOperation.d.ts.map +1 -0
- package/dist/compiler/directOperation.js +282 -0
- package/dist/compiler/directSoap.d.ts +42 -0
- package/dist/compiler/directSoap.d.ts.map +1 -0
- package/dist/compiler/directSoap.js +298 -0
- package/dist/compiler/directSoapSource.d.ts +15 -0
- package/dist/compiler/directSoapSource.d.ts.map +1 -0
- package/dist/compiler/directSoapSource.js +86 -0
- package/dist/compiler/directSourceCapsule.d.ts +97 -0
- package/dist/compiler/directSourceCapsule.d.ts.map +1 -0
- package/dist/compiler/directSourceCapsule.js +305 -0
- package/dist/compiler/directStructure.d.ts +51 -0
- package/dist/compiler/directStructure.d.ts.map +1 -0
- package/dist/compiler/directStructure.js +252 -0
- package/dist/compiler/directStructurePlan.d.ts +16 -0
- package/dist/compiler/directStructurePlan.d.ts.map +1 -0
- package/dist/compiler/directStructurePlan.js +58 -0
- package/dist/compiler/directValues.d.ts +69 -0
- package/dist/compiler/directValues.d.ts.map +1 -0
- package/dist/compiler/directValues.js +282 -0
- package/dist/compiler/finiteRe01Verification.d.ts +140 -0
- package/dist/compiler/finiteRe01Verification.d.ts.map +1 -0
- package/dist/compiler/finiteRe01Verification.js +830 -0
- package/dist/compiler/graphTraversal.d.ts +11 -0
- package/dist/compiler/graphTraversal.d.ts.map +1 -0
- package/dist/compiler/graphTraversal.js +37 -0
- package/dist/compiler/hypotheticalScopedIdentity.d.ts +23 -0
- package/dist/compiler/hypotheticalScopedIdentity.d.ts.map +1 -0
- package/dist/compiler/hypotheticalScopedIdentity.js +81 -0
- package/dist/compiler/occurrenceAnalysis.d.ts +65 -0
- package/dist/compiler/occurrenceAnalysis.d.ts.map +1 -0
- package/dist/compiler/occurrenceAnalysis.js +300 -0
- package/dist/compiler/originalSourceMembership.d.ts +6 -0
- package/dist/compiler/originalSourceMembership.d.ts.map +1 -0
- package/dist/compiler/originalSourceMembership.js +31 -0
- package/dist/compiler/particleAttribution.d.ts +17 -0
- package/dist/compiler/particleAttribution.d.ts.map +1 -0
- package/dist/compiler/particleAttribution.js +474 -0
- package/dist/compiler/particleDeclarationConsistency.d.ts +24 -0
- package/dist/compiler/particleDeclarationConsistency.d.ts.map +1 -0
- package/dist/compiler/particleDeclarationConsistency.js +197 -0
- package/dist/compiler/particleExtension.d.ts +22 -0
- package/dist/compiler/particleExtension.d.ts.map +1 -0
- package/dist/compiler/particleExtension.js +119 -0
- package/dist/compiler/particleLocalAssessment.d.ts +20 -0
- package/dist/compiler/particleLocalAssessment.d.ts.map +1 -0
- package/dist/compiler/particleLocalAssessment.js +92 -0
- package/dist/compiler/particleRestriction.d.ts +24 -0
- package/dist/compiler/particleRestriction.d.ts.map +1 -0
- package/dist/compiler/particleRestriction.js +489 -0
- package/dist/compiler/particleSemanticView.d.ts +50 -0
- package/dist/compiler/particleSemanticView.d.ts.map +1 -0
- package/dist/compiler/particleSemanticView.js +297 -0
- package/dist/compiler/particleWildcardRelation.d.ts +88 -0
- package/dist/compiler/particleWildcardRelation.d.ts.map +1 -0
- package/dist/compiler/particleWildcardRelation.js +143 -0
- package/dist/compiler/re01CandidateCorrespondence.d.ts +64 -0
- package/dist/compiler/re01CandidateCorrespondence.d.ts.map +1 -0
- package/dist/compiler/re01CandidateCorrespondence.js +572 -0
- package/dist/compiler/re01TypeProperties.d.ts +71 -0
- package/dist/compiler/re01TypeProperties.d.ts.map +1 -0
- package/dist/compiler/re01TypeProperties.js +120 -0
- package/dist/compiler/re01TypePropertyValidation.d.ts +23 -0
- package/dist/compiler/re01TypePropertyValidation.d.ts.map +1 -0
- package/dist/compiler/re01TypePropertyValidation.js +161 -0
- package/dist/compiler/resolveCanonicalGraph.d.ts +38 -0
- package/dist/compiler/resolveCanonicalGraph.d.ts.map +1 -0
- package/dist/compiler/resolveCanonicalGraph.js +170 -0
- package/dist/compiler/scalarSchemaAssessment.d.ts +425 -0
- package/dist/compiler/scalarSchemaAssessment.d.ts.map +1 -0
- package/dist/compiler/scalarSchemaAssessment.js +5198 -0
- package/dist/compiler/schemaAttributeGroupProperties.d.ts +17 -0
- package/dist/compiler/schemaAttributeGroupProperties.d.ts.map +1 -0
- package/dist/compiler/schemaAttributeGroupProperties.js +53 -0
- package/dist/compiler/schemaAttributeProperties.d.ts +10 -0
- package/dist/compiler/schemaAttributeProperties.d.ts.map +1 -0
- package/dist/compiler/schemaAttributeProperties.js +11 -0
- package/dist/compiler/schemaAttributeUses.d.ts +90 -0
- package/dist/compiler/schemaAttributeUses.d.ts.map +1 -0
- package/dist/compiler/schemaAttributeUses.js +725 -0
- package/dist/compiler/schemaBinaryWordReconstruction.d.ts +10 -0
- package/dist/compiler/schemaBinaryWordReconstruction.d.ts.map +1 -0
- package/dist/compiler/schemaBinaryWordReconstruction.js +33 -0
- package/dist/compiler/schemaBuiltinFacets.d.ts +14 -0
- package/dist/compiler/schemaBuiltinFacets.d.ts.map +1 -0
- package/dist/compiler/schemaBuiltinFacets.js +51 -0
- package/dist/compiler/schemaCalendarImages.d.ts +8 -0
- package/dist/compiler/schemaCalendarImages.d.ts.map +1 -0
- package/dist/compiler/schemaCalendarImages.js +204 -0
- package/dist/compiler/schemaCalendarLanguage.d.ts +11 -0
- package/dist/compiler/schemaCalendarLanguage.d.ts.map +1 -0
- package/dist/compiler/schemaCalendarLanguage.js +227 -0
- package/dist/compiler/schemaComponentEquality.d.ts +28 -0
- package/dist/compiler/schemaComponentEquality.d.ts.map +1 -0
- package/dist/compiler/schemaComponentEquality.js +446 -0
- package/dist/compiler/schemaConstructionAssessment.d.ts +46 -0
- package/dist/compiler/schemaConstructionAssessment.d.ts.map +1 -0
- package/dist/compiler/schemaConstructionAssessment.js +663 -0
- package/dist/compiler/schemaDatatypeValues.d.ts +4 -0
- package/dist/compiler/schemaDatatypeValues.d.ts.map +1 -0
- package/dist/compiler/schemaDatatypeValues.js +2 -0
- package/dist/compiler/schemaDecimalLanguage.d.ts +7 -0
- package/dist/compiler/schemaDecimalLanguage.d.ts.map +1 -0
- package/dist/compiler/schemaDecimalLanguage.js +102 -0
- package/dist/compiler/schemaDeclarationPrimitives.d.ts +34 -0
- package/dist/compiler/schemaDeclarationPrimitives.d.ts.map +1 -0
- package/dist/compiler/schemaDeclarationPrimitives.js +194 -0
- package/dist/compiler/schemaDocumentSyntax.d.ts +55 -0
- package/dist/compiler/schemaDocumentSyntax.d.ts.map +1 -0
- package/dist/compiler/schemaDocumentSyntax.js +294 -0
- package/dist/compiler/schemaDurationLanguage.d.ts +11 -0
- package/dist/compiler/schemaDurationLanguage.d.ts.map +1 -0
- package/dist/compiler/schemaDurationLanguage.js +170 -0
- package/dist/compiler/schemaElementProperties.d.ts +16 -0
- package/dist/compiler/schemaElementProperties.d.ts.map +1 -0
- package/dist/compiler/schemaElementProperties.js +23 -0
- package/dist/compiler/schemaEndpointWordCapacity.d.ts +36 -0
- package/dist/compiler/schemaEndpointWordCapacity.d.ts.map +1 -0
- package/dist/compiler/schemaEndpointWordCapacity.js +39 -0
- package/dist/compiler/schemaExactCalendar.d.ts +73 -0
- package/dist/compiler/schemaExactCalendar.d.ts.map +1 -0
- package/dist/compiler/schemaExactCalendar.js +264 -0
- package/dist/compiler/schemaFacetAnnotation.d.ts +32 -0
- package/dist/compiler/schemaFacetAnnotation.d.ts.map +1 -0
- package/dist/compiler/schemaFacetAnnotation.js +199 -0
- package/dist/compiler/schemaGeneratedScalarShape.d.ts +35 -0
- package/dist/compiler/schemaGeneratedScalarShape.d.ts.map +1 -0
- package/dist/compiler/schemaGeneratedScalarShape.js +176 -0
- package/dist/compiler/schemaIdentityConstraints.d.ts +73 -0
- package/dist/compiler/schemaIdentityConstraints.d.ts.map +1 -0
- package/dist/compiler/schemaIdentityConstraints.js +362 -0
- package/dist/compiler/schemaIeeeLanguage.d.ts +43 -0
- package/dist/compiler/schemaIeeeLanguage.d.ts.map +1 -0
- package/dist/compiler/schemaIeeeLanguage.js +759 -0
- package/dist/compiler/schemaIntegerImages.d.ts +11 -0
- package/dist/compiler/schemaIntegerImages.d.ts.map +1 -0
- package/dist/compiler/schemaIntegerImages.js +113 -0
- package/dist/compiler/schemaLexicalPredicates.d.ts +29 -0
- package/dist/compiler/schemaLexicalPredicates.d.ts.map +1 -0
- package/dist/compiler/schemaLexicalPredicates.js +63 -0
- package/dist/compiler/schemaNotationProperties.d.ts +32 -0
- package/dist/compiler/schemaNotationProperties.d.ts.map +1 -0
- package/dist/compiler/schemaNotationProperties.js +84 -0
- package/dist/compiler/schemaNumericImageConditions.d.ts +24 -0
- package/dist/compiler/schemaNumericImageConditions.d.ts.map +1 -0
- package/dist/compiler/schemaNumericImageConditions.js +66 -0
- package/dist/compiler/schemaParticleWildcardProperties.d.ts +20 -0
- package/dist/compiler/schemaParticleWildcardProperties.d.ts.map +1 -0
- package/dist/compiler/schemaParticleWildcardProperties.js +43 -0
- package/dist/compiler/schemaPattern.d.ts +1062 -0
- package/dist/compiler/schemaPattern.d.ts.map +1 -0
- package/dist/compiler/schemaPattern.js +581 -0
- package/dist/compiler/schemaRegularLanguage.d.ts +67 -0
- package/dist/compiler/schemaRegularLanguage.d.ts.map +1 -0
- package/dist/compiler/schemaRegularLanguage.js +1166 -0
- package/dist/compiler/schemaScalarContext.d.ts +81 -0
- package/dist/compiler/schemaScalarContext.d.ts.map +1 -0
- package/dist/compiler/schemaScalarContext.js +78 -0
- package/dist/compiler/schemaScalarKernel.d.ts +182 -0
- package/dist/compiler/schemaScalarKernel.d.ts.map +1 -0
- package/dist/compiler/schemaScalarKernel.js +391 -0
- package/dist/compiler/schemaScalarWitnesses.d.ts +6 -0
- package/dist/compiler/schemaScalarWitnesses.d.ts.map +1 -0
- package/dist/compiler/schemaScalarWitnesses.js +118 -0
- package/dist/compiler/schemaSimpleTypeProperties.d.ts +95 -0
- package/dist/compiler/schemaSimpleTypeProperties.d.ts.map +1 -0
- package/dist/compiler/schemaSimpleTypeProperties.js +103 -0
- package/dist/compiler/schemaSourceGrammar.d.ts +27 -0
- package/dist/compiler/schemaSourceGrammar.d.ts.map +1 -0
- package/dist/compiler/schemaSourceGrammar.js +290 -0
- package/dist/compiler/schemaSourceLexical.d.ts +4 -0
- package/dist/compiler/schemaSourceLexical.d.ts.map +1 -0
- package/dist/compiler/schemaSourceLexical.js +12 -0
- package/dist/compiler/schemaSourceValues.d.ts +51 -0
- package/dist/compiler/schemaSourceValues.d.ts.map +1 -0
- package/dist/compiler/schemaSourceValues.js +225 -0
- package/dist/compiler/schemaSourceWildcards.d.ts +28 -0
- package/dist/compiler/schemaSourceWildcards.d.ts.map +1 -0
- package/dist/compiler/schemaSourceWildcards.js +247 -0
- package/dist/compiler/schemaSymbolicSequences.d.ts +16 -0
- package/dist/compiler/schemaSymbolicSequences.d.ts.map +1 -0
- package/dist/compiler/schemaSymbolicSequences.js +99 -0
- package/dist/compiler/schemaSymbolicValueSets.d.ts +32 -0
- package/dist/compiler/schemaSymbolicValueSets.d.ts.map +1 -0
- package/dist/compiler/schemaSymbolicValueSets.js +149 -0
- package/dist/compiler/schemaSyntaxAssessment.d.ts +25 -0
- package/dist/compiler/schemaSyntaxAssessment.d.ts.map +1 -0
- package/dist/compiler/schemaSyntaxAssessment.js +361 -0
- package/dist/compiler/schemaTemporalAliases.d.ts +6 -0
- package/dist/compiler/schemaTemporalAliases.d.ts.map +1 -0
- package/dist/compiler/schemaTemporalAliases.js +195 -0
- package/dist/compiler/schemaTokenImages.d.ts +9 -0
- package/dist/compiler/schemaTokenImages.d.ts.map +1 -0
- package/dist/compiler/schemaTokenImages.js +142 -0
- package/dist/compiler/schemaTypeIdentity.d.ts +39 -0
- package/dist/compiler/schemaTypeIdentity.d.ts.map +1 -0
- package/dist/compiler/schemaTypeIdentity.js +78 -0
- package/dist/compiler/schemaTypeRelations.d.ts +38 -0
- package/dist/compiler/schemaTypeRelations.d.ts.map +1 -0
- package/dist/compiler/schemaTypeRelations.js +576 -0
- package/dist/compiler/schemaUri.d.ts +13 -0
- package/dist/compiler/schemaUri.d.ts.map +1 -0
- package/dist/compiler/schemaUri.js +103 -0
- package/dist/compiler/schemaValueContext.d.ts +26 -0
- package/dist/compiler/schemaValueContext.d.ts.map +1 -0
- package/dist/compiler/schemaValueContext.js +1 -0
- package/dist/compiler/schemaValueImages.d.ts +10 -0
- package/dist/compiler/schemaValueImages.d.ts.map +1 -0
- package/dist/compiler/schemaValueImages.js +142 -0
- package/dist/compiler/schemaValueSequences.d.ts +15 -0
- package/dist/compiler/schemaValueSequences.d.ts.map +1 -0
- package/dist/compiler/schemaValueSequences.js +19 -0
- package/dist/compiler/semanticBudget.d.ts +50 -0
- package/dist/compiler/semanticBudget.d.ts.map +1 -0
- package/dist/compiler/semanticBudget.js +178 -0
- package/dist/compiler/semanticCatalog.d.ts +122 -0
- package/dist/compiler/semanticCatalog.d.ts.map +1 -0
- package/dist/compiler/semanticCatalog.js +160 -0
- package/dist/compiler/semanticContext.d.ts +172 -0
- package/dist/compiler/semanticContext.d.ts.map +1 -0
- package/dist/compiler/semanticContext.js +1168 -0
- package/dist/compiler/semanticTypeDependencies.d.ts +8 -0
- package/dist/compiler/semanticTypeDependencies.d.ts.map +1 -0
- package/dist/compiler/semanticTypeDependencies.js +64 -0
- package/dist/compiler/semanticTypeReference.d.ts +24 -0
- package/dist/compiler/semanticTypeReference.d.ts.map +1 -0
- package/dist/compiler/semanticTypeReference.js +36 -0
- package/dist/compiler/shapeResolver.d.ts +1 -0
- package/dist/compiler/shapeResolver.d.ts.map +1 -1
- package/dist/compiler/shapeResolver.js +7 -9
- package/dist/compiler/sourceSchemaBinding.d.ts +26 -0
- package/dist/compiler/sourceSchemaBinding.d.ts.map +1 -0
- package/dist/compiler/sourceSchemaBinding.js +39 -0
- package/dist/compiler/structuralCompanions.d.ts +16 -0
- package/dist/compiler/structuralCompanions.d.ts.map +1 -0
- package/dist/compiler/structuralCompanions.js +232 -0
- package/dist/compiler/validateSemanticGraph.d.ts +5 -0
- package/dist/compiler/validateSemanticGraph.d.ts.map +1 -0
- package/dist/compiler/validateSemanticGraph.js +376 -0
- package/dist/compiler/wildcardAlgebra.d.ts +26 -0
- package/dist/compiler/wildcardAlgebra.d.ts.map +1 -0
- package/dist/compiler/wildcardAlgebra.js +155 -0
- package/dist/gateway/generateGateway.d.ts.map +1 -1
- package/dist/gateway/generateGateway.js +2 -2
- package/dist/index.d.ts +3 -0
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +2 -0
- package/dist/loader/orderedSyntax.d.ts +77 -0
- package/dist/loader/orderedSyntax.d.ts.map +1 -0
- package/dist/loader/orderedSyntax.js +202 -0
- package/dist/loader/resolutionDepth.d.ts +7 -0
- package/dist/loader/resolutionDepth.d.ts.map +1 -0
- package/dist/loader/resolutionDepth.js +65 -0
- package/dist/loader/schemaInput.d.ts +53 -0
- package/dist/loader/schemaInput.d.ts.map +1 -0
- package/dist/loader/schemaInput.js +212 -0
- package/dist/loader/schemaResources.d.ts +59 -0
- package/dist/loader/schemaResources.d.ts.map +1 -0
- package/dist/loader/schemaResources.js +292 -0
- package/dist/openapi/generateOpenAPI.d.ts.map +1 -1
- package/dist/openapi/generateOpenAPI.js +2 -2
- package/dist/test/generateTests.d.ts.map +1 -1
- package/dist/test/generateTests.js +2 -2
- package/dist/util/xmlWhitespace.d.ts +3 -0
- package/dist/util/xmlWhitespace.d.ts.map +1 -0
- package/dist/util/xmlWhitespace.js +4 -0
- package/docs/README.md +14 -1
- package/docs/architecture.md +9 -0
- package/docs/cli-reference.md +21 -1
- package/docs/content-model-analysis.md +92 -0
- package/docs/content-model-baseline.md +121 -0
- package/docs/content-model-catalog.md +116 -0
- package/docs/content-model-companions.md +90 -0
- package/docs/content-model-composition.md +103 -0
- package/docs/content-model-decisions.md +79 -0
- package/docs/content-model-gateway-feasibility.md +169 -0
- package/docs/content-model-graph.md +121 -0
- package/docs/content-model-loading.md +163 -0
- package/docs/content-model-matching.md +85 -0
- package/docs/content-model-readiness.md +144 -0
- package/docs/content-model-resolution.md +81 -0
- package/docs/content-model-s02-handoff.md +98 -0
- package/docs/content-model-s06-au-01.md +425 -0
- package/docs/content-model-s06-dt-01.md +386 -0
- package/docs/content-model-s06-pw-01.md +350 -0
- package/docs/content-model-s06-re-01-resolver-implementation.md +869 -0
- package/docs/content-model-s06-re-01-resolver.md +513 -0
- package/docs/content-model-s06-re-01-scalar-witnesses.md +1423 -0
- package/docs/content-model-s06-re-01-support-reconstruction.md +6337 -0
- package/docs/content-model-s06-re-01.md +7477 -0
- package/docs/content-model-s06-research-handoff.md +909 -0
- package/docs/content-model-shipped-fix.md +83 -0
- package/docs/content-model-soap-feasibility.md +165 -0
- package/docs/decisions/002-streamable-responses.md +2 -0
- package/docs/decisions/003-content-model-contracts.md +280 -0
- package/docs/direct-values.md +311 -0
- package/docs/generated-code.md +4 -0
- package/docs/reference-validation.md +243 -0
- package/docs/releases/v1.1.4.md +36 -0
- package/docs/releases/v1.1.5.md +38 -0
- package/docs/roadmap/README.md +2 -2
- package/docs/supported-patterns.md +13 -5
- package/package.json +27 -13
- package/src/generation/preambles/direct-client/typescript.preamble +3 -0
- package/src/runtime/clientStreamMethods.tpl.txt +1 -1
|
@@ -0,0 +1,169 @@
|
|
|
1
|
+
# Content Model Gateway Feasibility
|
|
2
|
+
|
|
3
|
+
Executed S02 #170 evidence for validation, representation and serialized-byte boundaries. See the root [README](../README.md).
|
|
4
|
+
|
|
5
|
+
## Scope and disposition
|
|
6
|
+
|
|
7
|
+
This bounded probe supports ADR 003's draft-07 runtime and serializer lowering, route-local non-mutating validation, and independently validated JSON serialization fallback. It introduces fixtures and tests only; the current gateway emitter and unrelated host policy remain unchanged.
|
|
8
|
+
|
|
9
|
+
The [ADR](decisions/003-content-model-contracts.md#portable-contracts-and-dialects-s02-d05-s02-d06) defines the architecture; the [decision register](content-model-decisions.md) owns final dispositions. This document records executed observations, primary documentation, unverified combinations and first-consumer gates for #197/#198/#199/#200.
|
|
10
|
+
|
|
11
|
+
## Reproduction and inspected versions
|
|
12
|
+
|
|
13
|
+
The executable corpus is [the gateway feasibility integration test](../test/integration/content-model-gateway-feasibility.test.ts). Its [route helper](../test/helpers/contentModelGatewayProbe.ts) uses installed Ajv and serializer engines, not another schema or semantic engine.
|
|
14
|
+
|
|
15
|
+
The reviewed draft checkpoint was `2f88ec81f77f4fc5a06b78f2d507ae8e20fe7a7c`. The following installed versions were observed after `npm ci --cache tmp/cache/npm` on Node `24.19.0`; the lockfile, rather than package ranges, determines this evidence.
|
|
16
|
+
|
|
17
|
+
| Component | Installed version | Role |
|
|
18
|
+
|---|---|---|
|
|
19
|
+
| Fastify | 5.12.5 | HTTP routes and injection |
|
|
20
|
+
| Ajv | 8.20.0 | Runtime JSON validation |
|
|
21
|
+
| `@fastify/ajv-compiler` | 4.0.6 | Host default validator |
|
|
22
|
+
| `fast-json-stringify` | 7.0.1 | Schema serializer |
|
|
23
|
+
| `@fastify/fast-json-stringify-compiler` | 5.1.0 | Host serializer adapter |
|
|
24
|
+
| `ajv-formats` | 3.0.1 | Installed host format plugin |
|
|
25
|
+
| Vitest | 5.0.3 | Executable evidence |
|
|
26
|
+
| TypeScript | 6.0.3 | Existing integration typecheck |
|
|
27
|
+
|
|
28
|
+
Run the local checks from the repository root:
|
|
29
|
+
|
|
30
|
+
```bash
|
|
31
|
+
npm ci --cache tmp/cache/npm
|
|
32
|
+
npx vitest run test/integration/content-model-gateway-feasibility.test.ts --reporter=verbose
|
|
33
|
+
npm run typecheck:integration
|
|
34
|
+
npm run docs:validate
|
|
35
|
+
npm run test:conformance
|
|
36
|
+
```
|
|
37
|
+
|
|
38
|
+
The integration suite writes `tmp/conformance/content-model-gateway/traces.json`. Each ordinary probe records submitted JSON text, parsed submission, validator-visible values before/after, handler input, returned response, response-validation values, serializer-output values, status and actual HTTP bytes.
|
|
39
|
+
|
|
40
|
+
Missing handler/serializer snapshots mean the request or response was rejected before that boundary. The imported current-emitter fallback has no body validator, so its trace records that boundary as absent rather than inventing validator observations.
|
|
41
|
+
|
|
42
|
+
## Selected dialect boundaries
|
|
43
|
+
|
|
44
|
+
### OpenAPI documentation
|
|
45
|
+
|
|
46
|
+
Select OpenAPI `3.1.1` and its OAS schema dialect based on JSON Schema 2020-12 for future faithful documentation. Primary specification inspection establishes the standard; it does not prove that the installed Fastify runtime or serializer executes every OpenAPI keyword.
|
|
47
|
+
|
|
48
|
+
The [current OpenAPI generator](../src/openapi/generateOpenAPI.ts) emits `openapi: "3.1.0"` and omits `jsonSchemaDialect`; this is source inspection, not an assertion that it already emits the selected `3.1.1` target. The synthetic complexity document in this probe uses `3.1.1` only to test gateway emission from that input.
|
|
49
|
+
|
|
50
|
+
OpenAPI documents representation constraints and supplemental requirements. `x-xsd-fractionDigits` is an annotation: strict route-local Ajv rejects it as unknown; explicitly registering it as annotation-only admits `"1.234"` despite a declared value of two.
|
|
51
|
+
|
|
52
|
+
### Runtime JSON Schema
|
|
53
|
+
|
|
54
|
+
Select draft-07 for the bounded faithful runtime lowering. The installed default Ajv class loads the draft-07 vocabulary and meta-schema; the compiler uses `strict: true`, `coerceTypes: false`, `removeAdditional: false`, `useDefaults: false` and `allErrors: false`.
|
|
55
|
+
|
|
56
|
+
Use route-level `validatorCompiler`; register referenced schemas with that Ajv instance explicitly. Do not change the host's global compiler or Ajv options. The same Fastify instance's control route retains coercion, default insertion and removal of unknown fields.
|
|
57
|
+
|
|
58
|
+
Executed failures establish that a 2020-12 `$schema` cannot compile with this class and that unlabelled `unevaluatedProperties` fails strict compilation. Other modern vocabulary is outside the selected lowering; unknown required capabilities must fail planning or compilation rather than be ignored.
|
|
59
|
+
|
|
60
|
+
### Serializer JSON Schema
|
|
61
|
+
|
|
62
|
+
Select separately emitted draft-07 serializer schemas for the tested closed shapes. Installed `fast-json-stringify` documentation expressly requires draft-07 input; its conversion and branch selection behavior is not complete response validation.
|
|
63
|
+
|
|
64
|
+
Validate returned HTTP JSON before serialization, validate parsed serialized bytes with the same independent runtime plan and shared semantic owner, and compare admitted JSON values for preservation. The probe's serializer wrapper rejects field loss before bytes leave Fastify; it does not repair the value or silently switch backend.
|
|
65
|
+
|
|
66
|
+
Select an explicit route-local `JSON.stringify` fallback when serializer lowering cannot preserve an admitted JSON value or when the configured complexity policy selects fallback. Keep response validation and its references available regardless of serializer selection; a fallback must never remove the validation obligation.
|
|
67
|
+
|
|
68
|
+
## Executed observations
|
|
69
|
+
|
|
70
|
+
### Requests and host control
|
|
71
|
+
|
|
72
|
+
| Case | Route-local observation | Host control observation |
|
|
73
|
+
|---|---|---|
|
|
74
|
+
| Numeric field submitted for string | 400; original field unchanged | Converted to string |
|
|
75
|
+
| Required field with schema default missing | 400; field remains absent | Default inserted |
|
|
76
|
+
| Unknown closed-object property | 400; property remains present | Property removed |
|
|
77
|
+
| Both closed exclusive-choice fields | 400; both fields retained | 200 after removing one field |
|
|
78
|
+
| Valid declared fields | 200; validator and handler values equal submission | Control remains independent |
|
|
79
|
+
|
|
80
|
+
These observations prove that invalid input cannot pass only because validation coerces, inserts defaults or removes fields on the proposed route. They characterize existing Fastify defaults; they do not recommend a global host-policy rewrite.
|
|
81
|
+
|
|
82
|
+
### Structural lowerings
|
|
83
|
+
|
|
84
|
+
| Construct | Executed outcome | Boundary |
|
|
85
|
+
|---|---|---|
|
|
86
|
+
| Closed `oneOf` branches | Valid branch survives bytes; combined branches rejected | Runtime and schema serializer |
|
|
87
|
+
| Overlapping `oneOf` | Both alternatives match; rejected | Runtime |
|
|
88
|
+
| Overlapping `anyOf` | Both fields accepted and preserved | Runtime and JSON fallback |
|
|
89
|
+
| Two empty `oneOf` alternatives | Empty object rejected because both match | Runtime |
|
|
90
|
+
| Two empty `anyOf` alternatives | Empty object accepted and preserved | Runtime and JSON fallback |
|
|
91
|
+
| Nullable array items | `["a",null]` accepted; null wrapper rejected | Runtime and schema serializer |
|
|
92
|
+
| Nullable array wrapper | Null wrapper accepted; `[null]` rejected | Runtime and schema serializer |
|
|
93
|
+
| Recursive `$ref` with nullable child | Nested valid response preserved; nested numeric value rejected | Runtime and schema serializer |
|
|
94
|
+
| Outer object closure with `allOf` requirements | Both declared fields preserved; missing/unknown fields rejected | Runtime and schema serializer |
|
|
95
|
+
| Closed disjoint `allOf` members | Original rejects `{a,b}`; current flattening accepts it | Current helper changes meaning |
|
|
96
|
+
|
|
97
|
+
The draft-07 outer-closure fixture enumerates the complete property set once at its containing object and declares local properties in each required subschema to satisfy Ajv `strictRequired`. A graph-driven lowering must emit the equivalent complete closure; generic merging of arbitrary OpenAPI `allOf` is not an equivalence proof.
|
|
98
|
+
|
|
99
|
+
An XML empty alternative is validated by the shared particle language, not by counting JSON `oneOf` matches. Overlapping or empty JSON alternatives that cannot express that language use a declared lowering plus #180 supplemental validation, with validated JSON fallback where serializer selection is unsuitable.
|
|
100
|
+
|
|
101
|
+
### Scalar and facet boundaries
|
|
102
|
+
|
|
103
|
+
Precision-sensitive int64 `"9223372036854775807"` and decimal `"9007199254740993.12345678901234567890"` survive validator snapshots and HTTP bytes exactly. Numeric substitutions and exponent-form decimal strings are rejected by the string representation schema.
|
|
104
|
+
|
|
105
|
+
Submitting the same digits as JSON numbers loses precision in JSON parsing before the validator sees them. The native-number probe sees `9223372036854776000` and `9007199254740994`; downstream schema validation cannot restore the submitted digits.
|
|
106
|
+
|
|
107
|
+
The reviewed lexical-sensitive witness `"+01.00"` survives response serialization. The fixture's anchored JSON pattern selects that representation and rejects `"1"`; it does not claim arbitrary XSD pattern equivalence or authorize rewriting a facet-constrained lexical witness.
|
|
108
|
+
|
|
109
|
+
Representation-only validation admits `"9223372036854775808"` and decimal `"1.234"`. A separate test-only shared-owner callback uses built-in `BigInt` for int64 bounds and exact textual fractional digits after trailing-zero removal for a two-fractional-digit profile; it rejects upper/lower out-of-range and excess-scale witnesses before handler dispatch and before response serialization, without mutating values.
|
|
110
|
+
|
|
111
|
+
The callback proves an executable supplemental seam, not a production XSD validator. Exact coefficient/scale conversion, totalDigits, all numeric bounds, XSD lexical/value normalization and XSD regex semantics remain owned by #184/#198; no duplicate scalar engine is added here.
|
|
112
|
+
|
|
113
|
+
| Constraint | Independent Ajv evidence | Serializer evidence |
|
|
114
|
+
|---|---|---|
|
|
115
|
+
| `type`, `required`, object closure | Accepted and rejected cases | Approved closed fields preserved |
|
|
116
|
+
| `pattern`, `minLength`, `maxLength` | Request and returned-response failures | Invalid string still serialized without independent validation |
|
|
117
|
+
| Integer `minimum`, `maximum` | Request and returned-response failures | Out-of-range integer still serialized without independent validation |
|
|
118
|
+
| `enum`, `minItems`, `maxItems` | Request and returned-response failures | Invalid array still serialized without independent validation |
|
|
119
|
+
| Exact int64/fractionDigits | Supplemental callback rejects exact witnesses | Callback retained under JSON fallback |
|
|
120
|
+
| `x-xsd-fractionDigits` | Unknown keyword rejected; annotation registration does not enforce | No enforcement claim |
|
|
121
|
+
| XSD particle/regex/QName rules | Injected shared semantic seam only | No enforcement claim |
|
|
122
|
+
|
|
123
|
+
### Response field preservation and complexity fallback
|
|
124
|
+
|
|
125
|
+
An open object schema admits an `approved` field absent from `properties`. The schema serializer omits it, and the proposed preservation boundary returns 500 before output; explicitly selecting validated JSON fallback preserves the nested field and values.
|
|
126
|
+
|
|
127
|
+
The current [gateway emitter](../src/gateway/generators.ts) selects no fallback at 149 reachable schema references and selects fallback at 150. The test imports the actual emitted route module and supplies a local handler for its generated stub; the route registration removes `response` and uses Fastify's JSON serialization fallback.
|
|
128
|
+
|
|
129
|
+
That current emitted route returns both a valid 150-reference response and an invalid numeric/unknown-field response with 200 and unchanged bytes. The proposed adapter retains the same referenced runtime response schema, returns the valid response without field loss and rejects the invalid response before serialization even while using `JSON.stringify`.
|
|
130
|
+
|
|
131
|
+
This broad 150-reference graph proves the existing policy boundary and fallback behavior. It does not measure the serializer's maximum depth, prove a stack overflow at exactly 150, or justify a new resource limit.
|
|
132
|
+
|
|
133
|
+
## Decision-register handoff
|
|
134
|
+
|
|
135
|
+
The following D06 entries resolve architecture choices within the tested scope. Missing implementation and qualification remain blocking gates for their first consumers; they are not claims of already shipped faithful behavior.
|
|
136
|
+
|
|
137
|
+
| Entry | Selected contract | Evidence | First owner and consuming gate |
|
|
138
|
+
|---|---|---|---|
|
|
139
|
+
| D06-OpenAPI | OAS 3.1.1 documentation; separate runtime lowering | Primary standard; current output source inspected | #197 must emit selected dialect and completeness metadata |
|
|
140
|
+
| D06-runtime | Strict non-mutating route-local draft-07 Ajv | Host isolation, structures, facets, modern-keyword failures | #198 validator/compiler plan; #199 request integration |
|
|
141
|
+
| D06-serializer | Separate draft-07 serializer plan; serializer is not validation | Actual byte checks and ordinary facet counterexamples | #197 lowering; #200 preservation validation |
|
|
142
|
+
| D06-fallback | Explicit JSON fallback preserves independent response validation | Imported current emitter and 150-ref proposed route | #200 must retain validation when serializer schema is omitted |
|
|
143
|
+
| D06-supplemental | One shared #180/#184 semantic owner, injected at each boundary | Exact facet callback and fail-closed seam tests | #198 must supply shared rules; #199/#200 must invoke them |
|
|
144
|
+
| D06-closure | Complete graph-derived closure; no generic allOf flattening | Original/flattened meaning differs | #197 lowering proof before #198/#199/#200 consume it |
|
|
145
|
+
|
|
146
|
+
Required blockers are explicit: #197 must diagnose an unsupported lowering or choose an evidenced validated fallback; #198 must reject incomplete plans lacking required #180/#184 checks; #199 must validate before explicit representation conversion and dispatch; #200 must validate converted response JSON and serializer bytes before sending. Exact scalar facets, complete particle languages and lexical-sensitive normalization cannot be waived by schema or serializer success.
|
|
147
|
+
|
|
148
|
+
## Documented and unverified combinations
|
|
149
|
+
|
|
150
|
+
Installed primary docs describe draft-07, nullable extensions, recursive references, serializer defaults, field omission and branch selection. Documentation alone does not expand this finite executed corpus.
|
|
151
|
+
|
|
152
|
+
Format plugins are installed on the host, but the route-local Ajv probe does not install them or claim date/time/binary format enforcement. QName namespace scope, XSD Unicode/regex differences, list/union assessment, wildcard and nil-with-attributes projections, mixed text, discriminator, `if/then/else`, dependent vocabulary and pathological recursive depth are unverified here and require implementing-issue fixtures.
|
|
153
|
+
|
|
154
|
+
OpenAPI 3.1.1 document validation, generic 2020-12 Ajv compilation, arbitrary modern-to-draft-07 lowering, live network listeners, consumer-installed dependency matrices, Node 26 and adversarial performance/resource limits were not exercised by this integration suite. The current threshold remains a selected existing fallback policy rather than a newly measured engine limit.
|
|
155
|
+
|
|
156
|
+
## Validation record
|
|
157
|
+
|
|
158
|
+
The final targeted suite passed all 19 tests on Node 24.19.0; the existing integration typecheck passed. Full conformance passed all 138 tests across three files; documentation validation and the pipeline smoke check passed.
|
|
159
|
+
|
|
160
|
+
IDE inspections were unavailable; repository-local TypeScript, Vitest and documentation checks provide the local verification. No production files, dependencies or global host options were changed.
|
|
161
|
+
|
|
162
|
+
## Primary references
|
|
163
|
+
|
|
164
|
+
- [Fastify 5.12.5 validation and serialization](https://github.com/fastify/fastify/blob/v5.12.5/docs/Reference/Validation-and-Serialization.md)
|
|
165
|
+
- [Ajv 8.20.0 README](https://github.com/ajv-validator/ajv/blob/v8.20.0/README.md)
|
|
166
|
+
- [Ajv 8.20.0 data modification](https://github.com/ajv-validator/ajv/blob/v8.20.0/docs/guide/modifying-data.md)
|
|
167
|
+
- [fast-json-stringify 7.0.1 README](https://github.com/fastify/fast-json-stringify/blob/v7.0.1/README.md)
|
|
168
|
+
- [OpenAPI 3.1.1 specification](https://github.com/OAI/OpenAPI-Specification/blob/3.1.1/versions/3.1.1.md)
|
|
169
|
+
- [ADR 003 scalar profile](decisions/003-content-model-contracts.md#xsd-10-profile-and-enforcement-s02-d04)
|
|
@@ -0,0 +1,121 @@
|
|
|
1
|
+
# Canonical Schema Graph
|
|
2
|
+
|
|
3
|
+
Internal S04 graph contracts for the unreleased faithful compiler. See the root [README](../README.md).
|
|
4
|
+
|
|
5
|
+
## Ownership and data flow
|
|
6
|
+
|
|
7
|
+
[ADR-003 D01/D04/D09](decisions/003-content-model-contracts.md) defines identity, profile and budgets.
|
|
8
|
+
[S03 loading](content-model-loading.md) supplies immutable syntax through its repository-owned adapter.
|
|
9
|
+
[The model](../src/compiler/canonicalGraph.ts) and [pure builder](../src/compiler/buildCanonicalGraph.ts) implement #173.
|
|
10
|
+
|
|
11
|
+
```text
|
|
12
|
+
SchemaInput.schemas + ordered WSDL documents
|
|
13
|
+
-> reserve global symbols
|
|
14
|
+
-> build complete declarations and independent use sites
|
|
15
|
+
-> link available targets without expansion
|
|
16
|
+
-> freeze CanonicalGraph
|
|
17
|
+
-> S05 reference/composition assessment
|
|
18
|
+
```
|
|
19
|
+
|
|
20
|
+
`buildCanonicalGraph(input, {maxNodes?})` performs no I/O and never mutates input.
|
|
21
|
+
The internal graph is not exported by the package entry point or activated by the CLI.
|
|
22
|
+
The legacy compiler and its consumers retain the 1.x default.
|
|
23
|
+
|
|
24
|
+
## Identities and immutable references
|
|
25
|
+
|
|
26
|
+
Global IDs are JSON tuples `['global', role, effectiveNamespace, localName]`.
|
|
27
|
+
Element, attribute, type, model group, attribute group and WSDL roles occupy separate symbol spaces.
|
|
28
|
+
Simple and complex named types share the type symbol space.
|
|
29
|
+
|
|
30
|
+
Scoped identity is `(containingDeclarationId, sourceRelativePath, role)`.
|
|
31
|
+
The ID is `scoped:` plus SHA-256 of the UTF-8 JSON tuple `[owner, path, role]`; the tuple remains explicit in `identity`.
|
|
32
|
+
Hashing prevents recursively escaped anonymous-owner IDs from growing exponentially with nesting.
|
|
33
|
+
An anonymous type is a distinct type node owned by its containing declaration.
|
|
34
|
+
Local elements with the same expanded name in different types retain independent declarations and type references.
|
|
35
|
+
|
|
36
|
+
Syntax paths are relative to the containing declaration and preserve the adapter's ordered element/text indexes.
|
|
37
|
+
They contain no document URI or temporary directory.
|
|
38
|
+
Changing source structure may change scoped IDs; output names and prefixes never define identity.
|
|
39
|
+
|
|
40
|
+
Interpretation keys live only in `origins`; repeated root/include interpretations do not create additional globals.
|
|
41
|
+
Repeated declarations from the same byte digest and source path share one complete body.
|
|
42
|
+
Conflicting declarations for one global identity fail explicitly rather than being merged by name.
|
|
43
|
+
|
|
44
|
+
References are discriminated `symbol`, `builtin` or `local` values.
|
|
45
|
+
Available global targets are linked after all bodies exist; unresolved symbol references keep their expanded name and lexical context with no target.
|
|
46
|
+
S05 owns missing-target diagnosis, reference visibility, component-cycle legality and complete derivation semantics.
|
|
47
|
+
|
|
48
|
+
For recursive `element Shared -> type Shared -> element-use Shared`, each target points to a complete declaration.
|
|
49
|
+
No eager expansion or empty recursion placeholder is introduced.
|
|
50
|
+
Two uses of group `Pair` with bounds `0..2` and `3..900719925474099312345678901234567890` share its definition and keep separate particles.
|
|
51
|
+
|
|
52
|
+
## Node invariants
|
|
53
|
+
|
|
54
|
+
Element and attribute declarations own their expanded names, type references and default/fixed constraints.
|
|
55
|
+
Particles own only their local `Occurs` and term: ordered sequence, choice, legal XSD 1.0 all, element use, group use or wildcard.
|
|
56
|
+
Attributes, attribute-group references and attribute wildcards occupy an ordered attribute-use list distinct from child content.
|
|
57
|
+
|
|
58
|
+
Simple types retain restriction bases and ordered facets, list items or declaration-ordered union members.
|
|
59
|
+
Complex types retain local content and attributes plus distinct extension/restriction edges and simple/complex content kind.
|
|
60
|
+
No derived content, effective attribute composition or occurrence summary is calculated here.
|
|
61
|
+
|
|
62
|
+
Finite bounds are canonical nonnegative decimal strings; `unbounded` is a distinct maximum token.
|
|
63
|
+
The builder compares exact integers, rejects negative/fractional/reversed ranges and invalid all shapes, and never converts bounds to Number.
|
|
64
|
+
Zero remains a local bound; S06 calculates its annihilating effect on summaries.
|
|
65
|
+
|
|
66
|
+
WSDL nodes preserve ordered message/operation/binding/service syntax and role-qualified references.
|
|
67
|
+
Their binding extensions, actions, body/header/fault selections and lexical attributes remain available to later planning.
|
|
68
|
+
The graph does not select a SOAP transport or advertise qualified capabilities.
|
|
69
|
+
|
|
70
|
+
## Lexical context and provenance
|
|
71
|
+
|
|
72
|
+
Every graph node retains source URI, original-byte digest, source path and start/end positions, inherited base URI and namespace scope.
|
|
73
|
+
Source offsets and exclusive ends follow the [adapter contract](content-model-loading.md#syntax-and-provenance-contract).
|
|
74
|
+
`GraphContext.schemaAttributes` retains schema-level defaults for downstream interpretation.
|
|
75
|
+
|
|
76
|
+
Facet values, defaults/fixed values, wildcard namespace constraints and explicit QName references retain `LexicalValue {value, context}`.
|
|
77
|
+
Lexical values are not coerced, normalized or assessed by S04.
|
|
78
|
+
QName facets can be interpreted later using the original locally rebound namespace context.
|
|
79
|
+
|
|
80
|
+
Chameleon adoption changes a no-namespace component reference's effective target namespace while preserving its original lexical context.
|
|
81
|
+
A lexical `Node` with an empty default binding can target `urn:a:Node` under adoption and `urn:b:Node` in another interpretation.
|
|
82
|
+
An explicit/default lexical namespace remains authoritative; it is never overwritten by adoption.
|
|
83
|
+
|
|
84
|
+
Default namespaces apply to lexical QNames and XML element names, while unprefixed ordinary XML attributes remain unqualified.
|
|
85
|
+
Local declaration names use `form` or the schema's respective element/attribute form default.
|
|
86
|
+
These declaration rules are independent of the XML syntax name's namespace.
|
|
87
|
+
|
|
88
|
+
Annotations preserve ordered element/text syntax, attributes and namespaces, including mixed appinfo text.
|
|
89
|
+
`syntaxDetails` preserves restriction/list/union and content-wrapper syntax; facets retain their complete declaring syntax.
|
|
90
|
+
Known element-only XSD containers reject significant text explicitly, while mixed annotation content remains ordered.
|
|
91
|
+
Uninterpreted declarations remain `retained` or contextual `schemaRetained` for S06 assessment; preservation is not support certification.
|
|
92
|
+
Full internal URIs and loading edges remain provenance; [format 2 persistence](content-model-catalog.md) implements #174's artifact-safe serialization and semantic fingerprints.
|
|
93
|
+
|
|
94
|
+
## Resource and validation boundaries
|
|
95
|
+
|
|
96
|
+
The inclusive provisional limit is 100,000 declarations and use-site nodes together.
|
|
97
|
+
An explicit positive safe-integer `maxNodes` overrides it; construction fails with `resource-limit` and returns no partial graph.
|
|
98
|
+
Malformed structural shapes fail with `invalid-schema` and the declaring source.
|
|
99
|
+
|
|
100
|
+
S03's loading limits and conservative cyclic-depth behavior are consumed unchanged in `graph.loading`.
|
|
101
|
+
The builder performs structural checks only; S05 resolves/composes, S06 checks complete schema legality and reachable capabilities, and S07 matches values.
|
|
102
|
+
UPA, scalar/facet legality, complete component-cycle rules and production codecs remain downstream gates.
|
|
103
|
+
|
|
104
|
+
## Evidence and reproduction
|
|
105
|
+
|
|
106
|
+
[Graph tests](../test/unit/canonical-graph.test.ts) reuse independent S01/S02 and S03 fixtures.
|
|
107
|
+
[Graph fixtures](../test/conformance/fixtures/xsd/graph/shared-recursive.xsd) add shared definitions, recursion, local names, anonymous types, large bounds and scalar lexical context.
|
|
108
|
+
[Chameleon input](../test/conformance/fixtures/xsd/graph/chameleon.wsdl) proves namespace adoption without rewriting lexical bindings.
|
|
109
|
+
[Independent schema qualification](../test/conformance/reference/graph-contract.test.ts) preserves historical xmlschema 4.2.0 acceptance of the complete graph fixture. Current primary construction of the original huge bound remains unqualified under [NT-CONT-01](reference-validation.md), with exact scoped assertions and a separately hashed small copy.
|
|
110
|
+
Historical libxml2 rejected that fixture's huge bound; the current adapter reports unsupported capability before engine allocation. The separate variant with maximum `4` constructs successfully; exact-bound assertions and archived xmlschema acceptance remain distinct from that fresh result.
|
|
111
|
+
|
|
112
|
+
```bash
|
|
113
|
+
npx vitest run test/unit/canonical-graph.test.ts test/unit/canonical-graph-budgets.test.ts
|
|
114
|
+
npx tsc -p test/unit/tsconfig.json
|
|
115
|
+
npm run ci
|
|
116
|
+
npm run test:reference:full
|
|
117
|
+
```
|
|
118
|
+
|
|
119
|
+
[Budget evidence](../test/unit/canonical-graph-budgets.test.ts) measures 100,000/100,001 nodes and writes ignored results to `tmp/conformance/schema-graph/measurements.json`.
|
|
120
|
+
The #151 handoff pins exact independently reviewed heads, merged revisions, commands/results and later qualification owners.
|
|
121
|
+
Optional IDE checks, Windows filesystem behavior, private production schemas and broad platform limits remain unqualified.
|
|
@@ -0,0 +1,163 @@
|
|
|
1
|
+
# Ordered Schema Loading
|
|
2
|
+
|
|
3
|
+
Internal S03 input contracts for the unreleased faithful compiler. See the root [README](../README.md).
|
|
4
|
+
|
|
5
|
+
## Ownership and compatibility
|
|
6
|
+
|
|
7
|
+
[ADR-003 D01/D04/D09](decisions/003-content-model-contracts.md) owns the input, profile and budget decisions.
|
|
8
|
+
The [decision register](content-model-decisions.md) assigns the later semantic consumers.
|
|
9
|
+
The [ordered syntax adapter](../src/loader/orderedSyntax.ts) implements #171; [contextual traversal](../src/loader/schemaInput.ts) and [resource I/O](../src/loader/schemaResources.ts) implement #172.
|
|
10
|
+
|
|
11
|
+
This internal adapter is not exported from the package entry point or activated by the CLI.
|
|
12
|
+
The existing [WSDL loader](../src/loader/wsdlLoader.ts) remains the legacy default while #174 owns later routing.
|
|
13
|
+
Parsing XML syntax does not certify XSD legality, resolve declarations, or establish payload validity.
|
|
14
|
+
|
|
15
|
+
## Syntax and provenance contract
|
|
16
|
+
|
|
17
|
+
`parseOrderedSyntax(bytes, absoluteUri, {maxDepth})` returns an immutable `SyntaxDocument` with `root`, full `uri` and SHA-256 `digest` of original bytes.
|
|
18
|
+
`SyntaxElement.children` retains text and element order across every compositor kind; no name-keyed grouping occurs.
|
|
19
|
+
Annotations, occurrence strings, declaration form settings and lexical attribute values remain available for their later owners.
|
|
20
|
+
|
|
21
|
+
Each element retains its expanded `name`, `lexicalName`, ordinary attributes, all in-scope `namespaces`, effective `baseUri` and `source`.
|
|
22
|
+
Namespace declarations populate context rather than ordinary attributes.
|
|
23
|
+
Default namespaces apply to element names; unprefixed attribute names have an empty namespace.
|
|
24
|
+
|
|
25
|
+
`resolveLexicalQName(value, element)` resolves QName-valued attributes or text in the declaring element's namespace context, including the default binding.
|
|
26
|
+
It rejects malformed lexical names and unbound prefixes, without echoing lexical values in diagnostics.
|
|
27
|
+
`syntaxElements` filters direct element children by expanded name while retaining order; `syntaxAttribute` retrieves an expanded attribute name.
|
|
28
|
+
|
|
29
|
+
`source` contains full document URI, digest, stable source-relative syntax path and start/end positions.
|
|
30
|
+
Lines and columns are one-based; offsets are zero-based UTF-16 positions in decoded XML and end offsets are exclusive.
|
|
31
|
+
Syntax paths distinguish local declarations in different containing types; they are not global symbol identities.
|
|
32
|
+
S04 owns global `(namespace, local, role)` identities and containing-declaration identities for locals.
|
|
33
|
+
|
|
34
|
+
`baseUri` begins at the supplied final retrieval URI and inherits each `xml:base` through URL-reference resolution.
|
|
35
|
+
For a document at `https://example.test/contracts/root.xsd`, `xml:base="../types/"` gives `https://example.test/types/`.
|
|
36
|
+
The syntax adapter computes this context without performing I/O; #172 must authorize each resolved fetch.
|
|
37
|
+
|
|
38
|
+
## Syntax limits and diagnostics
|
|
39
|
+
|
|
40
|
+
The default nesting budget is 256 elements, inclusive, checked before accepting the next element.
|
|
41
|
+
`SchemaLoadingError` distinguishes `invalid-schema`, `unsupported-capability`, `resource-limit` and `transport`; syntax errors carry source context.
|
|
42
|
+
The adapter rejects DTDs, entity declarations and unresolved entity references, while accepting XML's predefined and numeric character references.
|
|
43
|
+
|
|
44
|
+
UTF-8 and BOM-marked UTF-16 are decoded strictly; unsupported declared encodings fail explicitly.
|
|
45
|
+
Comments and processing instructions are outside XML-value fidelity and omitted; CDATA retains its text.
|
|
46
|
+
The parser dependency is confined to this module; consumers receive repository-owned types.
|
|
47
|
+
|
|
48
|
+
## Controlled resolution contract
|
|
49
|
+
|
|
50
|
+
`loadSchemaInput(source, {policy, limits, offlineResources})` creates one compilation-scoped snapshot.
|
|
51
|
+
It accepts local paths, absolute file/HTTP(S) URIs, XSD roots and WSDL 1.1 definitions, including WSDL imports and inline schemas.
|
|
52
|
+
It returns immutable documents, contextual schemas, resource metadata, explicit resolution edges, limits and I/O metrics.
|
|
53
|
+
|
|
54
|
+
Traversal uses only expanded XSD include/import children and WSDL imports in their declaring syntax context.
|
|
55
|
+
Payload roots fail with `unsupported-capability`; `xsi:schemaLocation` and annotation content never initiate resolution.
|
|
56
|
+
Includes adopt the containing namespace only when the included schema has no target namespace; explicit namespace mismatches fail.
|
|
57
|
+
Imports preserve their declared namespace and check it against the retrieved schema.
|
|
58
|
+
|
|
59
|
+
An import without a schema location remains an unresolved edge for S05; it never guesses a network endpoint from its namespace.
|
|
60
|
+
Include without a location fails as invalid input.
|
|
61
|
+
Cycle edges remain in the result and stop active expansion; unresolved declaration diagnostics belong to S05 after traversal.
|
|
62
|
+
|
|
63
|
+
Cached depth checks include inline schemas at zero edge cost and count the cycle-closing edge against current active ancestry.
|
|
64
|
+
The [depth helper](../src/loader/resolutionDepth.ts) collapses strongly connected components and computes a polynomial upper bound on the condensed graph.
|
|
65
|
+
Acyclic chains and closed simple cycles retain exact boundaries; cyclic components with branches or exits may exhaust this conservative budget earlier.
|
|
66
|
+
An explicit caller depth override can admit them; no cycle edges or schema declarations disappear from the result.
|
|
67
|
+
|
|
68
|
+
`SchemaInterpretation` exposes `syntax`, `documentUri`, `digest`, `baseUri`, `targetNamespace`, `context` and `key`.
|
|
69
|
+
The context records root/inline/include/import kind and the namespace requested by that relationship.
|
|
70
|
+
Its key is a deterministic tuple of digest, final document URI, effective base URI, effective target namespace, context kind/namespace and syntax path.
|
|
71
|
+
The path distinguishes multiple inline schemas in the same document even when they share a namespace.
|
|
72
|
+
|
|
73
|
+
For example, `common.xsd` without a target namespace included from `urn:a` and `urn:b` has one fetched resource and two interpretations.
|
|
74
|
+
Both interpretations share immutable syntax; S04 reads their effective namespaces without changing lexical QName scope or mutating declarations.
|
|
75
|
+
Identical bytes at `/base-a/common.xsd` and `/base-b/common.xsd` keep distinct interpretations because `child.xsd` resolves differently.
|
|
76
|
+
|
|
77
|
+
The raw byte cache uses `(canonical final retrieval URI, SHA-256 digest)` and request/redirect aliases.
|
|
78
|
+
Fetches and traversal are serialized within a compilation; each successful final resource is fetched once.
|
|
79
|
+
The interpretation cache is separate and never keyed by digest alone.
|
|
80
|
+
Previously authorized aliases reuse the compilation's pinned bytes without new filesystem or network I/O.
|
|
81
|
+
Authorization I/O for a newly encountered file spelling still consumes the remaining deadline, even when it resolves to cached bytes.
|
|
82
|
+
|
|
83
|
+
## URI and security policy
|
|
84
|
+
|
|
85
|
+
`policy.fileRoots` authorizes local roots; `policy.allowedOrigins` authorizes exact HTTP(S) origins, including scheme and port.
|
|
86
|
+
Both lists default to empty. No input root grants implicit import permission.
|
|
87
|
+
Every import and redirect is rechecked, including the result of inherited `xml:base`.
|
|
88
|
+
|
|
89
|
+
HTTP redirects are manual and policy-checked before the next request; an HTTP redirect cannot select a file.
|
|
90
|
+
The final checked URI becomes document identity and the initial base for syntax.
|
|
91
|
+
Origin policy authorizes the destination explicitly, including any caller-approved private destination; it does not inherit application transport credentials.
|
|
92
|
+
|
|
93
|
+
URL normalization removes fragments, resolves dot segments and normalizes host/default-port spelling while preserving queries.
|
|
94
|
+
Local paths become absolute file URIs; filesystem identity uses `realpath`, with traversal and symlink checks against configured roots.
|
|
95
|
+
File queries and remote file authorities, other schemes and URLs containing user/password credentials fail explicitly.
|
|
96
|
+
|
|
97
|
+
Full source URIs are internal provenance, not semantic fingerprints or publishable artifact fields.
|
|
98
|
+
Callers must use credential-free source URLs and trusted, stable authorized filesystem roots; S04/#174 owns artifact-safe provenance serialization.
|
|
99
|
+
Transport errors omit upstream response text and credential-bearing error strings; referencing-node source locations remain available.
|
|
100
|
+
|
|
101
|
+
An optional offline map contains canonical URIs and pinned `{bytes, digest}` records.
|
|
102
|
+
Every offline resource still passes policy, size and digest checks; a missing record fails without network fallback.
|
|
103
|
+
Resource metadata exposes full final URI, digest and decompressed byte length, with no raw bytes in the returned input snapshot.
|
|
104
|
+
|
|
105
|
+
## Loading budgets
|
|
106
|
+
|
|
107
|
+
The provisional defaults from ADR-003 are implemented before downstream graph construction.
|
|
108
|
+
Positive safe-integer overrides permit explicit caller increases or lower limits; redirects may be zero.
|
|
109
|
+
|
|
110
|
+
| Budget | Inclusive default | Outcome beyond limit |
|
|
111
|
+
|---|---|---|
|
|
112
|
+
| Distinct final resources | 128 | `resource-limit` before new final body |
|
|
113
|
+
| Decompressed resource bytes | 8 MiB | `resource-limit` before parse |
|
|
114
|
+
| Aggregate decompressed bytes | 64 MiB | `resource-limit` before parse |
|
|
115
|
+
| Resolution depth bound | 32 edges | `resource-limit`, including cached subtrees |
|
|
116
|
+
| Redirects per fetch | 5 | `resource-limit` before sixth destination |
|
|
117
|
+
| Resource I/O | 15,000 ms | `transport`, abort/cancel input |
|
|
118
|
+
| Total compilation I/O | 120,000 ms | `transport`, abort/cancel input |
|
|
119
|
+
| XML element nesting | 256 | `resource-limit` in syntax adapter |
|
|
120
|
+
|
|
121
|
+
HTTP response bodies and files are read incrementally; decompressed chunks count against both byte budgets.
|
|
122
|
+
At the resource-count limit, bounded HTTP redirect discovery may still identify a cached final resource; a new final body is cancelled.
|
|
123
|
+
Local special files are rejected before opening; nonblocking/no-follow open flags and a descriptor check guard the final file boundary.
|
|
124
|
+
The deadline covers fetching, redirects and body reads; parsing is outside the I/O clock.
|
|
125
|
+
The total counts serial resource I/O, with monotonic timing and the remaining total budget constraining each fetch.
|
|
126
|
+
No rejected load returns a partial schema model.
|
|
127
|
+
|
|
128
|
+
## Evidence and reproduction
|
|
129
|
+
|
|
130
|
+
[Ordered syntax tests](../test/unit/ordered-syntax.test.ts) reuse independently qualified S01 compositor and S02 ordered SOAP inputs.
|
|
131
|
+
[Syntax fixtures](../test/conformance/fixtures/xsd/syntax/ordered-namespaces.xsd) and their [default-namespace equivalent](../test/conformance/fixtures/xsd/syntax/default-namespaces.xsd) exercise interleaving, annotations, rebinding, lexical QNames and distinct local paths.
|
|
132
|
+
These syntax fixtures establish input preservation; later graph/profile tasks own semantic schema assessment.
|
|
133
|
+
|
|
134
|
+
```bash
|
|
135
|
+
npx vitest run test/unit/ordered-syntax.test.ts --reporter=verbose
|
|
136
|
+
npx tsc -p test/unit/tsconfig.json
|
|
137
|
+
npx vitest run test/unit/schema-input.test.ts test/unit/schema-loading-budgets.test.ts test/integration/schema-resource-http.test.ts
|
|
138
|
+
npm run ci
|
|
139
|
+
```
|
|
140
|
+
|
|
141
|
+
Depth 256 succeeds and depth 257 fails with `resource-limit`; lower configured limits and malformed XML fail explicitly.
|
|
142
|
+
Tests also preserve the legacy relative-import fixture and validate source locations/digests and strict byte decoding.
|
|
143
|
+
Exact reviewed commits, executed aggregate results and measured limits are recorded in #150's final S03 handoff.
|
|
144
|
+
|
|
145
|
+
[Context fixtures](../test/conformance/fixtures/xsd/resolution/chameleon.wsdl) add chameleon/repeated includes, identical-byte bases, relative chains and cycles.
|
|
146
|
+
[Context tests](../test/unit/schema-input.test.ts) add offline digests, namespace mismatch, URI policy, query identity, symlink/traversal rejection, WSDL imports and payload hints.
|
|
147
|
+
[Live HTTP evidence](../test/integration/schema-resource-http.test.ts) checks final retrieval/base resolution and actual gzip decompression.
|
|
148
|
+
|
|
149
|
+
[Budget tests](../test/unit/schema-loading-budgets.test.ts) run 128/129 resources, 8 MiB/8 MiB+1, 64 MiB/64 MiB+1, 32/33 edges, 5/6 redirects and 256/257 syntax depth.
|
|
150
|
+
Per-resource 15,000/15,001 ms and total 120,000/120,001 ms use controlled monotonic clocks, with stalled-body cancellation also checked.
|
|
151
|
+
They write observed outcomes and elapsed times to ignored `tmp/conformance/schema-loading/measurements.json`.
|
|
152
|
+
These boundary measurements do not qualify production network latency, private vendors, Windows filesystem behavior or general supported maxima; #208 owns later qualification.
|
|
153
|
+
|
|
154
|
+
## S04 continuation inputs
|
|
155
|
+
|
|
156
|
+
#171 was independently reviewed at `3bb3cd656b1c0d15906d55262a22776c78964984` and merged normally through PR #225 as `11f635072ee0999cd5f904c58cae90b476b064ff`.
|
|
157
|
+
#172 starts from that merge and consumes its exact syntax contract.
|
|
158
|
+
The final #150 acceptance record pins both reviewed heads, merge revisions, full repository checks and merged-main checks.
|
|
159
|
+
|
|
160
|
+
S04 #173 reads `SchemaInput.schemas` and the immutable ordered syntax, deriving global identities from effective namespace, local name and role.
|
|
161
|
+
Scoped local identities use containing declarations and source-relative paths; interpretation context remains resolution/provenance data.
|
|
162
|
+
#174 serializes artifact-safe provenance separately from semantic fingerprints and implements catalog routing.
|
|
163
|
+
S05 resolves declaration/reference semantics from the recorded edges; S03 does not create canonical graph nodes, projections or codecs.
|
|
@@ -0,0 +1,85 @@
|
|
|
1
|
+
# Direct structural matching
|
|
2
|
+
|
|
3
|
+
Internal authenticated payload structure and scalar handoff contract. See the root [README](../README.md).
|
|
4
|
+
|
|
5
|
+
## Authority and supported grammar
|
|
6
|
+
|
|
7
|
+
[matchDirectOperation](../src/compiler/directStructure.ts) consumes an issued [DirectOperationContract](../src/compiler/directOperation.ts), a `DirectDirection` and an ordered `SyntaxElement` payload. `inspectDirectOperation` supplies the exact original source/context/root; copies and diagnostic JSON throw `TypeError`. There is no root/context override, source reload, cache, public export or runtime admission.
|
|
8
|
+
|
|
9
|
+
Directions are `{kind: 'input'}`, `{kind: 'output'}` and `{kind: 'fault', name: string}` for an exact declared fault. Unknown directions/faults return `unsupported`. The source gate remains the unchanged [P1-D01](decisions/003-content-model-contracts.md#checked-product-assessment-amendment-p1-d01) sufficient direct correspondence route.
|
|
10
|
+
|
|
11
|
+
The matcher handles global string/int/boolean scalar roots and named element-only complex roots containing a flat ordered sequence of distinct scalar declarations, including empty sequences. Native declaration names determine namespace/form; native occurrence pairs have minima `0`/`1` and maxima `1`/`unbounded`. It consumes original particles and the shared occurrence algebra, never interval summaries as a language validator.
|
|
12
|
+
|
|
13
|
+
A monotone cursor and actual occurrence count enforce order, required members, singleton maxima and complete consumption. Advancing a slot prevents returning to it later. Unbounded repetition consumes only actual input, with no maximum expansion or speculative state allocation.
|
|
14
|
+
|
|
15
|
+
## Results and retained duties
|
|
16
|
+
|
|
17
|
+
`structural-match` has `scope: 'structure-only'`, `scalarValidity: 'unassessed'` and `admitted: false`. It retains the exact `root`, `contextId`, owned `direction`, ordered `occurrences` and final `usage`. It never changes the original contract's `admitted` or `missingCapabilities` fields.
|
|
18
|
+
|
|
19
|
+
Every `DirectScalarDuty` retains the actual immutable `declaration`, its exact `type` reference, `builtin` expanded name, complete `lexical` text, owned payload `namespaces` and `payloadSource`, generated `payloadPath` and native `schemaPath`. Empty text differs from an absent required element. Text fragments are concatenated without trimming, normalization, conversion or default insertion.
|
|
20
|
+
|
|
21
|
+
`mismatch` covers wrong expanded names, order/count/consumption, significant element-only text and nested scalar elements. Only XML whitespace (`#x20`, `#x9`, `#xD`, `#xA`) is ignored between complex children. Ordinary attributes, `xsi:nil`, `xsi:type` and `xml:*` return `unsupported` because their semantics are unimplemented; namespace declarations reside in namespace context and are permitted.
|
|
22
|
+
|
|
23
|
+
`cancelled` and `resource-limit` carry no partial match. Diagnostics carry fixed rules, source schema paths and generated numeric payload paths, without echoing lexical values or caller-supplied paths. Malformed data throws `TypeError`; a potentially legal unsupported payload feature is never called invalid schema.
|
|
24
|
+
|
|
25
|
+
## Input ownership and resource lifetime
|
|
26
|
+
|
|
27
|
+
Inputs are data-only plain records and dense arrays, without proxies or accessors. A prepass checks the element root and rejects reused/cyclic syntax nodes through descriptors without invoking getters, reserving syntax nodes before copying. An iterative budgeted snapshot owns retained payload facts; shape checks then distinguish malformed records from XML structural differences. Caller/source objects are neither modified nor newly frozen.
|
|
28
|
+
|
|
29
|
+
The original selected context budget charges planning, syntax visits, descriptor inspection, text/maps, copying, paths, occurrence collection, freezing and final publication. Repeated calls share the remaining sticky budget; failure cannot reset it. Node accounting adds each payload element/text node to the cumulative source-preparation/context count, and work also bounds all auxiliary records.
|
|
30
|
+
|
|
31
|
+
Traversal terminates because preflight rejects cyclic/reused syntax nodes, snapshot uses an explicit identity stack, and matching advances through finite payload children and schema slots. Work and retained memory scale with the actual source plan and payload facts, including text/maps/provenance; publication also traverses the retained native root graph. No operation scales with an unbounded hypothetical cardinality.
|
|
32
|
+
|
|
33
|
+
Cancellation is checked at entry, schema/payload visits, matching boundaries and before publication. This synchronous operation cannot observe timer callbacks until JavaScript yields; it claims cooperative checks only. A reusable production client's invocation-budget lifecycle requires a separate design decision.
|
|
34
|
+
|
|
35
|
+
## Repository-local example
|
|
36
|
+
|
|
37
|
+
Run the following from the repository root using `node --import tsx --input-type=module-typescript` and standard input. Parsing here supplies a payload tree for demonstration, not a production SOAP adapter or security qualification.
|
|
38
|
+
|
|
39
|
+
```typescript
|
|
40
|
+
import path from 'node:path';
|
|
41
|
+
import {selectDirectOperation} from './src/compiler/directOperation.ts';
|
|
42
|
+
import {matchDirectOperation} from './src/compiler/directStructure.ts';
|
|
43
|
+
import {parseOrderedSyntax} from './src/loader/orderedSyntax.ts';
|
|
44
|
+
|
|
45
|
+
const namespace = 'urn:checked:forecast';
|
|
46
|
+
const selected = await selectDirectOperation(
|
|
47
|
+
'test/conformance/fixtures/assessment/forecast.wsdl',
|
|
48
|
+
{portType: {namespace, local: 'ForecastPortType'},
|
|
49
|
+
binding: {namespace, local: 'ForecastBinding'}, operation: 'GetForecast'},
|
|
50
|
+
{loading: {policy: {fileRoots: [path.resolve('test/conformance/fixtures/assessment')]}}},
|
|
51
|
+
);
|
|
52
|
+
if (selected.kind !== 'selected') throw new Error(selected.kind);
|
|
53
|
+
const cases = [
|
|
54
|
+
{direction: {kind: 'input'} as const,
|
|
55
|
+
xml: '<f:GetForecast><f:city>Paris</f:city><f:days>not-an-int</f:days></f:GetForecast>'},
|
|
56
|
+
{direction: {kind: 'output'} as const,
|
|
57
|
+
xml: '<f:GetForecastResponse><f:city>Paris</f:city><f:complete>true</f:complete></f:GetForecastResponse>'},
|
|
58
|
+
{direction: {kind: 'fault', name: 'ForecastError'} as const,
|
|
59
|
+
xml: '<f:ForecastFault><f:code>NOT_FOUND</f:code><f:message>Unknown city</f:message></f:ForecastFault>'},
|
|
60
|
+
];
|
|
61
|
+
for (const example of cases) {
|
|
62
|
+
const xml = example.xml.replace('>', ` xmlns:f="${namespace}">`);
|
|
63
|
+
const payload = parseOrderedSyntax(Buffer.from(xml), 'https://payload.invalid/message.xml').root;
|
|
64
|
+
const result = matchDirectOperation(selected.contract, example.direction, payload);
|
|
65
|
+
console.log(result.kind, result.kind === 'structural-match' ? result.scalarValidity : result.rule);
|
|
66
|
+
}
|
|
67
|
+
```
|
|
68
|
+
|
|
69
|
+
All three print `structural-match unassessed`, including the intentionally invalid int lexical witness. No SOAP endpoint is contacted. This matching-only example does not assess SOAP envelopes/faults, parser security, scalars, projection/byte round trips, transport or generation; the separate value/codec consumer below supplies its own named checks.
|
|
70
|
+
|
|
71
|
+
## Independent evidence
|
|
72
|
+
|
|
73
|
+
[Independent language tests](../test/unit/direct-structure-evidence.test.ts) specify Forecast request/response/fault expectations without the subject plan. The test-only adapter uses exact SOAP namespace/path extraction. Literal mutations cover trailing requirements, late returns, namespaces/forms, renamed sources, scalar roots, empty sequences, text and attributes.
|
|
74
|
+
|
|
75
|
+
Finite enumeration covers 1,444 words: 40 request words of length 0..3 over city/days/alien, 341 response words of length 0..4 over city/temperature/complete/alien for each of four temperature occurrence pairs, and 40 words for city-star/days-star. Literal language predicates independently determine expectations; these are finite corroboration, not universal XSD completeness. [Ownership/resource tests](../test/unit/direct-structure.test.ts) cover authority, immutable facts, malformed/cyclic/accessor input, inclusive work/node boundaries, cancellation and sticky reuse.
|
|
76
|
+
|
|
77
|
+
## P3.3 scalar consumption and fresh inverse
|
|
78
|
+
|
|
79
|
+
The matcher now registers only its actual final successful returned object after final cancellation/resource checks. `inspectDirectStructuralMatch(match, expectedContract)` authenticates identity before reading receipt fields; copied/JSON/zero-duty and foreign-contract objects fail. Existing unregistered historical results cannot authenticate retrospectively. The registry binds exact operation, context, root and owned direction because those are immutable fields of the issued object.
|
|
80
|
+
|
|
81
|
+
[Direct scalar values](direct-values.md) documents the implemented payload facade, complete source-derived mapping, fresh inverse, normalization laws, independent review and internal bounded XML codec. The native slot helper is shared by matcher and mapping; absent optional and zero-count repeated fields cannot disappear from the plan. Scalar success is separate from this matcher's unchanged structure-only result and still grants no runtime admission.
|
|
82
|
+
|
|
83
|
+
The new direct value chain retains original lexical/map/source/type evidence, validates through neutral shared datatype calculations and revalidates generated lexical data through matching and scalar assessment. No schema operand receipt or provenance is fabricated. The [accepted resource model](direct-values.md#accepted-resource-model) precharges the source-known valid key vector and explicitly excludes oversized engine-internal vectors from malformed objects; it makes no all-V8-allocation or hard heap bound claim.
|
|
84
|
+
|
|
85
|
+
Nil, attributes/type overrides, augmentation/defaults, arbitrary derivation and general conversion remain unsupported. The internal [bare-root XML codec](direct-values.md#internal-bare-root-xml-codec) consumes this matcher without changing its receipts. Transport, persisted bundles, public structured activation and generation remain deferred; defaults/version and publication status are unchanged. Broader matcher/evidence owners remain open beyond this direct slice.
|