[JAVA-2285] Unable to reconnect to a replica set after a failover due to stale electionId Created: 22/Aug/16 Updated: 13/Sep/16 Resolved: 13/Sep/16 |
|
| Status: | Closed |
| Project: | Java Driver |
| Component/s: | None |
| Affects Version/s: | 3.2.0 |
| Fix Version/s: | None |
| Type: | Bug | Priority: | Major - P3 |
| Reporter: | Dude Dou | Assignee: | Jeffrey Yemin |
| Resolution: | Done | Votes: | 0 |
| Labels: | None | ||
| Remaining Estimate: | Not Specified | ||
| Time Spent: | Not Specified | ||
| Original Estimate: | Not Specified | ||
| Environment: |
mongodb 3.0.2 replica set, three nodes , java driver: 3.2.0, centos 7.0 |
||
| Attachments: |
|
| Description |
|
the java driver will try to connect to the replicate set infinitely when the replica set restart after the driver client starting.
|
| Comments |
| Comment by Jeffrey Yemin [ 13/Sep/16 ] |
|
As we haven't heard back from you in quite some time, I'm closing this issue but will re-open if you come back with further information. |
| Comment by Jeffrey Yemin [ 23/Aug/16 ] |
|
Hi Dude, Thanks for the reproduction steps. So far I have not been able to reproduce the same behavior as you have, but I can see from the logs you provided what looks like a real problem. In order to help get to the root cause, can you re-execute the reproduction scenario and attach new client logs as well as server logs for all three replica set members for the time period of the test? Regards, |
| Comment by Dude Dou [ 23/Aug/16 ] |
|
We have reproduced this scenario by the following steps: the logs is in attach |
| Comment by Jeffrey Yemin [ 22/Aug/16 ] |
|
Hi Dude, Thanks for the report. From the client logs you provided, this looks to be related to a feature in the driver for detecting stale primaries. In your case, the driver sees the 10.1.245.5:37017 as a stale primary because its reported electionId is less than an electionId detected earlier. In order to determine if there is an actual bug in either the driver or the server, please:
Thanks, |