Re: [Maria-developers] 56e2cd20ed3: MDEV-31033 ER_KEY_NOT_FOUND upon online COPY ALTER on a partitioned table

2023-05-29 Thread Nikita Malyavin
Hello Sergei! I think I've found a way that will satisfy both of us, and will also close my claim regarding the need for assertion. See commit 0bcbec79 . Comparing htons seems to work also for REORGANIZE

Re: [Maria-developers] 56e2cd20ed3: MDEV-31033 ER_KEY_NOT_FOUND upon online COPY ALTER on a partitioned table

2023-05-28 Thread Sergei Golubchik
Hi, Nikita, See, e.g. handler::is_clustering_key() or handler::ha_rnd_pos_by_record() On May 28, Nikita Malyavin wrote: > On Wed, 24 May 2023 at 18:32, Sergei Golubchik wrote: > > > > +bool handler::is_root_handler() const > > > +{ > > > + return this == table->file; > > > +} > > > > better

Re: [Maria-developers] 56e2cd20ed3: MDEV-31033 ER_KEY_NOT_FOUND upon online COPY ALTER on a partitioned table

2023-05-28 Thread Sergei Golubchik
Hi, Nikita, As far as I'm concerned, not having an assert there is quite fine too :) On May 27, Nikita Malyavin wrote: > > I suspect I'm able to move the assertion to a more generic place, like > is_root_handler, but I'd have to check whether a handler's hton is a > "certainly leaf" one by

Re: [Maria-developers] 56e2cd20ed3: MDEV-31033 ER_KEY_NOT_FOUND upon online COPY ALTER on a partitioned table

2023-05-27 Thread Nikita Malyavin
On Wed, 24 May 2023 at 18:32, Sergei Golubchik wrote: > > +bool handler::is_root_handler() const > > +{ > > + return this == table->file; > > +} > > better make it inline in handler.h > > Can't  TABLE is incomplete in handler.h. -- Yours truly, Nikita Malyavin

Re: [Maria-developers] 56e2cd20ed3: MDEV-31033 ER_KEY_NOT_FOUND upon online COPY ALTER on a partitioned table

2023-05-27 Thread Nikita Malyavin
Hello! On Wed, 24 May 2023 at 18:32, Sergei Golubchik wrote: > > @@ -7750,6 +7750,8 @@ ha_innobase::write_row( > > > > DBUG_ENTER("ha_innobase::write_row"); > > > > + DBUG_ASSERT(is_root_handler() || table->file->ht != > innodb_hton_ptr); > > instead of putting this assert into every

Re: [Maria-developers] 56e2cd20ed3: MDEV-31033 ER_KEY_NOT_FOUND upon online COPY ALTER on a partitioned table

2023-05-24 Thread Sergei Golubchik
Hi, Nikita, On May 24, Nikita Malyavin wrote: > revision-id: 56e2cd20ed3 (mariadb-11.0.1-114-g56e2cd20ed3) > parent(s): 47f5c7ae7e4 > author: Nikita Malyavin > committer: Nikita Malyavin > timestamp: 2023-05-10 01:49:42 +0300 > message: > > MDEV-31033 ER_KEY_NOT_FOUND upon online COPY ALTER on a