File tree Expand file tree Collapse file tree 1 file changed +10
-8
lines changed
src/main/java/com/alipay/oceanbase/rpc Expand file tree Collapse file tree 1 file changed +10
-8
lines changed Original file line number Diff line number Diff line change @@ -904,19 +904,21 @@ public void eraseTableEntry(String tableName) {
904904 public void setRpcExecuteTimeout (int rpcExecuteTimeout ) {
905905 this .properties .put (RPC_EXECUTE_TIMEOUT .getKey (), String .valueOf (rpcExecuteTimeout ));
906906 this .rpcExecuteTimeout = rpcExecuteTimeout ;
907- if (tableRoute != null ) {
908- ConcurrentHashMap <ObServerAddr , ObTable > tableRoster = tableRoute .getTableRoster ().getTables ();
907+ if (odpMode ) {
908+ ObTable odpTable = tableRoute .getOdpTable ();
909+ if (null != odpTable ) {
910+ odpTable .setObTableExecuteTimeout (rpcExecuteTimeout );
911+ }
912+ } else {
913+ TableRoster tableRoster = tableRoute .getTableRoster ();
909914 if (null != tableRoster ) {
910- for (ObTable obTable : tableRoster .values ()) {
911- if (obTable != null ) {
915+ ConcurrentHashMap <ObServerAddr , ObTable > addTableMap = tableRoster .getTables ();
916+ for (ObTable obTable : addTableMap .values ()) {
917+ if (null != obTable ) {
912918 obTable .setObTableExecuteTimeout (rpcExecuteTimeout );
913919 }
914920 }
915921 }
916- ObTable odpTable = tableRoute .getOdpTable ();
917- if (null != odpTable ) {
918- odpTable .setObTableExecuteTimeout (rpcExecuteTimeout );
919- }
920922 }
921923 }
922924
You can’t perform that action at this time.
0 commit comments