File tree Expand file tree Collapse file tree 1 file changed +6
-0
lines changed
rdb/rdb-sink/src/main/java/com/dtstack/flink/sql/sink/rdb/table Expand file tree Collapse file tree 1 file changed +6
-0
lines changed Original file line number Diff line number Diff line change 3131 */
3232public class RdbTableInfo extends AbstractTargetTableInfo {
3333
34+ public static final int MAX_BATCH_SIZE = 10000 ;
35+
3436 public static final String URL_KEY = "url" ;
3537
3638 public static final String TABLE_NAME_KEY = "tableName" ;
@@ -170,6 +172,10 @@ public boolean check() {
170172 Preconditions .checkNotNull (userName , "rdb field of userName is required" );
171173 Preconditions .checkNotNull (password , "rdb field of password is required" );
172174
175+ if (null != batchSize ) {
176+ Preconditions .checkArgument (batchSize <= MAX_BATCH_SIZE , "batchSize must be less than " + MAX_BATCH_SIZE );
177+ }
178+
173179 if (StringUtils .equalsIgnoreCase (updateMode , EUpdateMode .UPSERT .name ())) {
174180 Preconditions .checkArgument (null != getPrimaryKeys () && getPrimaryKeys ().size () > 0 , "updateMode mode primary is required" );
175181 }
You can’t perform that action at this time.
0 commit comments