Type:
Task
Priority:
Blocker
Resolution:
Done
The Spider storage engine provides two ways to specify remote data nodes. One is by the COMMENT clause and the other is by the CONNECTION clause (see below links for existing options). However, writing every specification in a single connection string is not very user-friendly.
We introduce new engine-defined attributes to specify remote data nodes. The engine attributes do not cover all the existing DSN parameters because most of the parameters need not be specified at the table level. So, we first introduce engine-defined attributes that correspond to essential parameters. If users complain that a parameter they need is missing, we can introduce it later.
I believe that the following attributes are enough:
engine-defined attribute
corresponding DNS parameter
REMOTE_SERVER
srv
REMOTE_DATABASE
database
REMOTE_TABLE
tbl
Writing a raw password in the COMMENT or engine-defined option is not preferable from the viewpoint of security because the password might be logged in slow log or general log. Therefore, we should encourage the use of the CREATE SERVER statement, and not introduce attributes such as REMOTE_USER and REMOTE_PASSWORD .
SSL-related parameters might be essential but I believe that they should be covered by CREATE SERVER statement rather than per-table or per-partition attributes.
If, for example, both COMMENT='table "t1"' and REMOTE_TABLE="t2" are specified for a single table or a single partition, the Spider returns an error.
Example:
CREATE TABLE `users` (
`id` INT ,
` name ` VARCHAR (255)
) ENGINE=SPIDER REMOTE_TABLE= "users"
PARTITION BY HASH(id)
(
PARTITION `pt1` REMOTE_SERVER= "s1" REMOTE_DATABASE= "db1" ,
PARTITION `pt2` REMOTE_SERVER= "s1" REMOTE_DATABASE= "db2" ,
PARTITION `pt3` REMOTE_SERVER= "s2" REMOTE_DATABASE= "db1"
);
TODO:
Introduce engine-defined attributes described above;
Make Spider to use the attributes;
Write comprehensive test cases;
Refactor entire patch.
{"report":{"fcp":1694.2000002861023,"ttfb":483,"pageVisibility":"visible","entityId":86852,"key":"jira.project.issue.view-issue","isInitial":true,"threshold":1000,"elementTimings":{},"userDeviceMemory":8,"userDeviceProcessors":64,"apdex":0.5,"journeyId":"15e392fe-bec3-4349-a8e5-3e942d6c9241","navigationType":0,"readyForUser":1881.8000001907349,"redirectCount":0,"resourceLoadedEnd":2317,"resourceLoadedStart":488.90000009536743,"resourceTiming":[{"duration":655.2000002861023,"initiatorType":"link","name":"https://jira.mariadb.org/s/2c21342762a6a02add1c328bed317ffd-CDN/lu2cib/820016/12ta74/0a8bac35585be7fc6c9cc5a0464cd4cf/_/download/contextbatch/css/_super/batch.css","startTime":488.90000009536743,"connectEnd":0,"connectStart":0,"domainLookupEnd":0,"domainLookupStart":0,"fetchStart":488.90000009536743,"redirectEnd":0,"redirectStart":0,"requestStart":0,"responseEnd":1144.1000003814697,"responseStart":0,"secureConnectionStart":0},{"duration":655.2999997138977,"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":489.1000003814697,"connectEnd":0,"connectStart":0,"domainLookupEnd":0,"domainLookupStart":0,"fetchStart":489.1000003814697,"redirectEnd":0,"redirectStart":0,"requestStart":0,"responseEnd":1144.4000000953674,"responseStart":0,"secureConnectionStart":0},{"duration":677.7999997138977,"initiatorType":"script","name":"https://jira.mariadb.org/s/0917945aaa57108d00c5076fea35e069-CDN/lu2cib/820016/12ta74/0a8bac35585be7fc6c9cc5a0464cd4cf/_/download/contextbatch/js/_super/batch.js?locale=en","startTime":489.2000002861023,"connectEnd":489.2000002861023,"connectStart":489.2000002861023,"domainLookupEnd":489.2000002861023,"domainLookupStart":489.2000002861023,"fetchStart":489.2000002861023,"redirectEnd":0,"redirectStart":0,"requestStart":489.2000002861023,"responseEnd":1167,"responseStart":1167,"secureConnectionStart":489.2000002861023},{"duration":785.9000000953674,"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":489.5,"connectEnd":489.5,"connectStart":489.5,"domainLookupEnd":489.5,"domainLookupStart":489.5,"fetchStart":489.5,"redirectEnd":0,"redirectStart":0,"requestStart":489.5,"responseEnd":1275.4000000953674,"responseStart":1275.4000000953674,"secureConnectionStart":489.5},{"duration":811,"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":489.7000002861023,"connectEnd":489.7000002861023,"connectStart":489.7000002861023,"domainLookupEnd":489.7000002861023,"domainLookupStart":489.7000002861023,"fetchStart":489.7000002861023,"redirectEnd":0,"redirectStart":0,"requestStart":489.7000002861023,"responseEnd":1300.7000002861023,"responseStart":1300.7000002861023,"secureConnectionStart":489.7000002861023},{"duration":811.7000002861023,"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":489.90000009536743,"connectEnd":489.90000009536743,"connectStart":489.90000009536743,"domainLookupEnd":489.90000009536743,"domainLookupStart":489.90000009536743,"fetchStart":489.90000009536743,"redirectEnd":0,"redirectStart":0,"requestStart":489.90000009536743,"responseEnd":1301.6000003814697,"responseStart":1301.6000003814697,"secureConnectionStart":489.90000009536743},{"duration":812.4000000953674,"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":490,"connectEnd":490,"connectStart":490,"domainLookupEnd":490,"domainLookupStart":490,"fetchStart":490,"redirectEnd":0,"redirectStart":0,"requestStart":490,"responseEnd":1302.4000000953674,"responseStart":1302.4000000953674,"secureConnectionStart":490},{"duration":847.8000001907349,"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":490.30000019073486,"connectEnd":0,"connectStart":0,"domainLookupEnd":0,"domainLookupStart":0,"fetchStart":490.30000019073486,"redirectEnd":0,"redirectStart":0,"requestStart":0,"responseEnd":1338.1000003814697,"responseStart":0,"secureConnectionStart":0},{"duration":814.4000000953674,"initiatorType":"script","name":"https://jira.mariadb.org/rest/api/1.0/shortcuts/820016/47140b6e0a9bc2e4913da06536125810/shortcuts.js?context=issuenavigation&context=issueaction","startTime":490.5,"connectEnd":490.5,"connectStart":490.5,"domainLookupEnd":490.5,"domainLookupStart":490.5,"fetchStart":490.5,"redirectEnd":0,"redirectStart":0,"requestStart":490.5,"responseEnd":1304.9000000953674,"responseStart":1304.9000000953674,"secureConnectionStart":490.5},{"duration":847.5999999046326,"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":490.6000003814697,"connectEnd":0,"connectStart":0,"domainLookupEnd":0,"domainLookupStart":0,"fetchStart":490.6000003814697,"redirectEnd":0,"redirectStart":0,"requestStart":0,"responseEnd":1338.2000002861023,"responseStart":0,"secureConnectionStart":0},{"duration":819.4000000953674,"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":491,"connectEnd":491,"connectStart":491,"domainLookupEnd":491,"domainLookupStart":491,"fetchStart":491,"redirectEnd":0,"redirectStart":0,"requestStart":491,"responseEnd":1310.4000000953674,"responseStart":1310.4000000953674,"secureConnectionStart":491},{"duration":1575.4000000953674,"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":497.80000019073486,"connectEnd":497.80000019073486,"connectStart":497.80000019073486,"domainLookupEnd":497.80000019073486,"domainLookupStart":497.80000019073486,"fetchStart":497.80000019073486,"redirectEnd":0,"redirectStart":0,"requestStart":497.80000019073486,"responseEnd":2073.2000002861023,"responseStart":2073.2000002861023,"secureConnectionStart":497.80000019073486},{"duration":1819.0999999046326,"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":497.90000009536743,"connectEnd":497.90000009536743,"connectStart":497.90000009536743,"domainLookupEnd":497.90000009536743,"domainLookupStart":497.90000009536743,"fetchStart":497.90000009536743,"redirectEnd":0,"redirectStart":0,"requestStart":497.90000009536743,"responseEnd":2317,"responseStart":2317,"secureConnectionStart":497.90000009536743},{"duration":768.5,"initiatorType":"xmlhttprequest","name":"https://jira.mariadb.org/rest/webResources/1.0/resources","startTime":1359.8000001907349,"connectEnd":1359.8000001907349,"connectStart":1359.8000001907349,"domainLookupEnd":1359.8000001907349,"domainLookupStart":1359.8000001907349,"fetchStart":1359.8000001907349,"redirectEnd":0,"redirectStart":0,"requestStart":1359.8000001907349,"responseEnd":2128.300000190735,"responseStart":2128.300000190735,"secureConnectionStart":1359.8000001907349},{"duration":733.0999999046326,"initiatorType":"script","name":"https://www.google-analytics.com/analytics.js","startTime":1686.7000002861023,"connectEnd":0,"connectStart":0,"domainLookupEnd":0,"domainLookupStart":0,"fetchStart":1686.7000002861023,"redirectEnd":0,"redirectStart":0,"requestStart":0,"responseEnd":2419.800000190735,"responseStart":0,"secureConnectionStart":0}],"fetchStart":0,"domainLookupStart":0,"domainLookupEnd":0,"connectStart":0,"connectEnd":0,"requestStart":303,"responseStart":483,"responseEnd":492,"domLoading":486,"domInteractive":2352,"domContentLoadedEventStart":2352,"domContentLoadedEventEnd":2412,"domComplete":4558,"loadEventStart":4558,"loadEventEnd":4560,"userAgent":"Mozilla/5.0 AppleWebKit/537.36 (KHTML, like Gecko; compatible; ClaudeBot/1.0; +claudebot@anthropic.com)","marks":[{"name":"bigPipe.sidebar-id.start","time":2319.7000002861023},{"name":"bigPipe.sidebar-id.end","time":2321.1000003814697},{"name":"bigPipe.activity-panel-pipe-id.start","time":2321.300000190735},{"name":"bigPipe.activity-panel-pipe-id.end","time":2324.1000003814697},{"name":"activityTabFullyLoaded","time":2465.1000003814697}],"measures":[],"correlationId":"daa38b51019ce1","effectiveType":"4g","downlink":10,"rtt":0,"serverDuration":118,"dbReadsTimeInMs":26,"dbConnsTimeInMs":37,"applicationHash":"9d11dbea5f4be3d4cc21f03a88dd11d8c8687422","experiments":[]}}