[Enhancement](streamload) stream tvf support user specified label (#24219)
stream tvf support user specified label example: curl -v --location-trusted -u root: -H "sql: insert into test.t1 WITH LABEL label1 select c1,c2 from http_stream(\"format\" = \"CSV\", \"column_separator\" = \",\")" -T example.csv http://127.0.0.1:8030/api/_http_stream return: { "TxnId": 2064, "Label": "label1", "Comment": "", "TwoPhaseCommit": "false", "Status": "Success", "Message": "OK", "NumberTotalRows": 2, "NumberLoadedRows": 2, "NumberFilteredRows": 0, "NumberUnselectedRows": 0, "LoadBytes": 27, "LoadTimeMs": 152, "BeginTxnTimeMs": 0, "StreamLoadPutTimeMs": 83, "ReadDataTimeMs": 92, "WriteDataTimeMs": 41, "CommitAndPublishTimeMs": 24 }
This commit is contained in:
@ -2079,6 +2079,7 @@ public class FrontendServiceImpl implements FrontendService.Iface {
|
||||
result.getParams().setTableName(parsedStmt.getTbl());
|
||||
// The txn_id here is obtained from the NativeInsertStmt
|
||||
result.getParams().setTxnConf(new TTxnParams().setTxnId(txn_id));
|
||||
result.getParams().setImportLabel(parsedStmt.getLabel());
|
||||
if (parsedStmt.isGroupCommitTvf) {
|
||||
result.getParams().params.setGroupCommit(true);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user