Fix bug 1617949 (HandlerSocket leaks thread objects)#937
Merged
laurynas-biveinis merged 1 commit intopercona:5.6from Aug 31, 2016
Merged
Fix bug 1617949 (HandlerSocket leaks thread objects)#937laurynas-biveinis merged 1 commit intopercona:5.6from
laurynas-biveinis merged 1 commit intopercona:5.6from
Conversation
| delete *i; | ||
| } | ||
| cnt.clear(); | ||
| } |
Collaborator
There was a problem hiding this comment.
For containers like this hiding copy constructor and assignment operator is also a good idea.
Collaborator
|
LGTM |
This is caused by hstcpsvr::threads, which is auto_ptrcontainer<std::vector<worker_thread_type *> > (effectively std::vector<foo *>), having clear() method, which clears the container without deleting the member pointers, which are owned by the container. Fix by making clear delete the pointers, and by making destructor to call clear instead of deleting pointers by itself.
8351d15 to
586ef5b
Compare
Contributor
Author
|
Updated to inherit from noncopyable, http://jenkins.percona.com/job/percona-server-5.6-param/1345/ |
Collaborator
|
LGTM |
satya-bodapati
added a commit
to satya-bodapati/percona-server
that referenced
this pull request
Feb 22, 2019
Summary: https://jira.percona.com/browse/FB8-47 The max user name length is increased to 80 chars (utf8mb3) Since the system tables are InnoDB tables and because Primary key is on the full username (80 *3 = 240 bytes) and other columns, InnoDb initialization with 4k page size fails. This is new limitation. Reference Patch: facebook/mysql-5.6@3dbbcfc This mitigates upstream bug: http://bugs.mysql.com/3083 User name length limit of 16 was too short, so made it 80. 80 is effectively the limit without making additional changes because of MyISAM's 1000 byte limit on key length and the primary key of mysql.columns_priv. To compute the size of the key for that table, the lengths of the char fields are summed and then multipled by 3, resulting in a limit on the max size of user name lengths being 81 characters. Pull Request resolved: facebook/mysql-5.6#937 Reviewed By: lth Differential Revision: D13890369 Pulled By: lth fbshipit-source-id: 347fef40974
inikep
pushed a commit
to inikep/percona-server
that referenced
this pull request
Apr 23, 2020
Summary: https://jira.percona.com/browse/FB8-47 The max user name length is increased to 80 chars (utf8mb3) Since the system tables are InnoDB tables and because Primary key is on the full username (80 *3 = 240 bytes) and other columns, InnoDb initialization with 4k page size fails. This is new limitation. Reference Patch: facebook/mysql-5.6@3dbbcfc This mitigates upstream bug: http://bugs.mysql.com/3083 User name length limit of 16 was too short, so made it 80. 80 is effectively the limit without making additional changes because of MyISAM's 1000 byte limit on key length and the primary key of mysql.columns_priv. To compute the size of the key for that table, the lengths of the char fields are summed and then multipled by 3, resulting in a limit on the max size of user name lengths being 81 characters. Pull Request resolved: facebook/mysql-5.6#937 Test Plan: Added long user names to basic grant and replication tests. Did full build and test run without perfschema, no failures. Did full build and test run with perfschema, no new failures. Jenkins both 'arc unit', and 'arc unit --everything', pass Built a test rpm, ran it through rpm tests, passed. Installed the test rpm on a test server, then downgraded it: "use mysql; show create table user;", and got: * Before upgrade: "...`User` char(16)..." * After upgrade: "...`User` char(16)..." * After restart: "...`User` char(16)..." * After running mysql_upgrade: "...`User` char(80)..." * After downgrade: "...`User` char(80)..." * After restart: "...`User` char(80)..." * After running mysql_upgrade: "...`User` char(16)..." Reviewed By: lth Differential Revision: D13890369 Pulled By: lth fbshipit-source-id: 35f0728285a
inikep
pushed a commit
to inikep/percona-server
that referenced
this pull request
Feb 24, 2021
Summary: https://jira.percona.com/browse/FB8-47 The max user name length is increased to 80 chars (utf8mb3) Since the system tables are InnoDB tables and because Primary key is on the full username (80 *3 = 240 bytes) and other columns, InnoDb initialization with 4k page size fails. This is new limitation. Reference Patch: facebook/mysql-5.6@3dbbcfc This mitigates upstream bug: http://bugs.mysql.com/3083 User name length limit of 16 was too short, so made it 80. 80 is effectively the limit without making additional changes because of MyISAM's 1000 byte limit on key length and the primary key of mysql.columns_priv. To compute the size of the key for that table, the lengths of the char fields are summed and then multipled by 3, resulting in a limit on the max size of user name lengths being 81 characters. Pull Request resolved: facebook/mysql-5.6#937 Test Plan: Added long user names to basic grant and replication tests. Did full build and test run without perfschema, no failures. Did full build and test run with perfschema, no new failures. Jenkins both 'arc unit', and 'arc unit --everything', pass Built a test rpm, ran it through rpm tests, passed. Installed the test rpm on a test server, then downgraded it: "use mysql; show create table user;", and got: * Before upgrade: "...`User` char(16)..." * After upgrade: "...`User` char(16)..." * After restart: "...`User` char(16)..." * After running mysql_upgrade: "...`User` char(80)..." * After downgrade: "...`User` char(80)..." * After restart: "...`User` char(80)..." * After running mysql_upgrade: "...`User` char(16)..." Reviewed By: lth Differential Revision: D13890369 Pulled By: lth fbshipit-source-id: 35f0728285a
inikep
pushed a commit
to inikep/percona-server
that referenced
this pull request
Nov 15, 2021
Summary: https://jira.percona.com/browse/FB8-47 The max user name length is increased to 80 chars (utf8mb3) Since the system tables are InnoDB tables and because Primary key is on the full username (80 *3 = 240 bytes) and other columns, InnoDb initialization with 4k page size fails. This is new limitation. Reference Patch: facebook/mysql-5.6@3dbbcfc This mitigates upstream bug: http://bugs.mysql.com/3083 User name length limit of 16 was too short, so made it 80. 80 is effectively the limit without making additional changes because of MyISAM's 1000 byte limit on key length and the primary key of mysql.columns_priv. To compute the size of the key for that table, the lengths of the char fields are summed and then multipled by 3, resulting in a limit on the max size of user name lengths being 81 characters. Pull Request resolved: facebook/mysql-5.6#937 Reviewed By: lloyd Differential Revision: D13890369 (facebook/mysql-5.6@1075e57) Pulled By: lth fbshipit-source-id: 2ec67345fb8
ldonoso
pushed a commit
to ldonoso/percona-server
that referenced
this pull request
Mar 15, 2022
Summary: https://jira.percona.com/browse/FB8-47 The max user name length is increased to 80 chars (utf8mb3) Since the system tables are InnoDB tables and because Primary key is on the full username (80 *3 = 240 bytes) and other columns, InnoDb initialization with 4k page size fails. This is new limitation. Reference Patch: facebook/mysql-5.6@3dbbcfc This mitigates upstream bug: http://bugs.mysql.com/3083 User name length limit of 16 was too short, so made it 80. 80 is effectively the limit without making additional changes because of MyISAM's 1000 byte limit on key length and the primary key of mysql.columns_priv. To compute the size of the key for that table, the lengths of the char fields are summed and then multipled by 3, resulting in a limit on the max size of user name lengths being 81 characters. Pull Request resolved: facebook/mysql-5.6#937 Reviewed By: lloyd Differential Revision: D13890369 Pulled By: lth
ldonoso
pushed a commit
to ldonoso/percona-server
that referenced
this pull request
Mar 15, 2022
Summary: https://jira.percona.com/browse/FB8-47 The max user name length is increased to 80 chars (utf8mb3) Since the system tables are InnoDB tables and because Primary key is on the full username (80 *3 = 240 bytes) and other columns, InnoDb initialization with 4k page size fails. This is new limitation. Reference Patch: facebook/mysql-5.6@3dbbcfc This mitigates upstream bug: http://bugs.mysql.com/3083 User name length limit of 16 was too short, so made it 80. 80 is effectively the limit without making additional changes because of MyISAM's 1000 byte limit on key length and the primary key of mysql.columns_priv. To compute the size of the key for that table, the lengths of the char fields are summed and then multipled by 3, resulting in a limit on the max size of user name lengths being 81 characters. Pull Request resolved: facebook/mysql-5.6#937 Reviewed By: lloyd Differential Revision: D13890369 Pulled By: lth
ldonoso
pushed a commit
to ldonoso/percona-server
that referenced
this pull request
Mar 18, 2022
Summary: https://jira.percona.com/browse/FB8-47 The max user name length is increased to 80 chars (utf8mb3) Since the system tables are InnoDB tables and because Primary key is on the full username (80 *3 = 240 bytes) and other columns, InnoDb initialization with 4k page size fails. This is new limitation. Reference Patch: facebook/mysql-5.6@3dbbcfc This mitigates upstream bug: http://bugs.mysql.com/3083 User name length limit of 16 was too short, so made it 80. 80 is effectively the limit without making additional changes because of MyISAM's 1000 byte limit on key length and the primary key of mysql.columns_priv. To compute the size of the key for that table, the lengths of the char fields are summed and then multipled by 3, resulting in a limit on the max size of user name lengths being 81 characters. Pull Request resolved: facebook/mysql-5.6#937 Reviewed By: lloyd Differential Revision: D13890369 Pulled By: lth
ldonoso
pushed a commit
to ldonoso/percona-server
that referenced
this pull request
Apr 12, 2022
Summary: https://jira.percona.com/browse/FB8-47 The max user name length is increased to 80 chars (utf8mb3) Since the system tables are InnoDB tables and because Primary key is on the full username (80 *3 = 240 bytes) and other columns, InnoDb initialization with 4k page size fails. This is new limitation. Reference Patch: facebook/mysql-5.6@3dbbcfc This mitigates upstream bug: http://bugs.mysql.com/3083 User name length limit of 16 was too short, so made it 80. 80 is effectively the limit without making additional changes because of MyISAM's 1000 byte limit on key length and the primary key of mysql.columns_priv. To compute the size of the key for that table, the lengths of the char fields are summed and then multipled by 3, resulting in a limit on the max size of user name lengths being 81 characters. Pull Request resolved: facebook/mysql-5.6#937 Reviewed By: lloyd Differential Revision: D13890369 Pulled By: lth
inikep
pushed a commit
to inikep/percona-server
that referenced
this pull request
Apr 15, 2024
Summary: https://jira.percona.com/browse/FB8-47 The max user name length is increased to 80 chars (utf8mb3) Since the system tables are InnoDB tables and because Primary key is on the full username (80 *3 = 240 bytes) and other columns, InnoDb initialization with 4k page size fails. This is new limitation. Reference Patch: facebook/mysql-5.6@3dbbcfc This mitigates upstream bug: http://bugs.mysql.com/3083 User name length limit of 16 was too short, so made it 80. 80 is effectively the limit without making additional changes because of MyISAM's 1000 byte limit on key length and the primary key of mysql.columns_priv. To compute the size of the key for that table, the lengths of the char fields are summed and then multipled by 3, resulting in a limit on the max size of user name lengths being 81 characters. Pull Request resolved: facebook/mysql-5.6#937 Reviewed By: lloyd Differential Revision: D13890369 Pulled By: lth
inikep
pushed a commit
to inikep/percona-server
that referenced
this pull request
Apr 16, 2024
Summary: https://jira.percona.com/browse/FB8-47 The max user name length is increased to 80 chars (utf8mb3) Since the system tables are InnoDB tables and because Primary key is on the full username (80 *3 = 240 bytes) and other columns, InnoDb initialization with 4k page size fails. This is new limitation. Reference Patch: facebook/mysql-5.6@3dbbcfc This mitigates upstream bug: http://bugs.mysql.com/3083 User name length limit of 16 was too short, so made it 80. 80 is effectively the limit without making additional changes because of MyISAM's 1000 byte limit on key length and the primary key of mysql.columns_priv. To compute the size of the key for that table, the lengths of the char fields are summed and then multipled by 3, resulting in a limit on the max size of user name lengths being 81 characters. Pull Request resolved: facebook/mysql-5.6#937 Reviewed By: lloyd Differential Revision: D13890369 Pulled By: lth
inikep
pushed a commit
to inikep/percona-server
that referenced
this pull request
Apr 17, 2024
Summary: https://jira.percona.com/browse/FB8-47 The max user name length is increased to 80 chars (utf8mb3) Since the system tables are InnoDB tables and because Primary key is on the full username (80 *3 = 240 bytes) and other columns, InnoDb initialization with 4k page size fails. This is new limitation. Reference Patch: facebook/mysql-5.6@3dbbcfc This mitigates upstream bug: http://bugs.mysql.com/3083 User name length limit of 16 was too short, so made it 80. 80 is effectively the limit without making additional changes because of MyISAM's 1000 byte limit on key length and the primary key of mysql.columns_priv. To compute the size of the key for that table, the lengths of the char fields are summed and then multipled by 3, resulting in a limit on the max size of user name lengths being 81 characters. Pull Request resolved: facebook/mysql-5.6#937 Reviewed By: lloyd Differential Revision: D13890369 Pulled By: lth
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
This is caused by hstcpsvr::threads, which is
auto_ptrcontainer<std::vector<worker_thread_type *> > (effectively
std::vector<foo *>), having clear() method, which clears the container
without deleting the member pointers, which are owned by the
container.
Fix by making clear delete the pointers, and by making destructor to
call clear instead of deleting pointers by itself.
http://jenkins.percona.com/job/percona-server-5.6-param/1341/
http://jenkins.percona.com/job/percona-server-5.6-valgrind/173/