Derive Macro SessionConfig

Source
#[derive(SessionConfig)]
{
    // Attributes available to this derive:
    #[parameter]
}
Expand description

To add a new parameter, you can add a field with #[parameter] in the struct A default value is required by setting the default option. The field name will be the parameter name. You can overwrite the parameter name by setting the rename option. To check the input parameter, you can use check_hook option.

flags options include

  • SETTER: to manually write a set_your_parameter_name function, in which you should call set_your_parameter_name_inner.
  • REPORT: to report the parameter through ConfigReporter
  • NO_ALTER_SYS: disallow the parameter to be set by alter system set