Details
-
New Feature
-
Status: Open (View Workflow)
-
Major
-
Resolution: Unresolved
-
None
Description
LOAD DATA currently supports reading from files and from the client (LOAD DATA LOCAL).
There's a certain interest in the ability to load data from more sources, in particular from AWS S3, but also from http[s]. This could also enable us to handle compressed files that is using any of the compression format the server supports.
We'll solve it by abstracting file reading code into the plugin. Initially there will be two plugins, file and "local".
The syntax
LOAD { DATA | XML } [ LOCAL ] INFILE ... |
will be generalized to
LOAD { DATA | XML } [ plugin ] INFILE ... |
We might need some kind of plugin-specific syntax extension for LOAD, so that AWS plugin would be able to specify the credentials. Or may be not, if everything can be part of the "filename", like in http://user:password@host.name/path/to/file
Preferably it should work for SELECT ... INTO OUTFILE too.
Attachments
Issue Links
- blocks
-
MCOL-5013 Support Load data from AWS S3 : UDF : columnstore_info.load_from_s3
-
- Closed
-
- is duplicated by
-
MDEV-23814 LOAD DATA INFILE 's3://mybucket/myobject.json'
-
- Closed
-
- relates to
-
MDEV-33188 Enhance mariadb-dump and mariadb-import capabilities similar to MyDumper
-
- Stalled
-
-
MXS-4618 Load data from S3
-
- Closed
-
strictly speaking, there're three kinds of actions here.
Which gives the syntax
LOAD plugin1 [LOW_PRIORITY | CONCURRENT] [plugin2] INFILE 'location'
[ REPLACE | IGNORE ] INFO table
[CHARACTER SET charset_name]
plugin1params
[IGNORE number {LINES|ROWS}]
[(col_name_or_user_var,...)]
[SET col_name = expr,...]
pligin1 is something like DATA, XML, JSON, etc. plugin2 could be LOAD, S3, etc. filtering would need an additional syntax not included above. the syntax above will likely be impossible due to bison limitations and will need to be adjusted during implementation