Hi Svoj! On Tue, May 28, 2019 at 10:13 PM Sergey Vojtovich <svoj@mariadb.org> wrote:
Hi Sachin,
Did you consider some other options?
Yes.
Like moving storage engine lookup out of parser. I did , But Andrei preferred a more universal approach. Which can be used for future errors/warnings not limited to storage engine. Or intercepting error/warning with Internal_error_handler? I did thought about this but I did not tried this, Main issue was we can have array of warnings/or maybe one or more error in future, So I was not sure how this will work.
I also tried 2 more approch 1. Create a error/warning array and a corresponding flag array in LEX_MASTER_INFO for storing errors/warning. 2. Instead of array , use a LIST and push the error with all info into this. (This was not much successful )
Regards, Sergey
On Mon, May 27, 2019 at 09:45:22PM +0530, sachin.setiya@mariadb.com wrote:
revision-id: 0fa3079ccc93288d4ec93f713bc162d69cc477d0 (mariadb-10.1.38-114-g0fa3079ccc9) parent(s): 6c5e4c9bc0d9ac30f7ec7ee334630bacb58687ba author: Sachin committer: Sachin timestamp: 2019-05-27 21:44:48 +0530 message:
Mdev-17588 replicate-do filters cause errors when creating filtered-out tables on master with syntax unsupported on slave
Prototype -4
Use a ME_DEFERRED_ERROR/ WARN_LEVEL_DEFERRED_WARN for my_error/push_warning when error can be deferred. It will store the error/warning in m_warn_list. And thd->is_error() will return false. To actiave the error/warning we need to call these functions change_deferred_to_normal_warn/error
--- include/my_sys.h | 5 +++ mysql-test/suite/rpl/r/rpl_mdev_17588.result | 27 +++++++++++++ mysql-test/suite/rpl/t/rpl_mdev_17588-slave.opt | 1 + mysql-test/suite/rpl/t/rpl_mdev_17588.test | 36 +++++++++++++++++ sql/mysqld.cc | 10 +++++ sql/sql_class.cc | 2 + sql/sql_class.h | 4 ++ sql/sql_error.cc | 51 +++++++++++++++++++++++++ sql/sql_error.h | 33 +++++++++++++++- sql/sql_parse.cc | 18 +++++++++ sql/sql_yacc.yy | 14 +++++-- 11 files changed, 196 insertions(+), 5 deletions(-) ...skip...
Regards, Sergey
-- Regards Sachin Setiya Software Engineer at MariaDB