microsoft / microsoft/multiclouddb-sdk-for-java
[BUG] Decode nested Spanner numeric values consistently across result paths
Nobody has claimed this yet.
- Dominant language
- Java
- Stars
- 7
- Forks
- 7
- Avg merge
- 1d 22h
- Merged PRs (30d)
- 1
Description
Bug description
Spanner's document representation uses typed string markers for values that cannot be represented directly by the selected Spanner schema. Nested numeric values are not decoded symmetrically on every result path: query results can conflict with the string-marker representation, and change-feed conversion does not recursively restore marker-backed values inside objects and arrays.
This is an existing Spanner read/query/change-feed concern discovered during the numeric audit for #105; it is not caused by partial update.
Provider
- Azure Cosmos DB
- Amazon DynamoDB
- Google Cloud Spanner
- Not provider-specific
Reproduction steps
- Store a document containing numeric values nested inside an object and an array.
- Read it through the normal point-read path, a portable query, and change feed.
- Compare both the values and Jackson node types returned by each path.
Expected behaviour
All Spanner result paths recursively decode the storage representation and return equivalent nested numeric values according to the portable numeric contract.
Actual behaviour
Nested values can remain marker strings or be exposed with a different representation depending on the result path.
Acceptance criteria
- Point read, query, and change feed share one recursive marker decoder.
- Nested objects and arrays preserve positive/negative integral and decimal values.
- Literal user strings that resemble a marker cannot be mis-decoded.
- Provider and conformance tests compare identical nested results across all three paths.
- The behavior is documented consistently with the shared portable numeric contract.
Additional context
Related umbrella issues: #37 and #64.
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Trace the Spanner point-read path, portable query path, and change-feed conversion, using the numeric audit from #105 and the shared portable numeric contract as starting points. Verify how nested objects and arrays are decoded, then run or add provider and conformance tests comparing all three paths; done means equivalent numeric values and unchanged literal marker-like strings.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- gcp, java
- Domain
- database
- Issue type
- Bug
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Active
- Clarity
- Mostly clear
- Newbie friendliness
- 52/100