mirror of
https://github.com/SigNoz/signoz.git
synced 2026-06-27 02:20:27 +01:00
fix: promote variable defaultValue to a named oneOf component
The list variable defaultValue was an inline string | []string oneOf, which downstream codegen can't canonicalize: tfplugingen-openapi rejects the inline scalar-or-array multi-type, and oapi-codegen has no named type to attach the union's Marshal/UnmarshalJSON to. Shape the vendored variable.DefaultValue as the named VariableDefaultValue oneOf via a reflector InterceptSchema hook and let defaultValue $ref it, instead of overriding the property inline. Regenerate the OpenAPI spec and frontend client accordingly.
This commit is contained in:
@@ -2971,11 +2971,7 @@ components:
|
||||
customAllValue:
|
||||
type: string
|
||||
defaultValue:
|
||||
oneOf:
|
||||
- type: string
|
||||
- items:
|
||||
type: string
|
||||
type: array
|
||||
$ref: '#/components/schemas/VariableDefaultValue'
|
||||
display:
|
||||
$ref: '#/components/schemas/DashboardtypesDisplay'
|
||||
name:
|
||||
@@ -7895,7 +7891,11 @@ components:
|
||||
- id
|
||||
type: object
|
||||
VariableDefaultValue:
|
||||
type: object
|
||||
oneOf:
|
||||
- type: string
|
||||
- items:
|
||||
type: string
|
||||
type: array
|
||||
ZeustypesGettableHost:
|
||||
properties:
|
||||
hosts:
|
||||
|
||||
Reference in New Issue
Block a user