-
Task
-
-
Major
-
Resolution:
Fixed
-
-
-
The code in the following methods:
Item::make_string_field()
|
Item::tmp_table_field_from_field_type()
|
Item_type_holder::make_field_by_type()
|
is not friendly to new data types, because it has conditions on field_type.
To make the code more friendly, we'll add two new virtual methods in Type_handler:
virtual const Type_handler *type_handler_for_tmp_table(const Item *) const;
|
virtual const Type_handler *type_handler_for_union(const Item *) const;
|
This will simplify the code a lot:
- Item::make_string_field() will be gone
- Item_func_group_concat::make_string_field() will be gone
- Item::tmp_table_field_from_field_type() will simplify to:
Field *tmp_table_field_from_field_type(TABLE *table)
|
{
|
const Type_handler *h= type_handler()->type_handler_for_tmp_table(this);
|
return h->make_and_init_table_field(&name, Record_addr(maybe_null),
|
*this, table);
|
}
|
- Item_type_holder::make_field_by_type() will be renamed to create_tmp_field} and simplify to:
Field *create_tmp_field(bool group, TABLE *table)
|
{
|
return Item_type_holder::type_handler()->
|
make_and_init_table_field(&name, Record_addr(maybe_null),
|
*this, table);
|
}
|
- The TIME_RESULT, STRING_RESULT, DECIMAL_RESULT branches in Item::create_tmp_field() will be simplified to:
case TIME_RESULT:
|
case DECIMAL_RESULT:
|
case STRING_RESULT:
|
new_field= tmp_table_field_from_field_type(table);
|
{"report":{"fcp":780.5,"ttfb":193.79999995231628,"pageVisibility":"visible","entityId":61058,"key":"jira.project.issue.view-issue","isInitial":true,"threshold":1000,"elementTimings":{},"userDeviceMemory":8,"userDeviceProcessors":64,"apdex":1,"journeyId":"810d8dc8-bc5a-4377-bc2b-cc0178c846f9","navigationType":0,"readyForUser":899,"redirectCount":0,"resourceLoadedEnd":510.40000009536743,"resourceLoadedStart":200.79999995231628,"resourceTiming":[{"duration":3.9000000953674316,"initiatorType":"link","name":"https://jira.mariadb.org/s/2c21342762a6a02add1c328bed317ffd-CDN/lu2bu7/820016/12ta74/0a8bac35585be7fc6c9cc5a0464cd4cf/_/download/contextbatch/css/_super/batch.css","startTime":200.79999995231628,"connectEnd":0,"connectStart":0,"domainLookupEnd":0,"domainLookupStart":0,"fetchStart":200.79999995231628,"redirectEnd":0,"redirectStart":0,"requestStart":0,"responseEnd":204.70000004768372,"responseStart":0,"secureConnectionStart":0},{"duration":4.5,"initiatorType":"link","name":"https://jira.mariadb.org/s/7ebd35e77e471bc30ff0eba799ebc151-CDN/lu2bu7/820016/12ta74/8679b4946efa1a0bb029a3a22206fb5d/_/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","startTime":202.70000004768372,"connectEnd":0,"connectStart":0,"domainLookupEnd":0,"domainLookupStart":0,"fetchStart":202.70000004768372,"redirectEnd":0,"redirectStart":0,"requestStart":0,"responseEnd":207.20000004768372,"responseStart":0,"secureConnectionStart":0},{"duration":167.20000004768372,"initiatorType":"script","name":"https://jira.mariadb.org/s/fbf975c0cce4b1abf04784eeae9ba1f4-CDN/lu2bu7/820016/12ta74/0a8bac35585be7fc6c9cc5a0464cd4cf/_/download/contextbatch/js/_super/batch.js?locale=en","startTime":202.79999995231628,"connectEnd":202.79999995231628,"connectStart":202.79999995231628,"domainLookupEnd":202.79999995231628,"domainLookupStart":202.79999995231628,"fetchStart":202.79999995231628,"redirectEnd":0,"redirectStart":0,"requestStart":209.5,"responseEnd":370,"responseStart":224.5,"secureConnectionStart":202.79999995231628},{"duration":279.5,"initiatorType":"script","name":"https://jira.mariadb.org/s/099b33461394b8015fc36c0a4b96e19f-CDN/lu2bu7/820016/12ta74/8679b4946efa1a0bb029a3a22206fb5d/_/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","startTime":203.29999995231628,"connectEnd":203.29999995231628,"connectStart":203.29999995231628,"domainLookupEnd":203.29999995231628,"domainLookupStart":203.29999995231628,"fetchStart":203.29999995231628,"redirectEnd":0,"redirectStart":0,"requestStart":210.10000014305115,"responseEnd":482.7999999523163,"responseStart":233.20000004768372,"secureConnectionStart":203.29999995231628},{"duration":31,"initiatorType":"script","name":"https://jira.mariadb.org/s/94c15bff32baef80f4096a08aceae8bc-CDN/lu2bu7/820016/12ta74/c92c0caa9a024ae85b0ebdbed7fb4bd7/_/download/contextbatch/js/atl.global,-_super/batch.js?locale=en","startTime":203.40000009536743,"connectEnd":203.40000009536743,"connectStart":203.40000009536743,"domainLookupEnd":203.40000009536743,"domainLookupStart":203.40000009536743,"fetchStart":203.40000009536743,"redirectEnd":0,"redirectStart":0,"requestStart":211.10000014305115,"responseEnd":234.40000009536743,"responseStart":231.5,"secureConnectionStart":203.40000009536743},{"duration":31.200000047683716,"initiatorType":"script","name":"https://jira.mariadb.org/s/d41d8cd98f00b204e9800998ecf8427e-CDN/lu2bu7/820016/12ta74/1.0/_/download/batch/jira.webresources:calendar-en/jira.webresources:calendar-en.js","startTime":203.5,"connectEnd":203.5,"connectStart":203.5,"domainLookupEnd":203.5,"domainLookupStart":203.5,"fetchStart":203.5,"redirectEnd":0,"redirectStart":0,"requestStart":211.70000004768372,"responseEnd":234.70000004768372,"responseStart":232.20000004768372,"secureConnectionStart":203.5},{"duration":37.19999980926514,"initiatorType":"script","name":"https://jira.mariadb.org/s/d41d8cd98f00b204e9800998ecf8427e-CDN/lu2bu7/820016/12ta74/1.0/_/download/batch/jira.webresources:calendar-localisation-moment/jira.webresources:calendar-localisation-moment.js","startTime":203.60000014305115,"connectEnd":203.60000014305115,"connectStart":203.60000014305115,"domainLookupEnd":203.60000014305115,"domainLookupStart":203.60000014305115,"fetchStart":203.60000014305115,"redirectEnd":0,"redirectStart":0,"requestStart":215.60000014305115,"responseEnd":240.79999995231628,"responseStart":239.5,"secureConnectionStart":203.60000014305115},{"duration":8.200000047683716,"initiatorType":"link","name":"https://jira.mariadb.org/s/b04b06a02d1959df322d9cded3aeecc1-CDN/lu2bu7/820016/12ta74/a2ff6aa845ffc9a1d22fe23d9ee791fc/_/download/contextbatch/css/jira.global.look-and-feel,-_super/batch.css","startTime":203.70000004768372,"connectEnd":0,"connectStart":0,"domainLookupEnd":0,"domainLookupStart":0,"fetchStart":203.70000004768372,"redirectEnd":0,"redirectStart":0,"requestStart":0,"responseEnd":211.90000009536743,"responseStart":0,"secureConnectionStart":0},{"duration":61.90000009536743,"initiatorType":"script","name":"https://jira.mariadb.org/rest/api/1.0/shortcuts/820016/47140b6e0a9bc2e4913da06536125810/shortcuts.js?context=issuenavigation&context=issueaction","startTime":203.79999995231628,"connectEnd":203.79999995231628,"connectStart":203.79999995231628,"domainLookupEnd":203.79999995231628,"domainLookupStart":203.79999995231628,"fetchStart":203.79999995231628,"redirectEnd":0,"redirectStart":0,"requestStart":217.29999995231628,"responseEnd":265.7000000476837,"responseStart":263.7000000476837,"secureConnectionStart":203.79999995231628},{"duration":11.200000047683716,"initiatorType":"link","name":"https://jira.mariadb.org/s/3ac36323ba5e4eb0af2aa7ac7211b4bb-CDN/lu2bu7/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":203.90000009536743,"connectEnd":0,"connectStart":0,"domainLookupEnd":0,"domainLookupStart":0,"fetchStart":203.90000009536743,"redirectEnd":0,"redirectStart":0,"requestStart":0,"responseEnd":215.10000014305115,"responseStart":0,"secureConnectionStart":0},{"duration":40.10000014305115,"initiatorType":"script","name":"https://jira.mariadb.org/s/3339d87fa2538a859872f2df449bf8d0-CDN/lu2bu7/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":204,"connectEnd":204,"connectStart":204,"domainLookupEnd":204,"domainLookupStart":204,"fetchStart":204,"redirectEnd":0,"redirectStart":0,"requestStart":217.40000009536743,"responseEnd":244.10000014305115,"responseStart":241.20000004768372,"secureConnectionStart":204},{"duration":303.10000014305115,"initiatorType":"script","name":"https://jira.mariadb.org/s/d41d8cd98f00b204e9800998ecf8427e-CDN/lu2bu7/820016/12ta74/1.0/_/download/batch/jira.webresources:bigpipe-js/jira.webresources:bigpipe-js.js","startTime":207.29999995231628,"connectEnd":207.29999995231628,"connectStart":207.29999995231628,"domainLookupEnd":207.29999995231628,"domainLookupStart":207.29999995231628,"fetchStart":207.29999995231628,"redirectEnd":0,"redirectStart":0,"requestStart":231.20000004768372,"responseEnd":510.40000009536743,"responseStart":507.90000009536743,"secureConnectionStart":207.29999995231628},{"duration":301.60000014305115,"initiatorType":"script","name":"https://jira.mariadb.org/s/d41d8cd98f00b204e9800998ecf8427e-CDN/lu2bu7/820016/12ta74/1.0/_/download/batch/jira.webresources:bigpipe-init/jira.webresources:bigpipe-init.js","startTime":207.5,"connectEnd":207.5,"connectStart":207.5,"domainLookupEnd":207.5,"domainLookupStart":207.5,"fetchStart":207.5,"redirectEnd":0,"redirectStart":0,"requestStart":235,"responseEnd":509.10000014305115,"responseStart":504.7999999523163,"secureConnectionStart":207.5},{"duration":57.299999952316284,"initiatorType":"xmlhttprequest","name":"https://jira.mariadb.org/rest/webResources/1.0/resources","startTime":518.4000000953674,"connectEnd":518.4000000953674,"connectStart":518.4000000953674,"domainLookupEnd":518.4000000953674,"domainLookupStart":518.4000000953674,"fetchStart":518.4000000953674,"redirectEnd":0,"redirectStart":0,"requestStart":544.9000000953674,"responseEnd":575.7000000476837,"responseStart":574.5,"secureConnectionStart":518.4000000953674},{"duration":97.79999995231628,"initiatorType":"script","name":"https://www.google-analytics.com/analytics.js","startTime":774,"connectEnd":0,"connectStart":0,"domainLookupEnd":0,"domainLookupStart":0,"fetchStart":774,"redirectEnd":0,"redirectStart":0,"requestStart":0,"responseEnd":871.7999999523163,"responseStart":0,"secureConnectionStart":0},{"duration":125.79999995231628,"initiatorType":"xmlhttprequest","name":"https://jira.mariadb.org/rest/webResources/1.0/resources","startTime":780.5,"connectEnd":780.5,"connectStart":780.5,"domainLookupEnd":780.5,"domainLookupStart":780.5,"fetchStart":780.5,"redirectEnd":0,"redirectStart":0,"requestStart":874.2999999523163,"responseEnd":906.2999999523163,"responseStart":905.5,"secureConnectionStart":780.5}],"fetchStart":1,"domainLookupStart":1,"domainLookupEnd":1,"connectStart":1,"connectEnd":1,"requestStart":50,"responseStart":194,"responseEnd":207,"domLoading":197,"domInteractive":958,"domContentLoadedEventStart":958,"domContentLoadedEventEnd":1001,"domComplete":1425,"loadEventStart":1425,"loadEventEnd":1425,"userAgent":"Mozilla/5.0 AppleWebKit/537.36 (KHTML, like Gecko; compatible; ClaudeBot/1.0; +claudebot@anthropic.com)","marks":[{"name":"bigPipe.sidebar-id.start","time":939.6000001430511},{"name":"bigPipe.sidebar-id.end","time":940.4000000953674},{"name":"bigPipe.activity-panel-pipe-id.start","time":940.6000001430511},{"name":"bigPipe.activity-panel-pipe-id.end","time":941.5},{"name":"activityTabFullyLoaded","time":1019.4000000953674}],"measures":[],"correlationId":"13d2a2cd0891e7","effectiveType":"4g","downlink":10,"rtt":0,"serverDuration":78,"dbReadsTimeInMs":12,"dbConnsTimeInMs":19,"applicationHash":"9d11dbea5f4be3d4cc21f03a88dd11d8c8687422","experiments":[]}}
OK to push.