-
Type:
Bug
-
Resolution: Won't Do
-
Priority:
Major - P3
-
None
-
Affects Version/s: None
-
Component/s: None
-
None
-
Server Security
-
ALL
-
None
-
None
-
None
-
None
-
None
-
None
-
None
Currently, this is possible by omitting the default-value specification for the required field:
structs:
ExampleClusterParameterStructValueType:
inline_chained_structs: true
chained_structs:
ClusterServerParameter: clusterServerParameter
fields:
enabled: # <-- required field
type: bool
expireAfterSeconds: # <-- optional field
type: safeInt64
default: 0
This mechanism however, requires parameter initialisation prior getClusterParameter or setClusterParameter is called. Currently, the initialisation can be specified inside the IDL, but it requires non-constexpr initialiser-function for struct types.
server_parameters:
someClusterParam:
set_at: cluster
cpp_vartype: ExampleClusterParameterStructValueType
cpp_varname: gSomeClusterParam
default:
expr: getSomeClusterParamDefault() # <-- initialiser function
is_constexpr: false
The same should be possible with serverless / multi-tenancy, preferably with constexpr initialiser.