|
There is a HostAndPort IDL type, but it does not appear to be supported under 'server_parameters' IDL definitions. Attempting to do so like this:
server_parameters:
|
searchIndexAtlasHostAndPort:
|
description: 'Search index Atlas host address'
|
set_at: [ startup ]
|
type: HostAndPort
|
cpp_varname: gSearchIndexParams
|
results in an error msg like this:
...
|
Errors found while compiling IDL
|
search_index_options.idl: (12, 8): ID0008: Unknown IDL node 'type' for YAML entity 'server_parameters'
|
...
|
Instead of an easy IDL definition like above, it's necessary to create a CPP type and leverage it in the IDL, like done in this recent patch commit, where IDL looks like this
server_parameters:
|
searchIndexAtlasHostAndPort:
|
description: 'Search index Atlas host address'
|
set_at: [ startup ]
|
default: ''
|
cpp_varname: 'globalSearchIndexParams.host'
|
validator:
|
callback: 'SearchIndexParams::onValidateHost'
|
There is a second use case, doing the exact same thing, in this code.
|