This commit is contained in:
jimmyc2006 2025-04-10 16:23:14 +08:00 committed by GitHub
commit 76a5faf9a5
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -222,9 +222,11 @@ public class StreamReader extends Reader {
public void startRead(RecordSender recordSender) {
Record oneRecord = buildOneRecord(recordSender, this.columns);
while (this.sliceRecordCount > 0) {
if (this.haveMixupFunction) {
// 如果用户配置了transformer会造成对同一个记录重复操作的问题除非用户在不使用随机函数的情况下配置了"hasMixupFunction" : true
// recordSender.sendToWriter(oneRecord)这个方法可能对oneRecord的数据进行修改所以使用前需要先复制一下或者每次都重新生成
// if (this.haveMixupFunction) {
oneRecord = buildOneRecord(recordSender, this.columns);
}
// }
recordSender.sendToWriter(oneRecord);
this.sliceRecordCount--;
}