Type:
Task
Priority:
Major
Resolution:
Unresolved
Fix Version/s:
None
currently a collation lookup (collation name to collation id) is done (in get_collation_number_internal() ) by linearly scanning the array of collations.
This used to work fine, but the number of collations is constantly growing (MDEV-27009 , MDEV-20912 ) and the linear search is starting to become noticeable.
It would be a good idea to change it to a hash lookup.
Same can be done for character sets, even though the number of charsets didn't grow that much.
Sergei Golubchik
made changes -
2025-01-17 11:51
Description
currently a collation lookup (collation name to collation id) is done (in {{get_collation_number_internal()}}) by linearly scanning the array of collations.
This used to work fine, but the number of collations is constantly growing (MDEV-27009 , MDEV-35256 ) and the linear search is starting to become noticeable.
It would be a good idea to change it to a hash lookup.
Same can be done for character sets, even though the number of charsets didn't grow that much.
currently a collation lookup (collation name to collation id) is done (in {{get_collation_number_internal()}}) by linearly scanning the array of collations.
This used to work fine, but the number of collations is constantly growing (MDEV-27009 , MDEV-20912 ) and the linear search is starting to become noticeable.
It would be a good idea to change it to a hash lookup.
Same can be done for character sets, even though the number of charsets didn't grow that much.
Sergei Golubchik
made changes -
2025-02-14 21:39
Labels
tech_debt
beginner-friendly tech_debt
{"report":{"fcp":1006.9000000953674,"ttfb":281.10000014305115,"pageVisibility":"visible","entityId":132429,"key":"jira.project.issue.view-issue","isInitial":true,"threshold":1000,"elementTimings":{},"userDeviceMemory":8,"userDeviceProcessors":64,"apdex":0.5,"journeyId":"0647d4d1-69f2-4224-9d6f-3c3907941fcc","navigationType":0,"readyForUser":1121.2000000476837,"redirectCount":0,"resourceLoadedEnd":1494.1000001430511,"resourceLoadedStart":285.90000009536743,"resourceTiming":[{"duration":200,"initiatorType":"link","name":"https://jira.mariadb.org/s/2c21342762a6a02add1c328bed317ffd-CDN/lu2cib/820016/12ta74/0a8bac35585be7fc6c9cc5a0464cd4cf/_/download/contextbatch/css/_super/batch.css","startTime":285.90000009536743,"connectEnd":0,"connectStart":0,"domainLookupEnd":0,"domainLookupStart":0,"fetchStart":285.90000009536743,"redirectEnd":0,"redirectStart":0,"requestStart":0,"responseEnd":485.90000009536743,"responseStart":0,"secureConnectionStart":0},{"duration":200.09999990463257,"initiatorType":"link","name":"https://jira.mariadb.org/s/7ebd35e77e471bc30ff0eba799ebc151-CDN/lu2cib/820016/12ta74/494e4c556ecbb29f90a3d3b4f09cb99c/_/download/contextbatch/css/jira.browse.project,project.issue.navigator,jira.view.issue,jira.general,jira.global,atl.general,-_super/batch.css?agile_global_admin_condition=true&jag=true&jira.create.linked.issue=true&slack-enabled=true&whisper-enabled=true","startTime":286.10000014305115,"connectEnd":0,"connectStart":0,"domainLookupEnd":0,"domainLookupStart":0,"fetchStart":286.10000014305115,"redirectEnd":0,"redirectStart":0,"requestStart":0,"responseEnd":486.2000000476837,"responseStart":0,"secureConnectionStart":0},{"duration":208.80000019073486,"initiatorType":"script","name":"https://jira.mariadb.org/s/0917945aaa57108d00c5076fea35e069-CDN/lu2cib/820016/12ta74/0a8bac35585be7fc6c9cc5a0464cd4cf/_/download/contextbatch/js/_super/batch.js?locale=en","startTime":286.2999999523163,"connectEnd":286.2999999523163,"connectStart":286.2999999523163,"domainLookupEnd":286.2999999523163,"domainLookupStart":286.2999999523163,"fetchStart":286.2999999523163,"redirectEnd":0,"redirectStart":0,"requestStart":286.2999999523163,"responseEnd":495.10000014305115,"responseStart":495.10000014305115,"secureConnectionStart":286.2999999523163},{"duration":281.2999999523163,"initiatorType":"script","name":"https://jira.mariadb.org/s/2d8175ec2fa4c816e8023260bd8c1786-CDN/lu2cib/820016/12ta74/494e4c556ecbb29f90a3d3b4f09cb99c/_/download/contextbatch/js/jira.browse.project,project.issue.navigator,jira.view.issue,jira.general,jira.global,atl.general,-_super/batch.js?agile_global_admin_condition=true&jag=true&jira.create.linked.issue=true&locale=en&slack-enabled=true&whisper-enabled=true","startTime":286.5,"connectEnd":286.5,"connectStart":286.5,"domainLookupEnd":286.5,"domainLookupStart":286.5,"fetchStart":286.5,"redirectEnd":0,"redirectStart":0,"requestStart":286.5,"responseEnd":567.7999999523163,"responseStart":567.7999999523163,"secureConnectionStart":286.5},{"duration":284.2999999523163,"initiatorType":"script","name":"https://jira.mariadb.org/s/a9324d6758d385eb45c462685ad88f1d-CDN/lu2cib/820016/12ta74/c92c0caa9a024ae85b0ebdbed7fb4bd7/_/download/contextbatch/js/atl.global,-_super/batch.js?locale=en","startTime":286.7000000476837,"connectEnd":286.7000000476837,"connectStart":286.7000000476837,"domainLookupEnd":286.7000000476837,"domainLookupStart":286.7000000476837,"fetchStart":286.7000000476837,"redirectEnd":0,"redirectStart":0,"requestStart":286.7000000476837,"responseEnd":571,"responseStart":571,"secureConnectionStart":286.7000000476837},{"duration":284.7000000476837,"initiatorType":"script","name":"https://jira.mariadb.org/s/d41d8cd98f00b204e9800998ecf8427e-CDN/lu2cib/820016/12ta74/1.0/_/download/batch/jira.webresources:calendar-en/jira.webresources:calendar-en.js","startTime":286.7999999523163,"connectEnd":286.7999999523163,"connectStart":286.7999999523163,"domainLookupEnd":286.7999999523163,"domainLookupStart":286.7999999523163,"fetchStart":286.7999999523163,"redirectEnd":0,"redirectStart":0,"requestStart":286.7999999523163,"responseEnd":571.5,"responseStart":571.5,"secureConnectionStart":286.7999999523163},{"duration":384.2000000476837,"initiatorType":"script","name":"https://jira.mariadb.org/s/d41d8cd98f00b204e9800998ecf8427e-CDN/lu2cib/820016/12ta74/1.0/_/download/batch/jira.webresources:calendar-localisation-moment/jira.webresources:calendar-localisation-moment.js","startTime":287,"connectEnd":287,"connectStart":287,"domainLookupEnd":287,"domainLookupStart":287,"fetchStart":287,"redirectEnd":0,"redirectStart":0,"requestStart":287,"responseEnd":671.2000000476837,"responseStart":671.2000000476837,"secureConnectionStart":287},{"duration":384.5,"initiatorType":"link","name":"https://jira.mariadb.org/s/b04b06a02d1959df322d9cded3aeecc1-CDN/lu2cib/820016/12ta74/a2ff6aa845ffc9a1d22fe23d9ee791fc/_/download/contextbatch/css/jira.global.look-and-feel,-_super/batch.css","startTime":287.5,"connectEnd":0,"connectStart":0,"domainLookupEnd":0,"domainLookupStart":0,"fetchStart":287.5,"redirectEnd":0,"redirectStart":0,"requestStart":0,"responseEnd":672,"responseStart":0,"secureConnectionStart":0},{"duration":384,"initiatorType":"script","name":"https://jira.mariadb.org/rest/api/1.0/shortcuts/820016/47140b6e0a9bc2e4913da06536125810/shortcuts.js?context=issuenavigation&context=issueaction","startTime":287.7000000476837,"connectEnd":287.7000000476837,"connectStart":287.7000000476837,"domainLookupEnd":287.7000000476837,"domainLookupStart":287.7000000476837,"fetchStart":287.7000000476837,"redirectEnd":0,"redirectStart":0,"requestStart":287.7000000476837,"responseEnd":671.7000000476837,"responseStart":671.7000000476837,"secureConnectionStart":287.7000000476837},{"duration":384.7000000476837,"initiatorType":"link","name":"https://jira.mariadb.org/s/3ac36323ba5e4eb0af2aa7ac7211b4bb-CDN/lu2cib/820016/12ta74/d176f0986478cc64f24226b3d20c140d/_/download/contextbatch/css/com.atlassian.jira.projects.sidebar.init,-_super,-project.issue.navigator,-jira.view.issue/batch.css?jira.create.linked.issue=true","startTime":287.90000009536743,"connectEnd":0,"connectStart":0,"domainLookupEnd":0,"domainLookupStart":0,"fetchStart":287.90000009536743,"redirectEnd":0,"redirectStart":0,"requestStart":0,"responseEnd":672.6000001430511,"responseStart":0,"secureConnectionStart":0},{"duration":384.39999985694885,"initiatorType":"script","name":"https://jira.mariadb.org/s/5d5e8fe91fbc506585e83ea3b62ccc4b-CDN/lu2cib/820016/12ta74/d176f0986478cc64f24226b3d20c140d/_/download/contextbatch/js/com.atlassian.jira.projects.sidebar.init,-_super,-project.issue.navigator,-jira.view.issue/batch.js?jira.create.linked.issue=true&locale=en","startTime":288.10000014305115,"connectEnd":288.10000014305115,"connectStart":288.10000014305115,"domainLookupEnd":288.10000014305115,"domainLookupStart":288.10000014305115,"fetchStart":288.10000014305115,"redirectEnd":0,"redirectStart":0,"requestStart":288.10000014305115,"responseEnd":672.5,"responseStart":672.5,"secureConnectionStart":288.10000014305115},{"duration":854.7999999523163,"initiatorType":"script","name":"https://jira.mariadb.org/s/d41d8cd98f00b204e9800998ecf8427e-CDN/lu2cib/820016/12ta74/1.0/_/download/batch/jira.webresources:bigpipe-js/jira.webresources:bigpipe-js.js","startTime":293.90000009536743,"connectEnd":293.90000009536743,"connectStart":293.90000009536743,"domainLookupEnd":293.90000009536743,"domainLookupStart":293.90000009536743,"fetchStart":293.90000009536743,"redirectEnd":0,"redirectStart":0,"requestStart":293.90000009536743,"responseEnd":1148.7000000476837,"responseStart":1148.7000000476837,"secureConnectionStart":293.90000009536743},{"duration":1200.1000001430511,"initiatorType":"script","name":"https://jira.mariadb.org/s/d41d8cd98f00b204e9800998ecf8427e-CDN/lu2cib/820016/12ta74/1.0/_/download/batch/jira.webresources:bigpipe-init/jira.webresources:bigpipe-init.js","startTime":294,"connectEnd":294,"connectStart":294,"domainLookupEnd":294,"domainLookupStart":294,"fetchStart":294,"redirectEnd":0,"redirectStart":0,"requestStart":294,"responseEnd":1494.1000001430511,"responseStart":1494.1000001430511,"secureConnectionStart":294},{"duration":484.40000009536743,"initiatorType":"xmlhttprequest","name":"https://jira.mariadb.org/rest/webResources/1.0/resources","startTime":648.7999999523163,"connectEnd":648.7999999523163,"connectStart":648.7999999523163,"domainLookupEnd":648.7999999523163,"domainLookupStart":648.7999999523163,"fetchStart":648.7999999523163,"redirectEnd":0,"redirectStart":0,"requestStart":648.7999999523163,"responseEnd":1133.2000000476837,"responseStart":1133.2000000476837,"secureConnectionStart":648.7999999523163},{"duration":497.2000000476837,"initiatorType":"script","name":"https://www.google-analytics.com/analytics.js","startTime":1000.5,"connectEnd":0,"connectStart":0,"domainLookupEnd":0,"domainLookupStart":0,"fetchStart":1000.5,"redirectEnd":0,"redirectStart":0,"requestStart":0,"responseEnd":1497.7000000476837,"responseStart":0,"secureConnectionStart":0}],"fetchStart":0,"domainLookupStart":0,"domainLookupEnd":0,"connectStart":0,"connectEnd":0,"requestStart":77,"responseStart":281,"responseEnd":291,"domLoading":284,"domInteractive":1528,"domContentLoadedEventStart":1528,"domContentLoadedEventEnd":1578,"domComplete":2111,"loadEventStart":2111,"loadEventEnd":2112,"userAgent":"Mozilla/5.0 AppleWebKit/537.36 (KHTML, like Gecko; compatible; ClaudeBot/1.0; +claudebot@anthropic.com)","marks":[{"name":"bigPipe.sidebar-id.start","time":1499},{"name":"bigPipe.sidebar-id.end","time":1500.5},{"name":"bigPipe.activity-panel-pipe-id.start","time":1500.6000001430511},{"name":"bigPipe.activity-panel-pipe-id.end","time":1504.6000001430511},{"name":"activityTabFullyLoaded","time":1595}],"measures":[],"correlationId":"ee3cace1cf76b9","effectiveType":"4g","downlink":9.3,"rtt":0,"serverDuration":134,"dbReadsTimeInMs":21,"dbConnsTimeInMs":31,"applicationHash":"9d11dbea5f4be3d4cc21f03a88dd11d8c8687422","experiments":[]}}
Hi Team,
can I look into this task ?