@@ -73,6 +73,8 @@ public static class OracleSourceConfig extends AbstractDBSpecificSourceConfig {
73
73
74
74
public static final String NAME_USE_CONNECTION = "useConnection" ;
75
75
public static final String NAME_CONNECTION = "connection" ;
76
+ public static final String DEFAULT_ROW_PREFETCH_VALUE = "40" ;
77
+ public static final String DEFAULT_BATCH_SIZE = "10" ;
76
78
77
79
@ Name (NAME_USE_CONNECTION )
78
80
@ Nullable
@@ -88,12 +90,12 @@ public static class OracleSourceConfig extends AbstractDBSpecificSourceConfig {
88
90
@ Name (OracleConstants .DEFAULT_BATCH_VALUE )
89
91
@ Description ("The default batch value that triggers an execution request." )
90
92
@ Nullable
91
- public Integer defaultBatchValue ;
93
+ private Integer defaultBatchValue ;
92
94
93
95
@ Name (OracleConstants .DEFAULT_ROW_PREFETCH )
94
96
@ Description ("The default number of rows to prefetch from the server." )
95
97
@ Nullable
96
- public Integer defaultRowPrefetch ;
98
+ private Integer defaultRowPrefetch ;
97
99
98
100
@ Override
99
101
public String getConnectionString () {
@@ -111,9 +113,12 @@ public String getConnectionString() {
111
113
@ Override
112
114
protected Map <String , String > getDBSpecificArguments () {
113
115
ImmutableMap .Builder <String , String > builder = ImmutableMap .builder ();
114
-
115
- builder .put (OracleConstants .DEFAULT_BATCH_VALUE , String .valueOf (defaultBatchValue ));
116
- builder .put (OracleConstants .DEFAULT_ROW_PREFETCH , String .valueOf (defaultRowPrefetch ));
116
+ if (defaultBatchValue != null ) {
117
+ builder .put (OracleConstants .DEFAULT_BATCH_VALUE , String .valueOf (defaultBatchValue ));
118
+ }
119
+ if (defaultRowPrefetch != null ) {
120
+ builder .put (OracleConstants .DEFAULT_ROW_PREFETCH , String .valueOf (defaultRowPrefetch ));
121
+ }
117
122
118
123
return builder .build ();
119
124
}
0 commit comments