pengxiangyu commented on a change in pull request #6188:
URL: https://github.com/apache/incubator-doris/pull/6188#discussion_r666622673
##########
File path:
extension/DataX/doriswriter/src/main/java/com/alibaba/datax/plugin/writer/doriswriter/Key.java
##########
@@ -92,32 +108,43 @@ public String getPassword() {
return this.options.getMap(LOAD_PROPS);
}
- public int getBatchRows() {
- final Integer rows = this.options.getInt(MAX_BATCH_ROWS);
- return (null == rows) ? 500000 : rows;
+ public long getBatchRows() {
+ return this.options.getLong(MAX_BATCH_ROWS, DEFAULT_MAX_BATCH_ROWS);
}
public long getBatchByteSize() {
- final Long size = this.options.getLong(MAX_BATCH_BYTE_SIZE);
- return (null == size) ? 94371840L : size;
+ return this.options.getLong(MAX_BATCH_BYTE_SIZE,
DEFAULT_MAX_BATCH_BYTE_SIZE);
}
+ public String getLabelPrefix() {
+ return this.options.getString(LABEL_PREFIX, DEFAULT_LABEL_PREFIX);
+ }
+
+ public String getLineDelimiter() {
+ return this.options.getString(LINE_DELIMITER, DEFAULT_LINE_DELIMITER);
+ }
private void validateStreamLoadUrl() {
- final List<String> urlList = this.getBeLoadUrlList();
+ List<String> urlList = this.getBeLoadUrlList();
+ if (urlList == null) {
+ urlList = this.getFeLoadUrlList();
+ }
+ if (urlList == null || urlList.isEmpty()) {
+ throw DataXException.asDataXException(DBUtilErrorCode.CONF_ERROR,
"Either beLoadUrl or feLoadUrl must be set");
+ }
+
for (final String host : urlList) {
if (host.split(":").length < 2) {
- throw
DataXException.asDataXException(DBUtilErrorCode.CONF_ERROR, "loadUrl的格式不正确,请输入
`be_ip:be_http_ip;be_ip:be_http_ip`。");
+ throw
DataXException.asDataXException(DBUtilErrorCode.CONF_ERROR,
+ "Invalid load url format. Should be host:port");
Review comment:
这里还是写:be_ip:be_http_ip;be_ip:be_http_ip吧
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]