| Bug #57513 | Remove unused and unmaintained event: Slave_log_event | ||
|---|---|---|---|
| Submitted: | 18 Oct 2010 10:14 | Modified: | 15 Nov 2010 19:43 |
| Reporter: | Luis Soares | Email Updates: | |
| Status: | Closed | Impact on me: | |
| Category: | MySQL Server: Replication | Severity: | S3 (Non-critical) |
| Version: | OS: | Any | |
| Assigned to: | Luis Soares | CPU Architecture: | Any |
| Tags: | replication refactoring, unused | ||
[20 Oct 2010 14:52]
Bugs System
A patch for this bug has been committed. After review, it may be pushed to the relevant source trees for release in the next version. You can access the patch from: http://lists.mysql.com/commits/121350 3325 Luis Soares 2010-10-20 BUG#57513: Remove unused and unmaintained event: Slave_log_event The source code shows that Slave_log_event is[/has] not [been] used at all[, ever]. So there are at least three reasons to remove it: 1. the fact that this code is unmaintained can raise some unexpected issues, like: BUG#38718; 2. other unmaintained code that exhibited dependencies from Slave_log_event was already removed in BUG#54649 3. Reviewers of BUG#38718 required that a new bug would be reported to remove this event. To fix this, we remove the Slave_log_event associated code. We maintain the ENUM position for SLAVE_EVENT for historical reasons and to avoid messing with Format_description_event post_header_len definitions.
[13 Nov 2010 16:23]
Bugs System
Pushed into mysql-trunk 5.6.99-m5 (revid:alexander.nozdrin@oracle.com-20101113155825-czmva9kg4n31anmu) (version source revid:alexander.nozdrin@oracle.com-20101113155825-czmva9kg4n31anmu) (merge vers: 5.6.99-m5) (pib:21)
[13 Nov 2010 16:32]
Bugs System
Pushed into mysql-next-mr (revid:alexander.nozdrin@oracle.com-20101113160336-atmtmfb3mzm4pz4i) (version source revid:alexander.nozdrin@oracle.com-20101113152540-gxro4g0v29l27f5x) (pib:21)
[15 Nov 2010 19:43]
Jon Stephens
No apparent visible impact on end users. Closed without further action.

Description: Looking at the sources, one finds that Slave_log_event is not used at all. In fact, we find several comments spread on the source code about this, for example: - sql/log_event.h " (...) /** @class Slave_log_event Note that this class is currently not used at all; no code writes a @c Slave_log_event. So it's not a problem if this code is not maintained. (...)" - sql/log_event.cc " (...) #ifdef HAVE_REPLICATION case SLAVE_EVENT: /* can never happen (unused event) */ ev = new Slave_log_event(buf, event_len); break; (...) " There are at least three reasons to propose that Slave_log_event is removed altogether: 1. the fact that this code is unmaintained can raise some unexpected issues, like: BUG#38718; 2. given that some other unmaintained code that exhibited dependencies from Slave_log_event was already removed in BUG#54649, the remains of Slave_log_event should also be removed; 3. Reviewers of BUG#38718 required that a new bug would be reported to remove this event. I happen to agree with all three items and propose to remove it in mysql-next-mr (which is where BUG#54649 - previous removal of unused code - was pushed). How to repeat: Look at: - tree: mysql-next-mr - rev-id: alexander.nozdrin@oracle.com-20101008132832-pbzewvmi9f365ak4 - files: sql/log_event.cc, sql/log_event.h Suggested fix: Remove the unused and unmaintained event.