etcd-io / etcd-io/jetcd

Campaign API throws different exceptions in same scenario

Open
#1,131 10 comments 1 reaction 0 assignees View on GitHub
waiting-for-feedback
Dominant language
Java
Stars
1.2k
Forks
312
Avg merge
5d 4h
Merged PRs (30d)
2

Description

**Versions**
- etcd: 3.5.9
- jetcd: 0.7.3
- java: Corretto-11.0.18.10.1

**Describe the bug**
`campaignResponse = electionClient.campaign(electionName, leaseId, proposal)
.get(writeTimeOut, TimeUnit.SECONDS);`
There is a leader already available for given electionName. We are doing this call as part of our code from another identical instance, sometimes it throws `TimeoutException` and some thing an exception which contains `etcdserver: invalid auth token`. Before upgrading to server 3.5.9 , it was consistently throwing `TimeoutException`. I

**To Reproduce**
In two separate programs, run above line. One after another, some times it will throw timeout and sometimes invalid auth token error

**Expected behavior**
This should be supported from client in a better way to understand if there is a server error or we are just timing out as there is a leader already available.

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.