Skip to content

Commit b301eeb

Browse files
aaronburtleCopilotsouvikghosh04
authored
Add level-2 property to runtime.cache in dab.draft.schema.json (#3317)
## Why make this change? Closes #3314 ## What is this change? Adds the `level-2` property, which is already a part of our object model, to the `dab.draft.schema.json` file. Also adds `minimum: 1` to `runtime.cache.ttl-seconds` to align schema validation with the runtime enforcement that rejects values ≤ 0. The `level-2.provider` property is kept as a plain string (no enum, no default) to match the nullable string with `null` default in the object model. ## How was this tested? - [ ] Integration Tests - [ ] Unit Tests ## Sample Request(s) N/A — schema-only change with no REST/GraphQL/CLI surface. <!-- START COPILOT CODING AGENT TIPS --> --- 📍 Connect Copilot coding agent with [Jira](https://gh.io/cca-jira-docs), [Azure Boards](https://gh.io/cca-azure-boards-docs) or [Linear](https://gh.io/cca-linear-docs) to delegate work to Copilot in one click without leaving your project management tool. --------- Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com> Co-authored-by: Souvik Ghosh <souvikofficial04@gmail.com>
1 parent 3c811b5 commit b301eeb

1 file changed

Lines changed: 34 additions & 1 deletion

File tree

schemas/dab.draft.schema.json

Lines changed: 34 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -486,7 +486,40 @@
486486
"ttl-seconds": {
487487
"type": "integer",
488488
"description": "Time to live in seconds",
489-
"default": 5
489+
"default": 5,
490+
"minimum": 1
491+
},
492+
"level-2": {
493+
"type": "object",
494+
"description": "Configuration for the level 2 (distributed) cache and backplane.",
495+
"additionalProperties": false,
496+
"properties": {
497+
"enabled": {
498+
"$ref": "#/$defs/boolean-or-string",
499+
"description": "Enable or disable the level 2 distributed cache.",
500+
"default": false
501+
},
502+
"provider": {
503+
"type": "string",
504+
"description": "The provider for the L2 cache. Currently only 'redis' is supported."
505+
},
506+
"connection-string": {
507+
"type": "string",
508+
"description": "The connection string for the level 2 cache provider."
509+
},
510+
"partition": {
511+
"type": "string",
512+
"description": "The prefix to use for cache keys in level 2 and backplane, useful in a shared environment to avoid collisions."
513+
}
514+
},
515+
"if": {
516+
"properties": {
517+
"enabled": { "const": true }
518+
}
519+
},
520+
"then": {
521+
"required": ["connection-string"]
522+
}
490523
}
491524
}
492525
},

0 commit comments

Comments
 (0)