File tree Expand file tree Collapse file tree 2 files changed +15
-10
lines changed
src/com/xxdb/streaming/client Expand file tree Collapse file tree 2 files changed +15
-10
lines changed Original file line number Diff line number Diff line change @@ -321,7 +321,7 @@ public boolean tryReconnect(String topic) {
321
321
// log.info("Successfully switched to node: " + sites[currentSiteIndexMap.get(topic)].host + ":" + sites[currentSiteIndexMap.get(topic)].port);
322
322
323
323
if (!reconnected ) {
324
- waitReconnectTopic .add (topic );
324
+ // waitReconnectTopic.add(topic);
325
325
return false ;
326
326
} else {
327
327
log .info ("Successfully switched to node: " + sites [currentSiteIndexMap .get (topic )].host + ":" + sites [currentSiteIndexMap .get (topic )].port );
Original file line number Diff line number Diff line change @@ -195,15 +195,20 @@ public void run() {
195
195
}
196
196
}
197
197
198
- Set <String > waitReconnectTopic = dispatcher .getAllReconnectTopic ();
199
- synchronized (waitReconnectTopic ) {
200
- for (String topic : waitReconnectTopic ) {
201
- // reconnect every info.resubTimeout ms
202
- if (System .currentTimeMillis () - AbstractClient .lastExceptionTopicTimeMap .get (topic ) <= AbstractClient .resubTimeout )
203
- continue ;
204
- dispatcher .tryReconnect (topic );
205
- }
206
- }
198
+ // not need to put and get from waitReconnectTopic.
199
+ // Set<String> waitReconnectTopic = dispatcher.getAllReconnectTopic();
200
+ // synchronized (waitReconnectTopic) {
201
+ // for (String topic : waitReconnectTopic) {
202
+ // // reconnect every info.resubTimeout ms
203
+ //// if (System.currentTimeMillis() - AbstractClient.lastExceptionTopicTimeMap.get(topic) <= AbstractClient.resubTimeout)
204
+ //// continue;
205
+ // long subTime = System.currentTimeMillis() - AbstractClient.lastExceptionTopicTimeMap.get(topic);
206
+ // System.out.println("flag3 subTime: " + subTime);
207
+ // if (subTime <= AbstractClient.resubTimeout)
208
+ // continue;
209
+ // dispatcher.tryReconnect(topic);
210
+ // }
211
+ // }
207
212
208
213
try {
209
214
// check reconnected interval time
You can’t perform that action at this time.
0 commit comments