Bug #86072 query_rewrite warning generation should be configurable
Submitted: 25 Apr 2017 13:24 Modified: 9 Feb 2018 11:35
Reporter: Simon Mudd (OCA) Email Updates:
Status: Verified Impact on me:
None 
Category:MySQL Server: Parser Severity:S4 (Feature request)
Version:5.7, 8.0 OS:Any
Assigned to: CPU Architecture:Any
Tags: query_rewrite plugin

[25 Apr 2017 13:24] Simon Mudd
Description:
I couldn't find a category for the query_rewrite plugin

Related partly to: bug#86071

https://dev.mysql.com/doc/refman/5.7/en/rewriter-query-rewrite-plugin-usage.html indicates that if the query_rewrite plugin is enabled and you execute a statement which gets matched and modified by the plugin then a warning is generated which indicates the modified query.

For anyone who monitors the warnings and decides to use the query rewrite plugin this usage is going to generate a huge number of warnings when they may or may not have been present previously and this is probably very undesirable.

How to repeat:
See above.

Suggested fix:
Each rule should probably have an option for warnings to be generated or not and it's fine for this to be enabled by default. However allowing the DBA to modify this setting so that warnings are not disabled would mean that no extra noise is generated.

The requested extra counters (per query?) in bug#86071 if implemented would give some sort of indication of the query_rewriter working correctly and the default behaviour would be unchanged.

So please consider adding such a switch so that the extra noise does not need to be seen when it may make sense to ignore it, or simply the condition is understood (as you've configured mysql to deal with it).
[9 Feb 2018 11:35] MySQL Verification Team
Hello Simon,

Thank you for the feature request.

Thanks,
Umesh