rewritefilter
This page is part of MariaDB's Documentation.
The parent of this page is: Filters for MariaDB MaxScale
Topics on this page:
Overview
DETAILS
The rewritefilter
is a filter that can be configured to manipulate the SQL statements that are being run before they get to the backing database.
The filter is configured in the maxscale.cnf
file using the following parameters.
The template_file
parameter must be configured in the filter section. It specifies a string value path name of the template file to parse into rewrite rules. This setting has no default value.
The following optional parameters control the default setting for how the rules behave. Each rule can override the default value specified here:
regex_grammar
- a string value that chooses which type of regex grammar to use in the template rules. The choices are:Native
(the default when unspecified)ECMAScript
Posix
EPosix
Awk
Grep
EGrep
case_sensitive
- a boolean value that controls if uppercase/lowercase are distinct when matching. Defaults to true.log_replacement
- a boolean value that controls if replacements are logged at the NOTICE level or not logged. Defaults to false (no logging).
For details on creating the template file itself, see
.EXAMPLES
[Rewrite]
type = filter
module = rewritefilter
template_file = /path/to/template_file.rf
regex_grammar = Native
case_sensitive = true
log_replacement = true