|
|
|
@ -202,8 +202,7 @@ public class KhVoteEmpServiceImpl implements IKhVoteEmpService {
|
|
|
|
// if (retryCount < MAX_RETRY_COUNT) {
|
|
|
|
// if (retryCount < MAX_RETRY_COUNT) {
|
|
|
|
// 等待一段时间后重试,避免立即重试导致的持续冲突
|
|
|
|
// 等待一段时间后重试,避免立即重试导致的持续冲突
|
|
|
|
try {
|
|
|
|
try {
|
|
|
|
Thread.sleep(100); // 重试间隔递增
|
|
|
|
Thread.sleep(100* retryCount); // 重试间隔递增
|
|
|
|
//Thread.sleep(200 * retryCount); // 重试间隔递增
|
|
|
|
|
|
|
|
} catch (InterruptedException e) {
|
|
|
|
} catch (InterruptedException e) {
|
|
|
|
Thread.currentThread().interrupt();
|
|
|
|
Thread.currentThread().interrupt();
|
|
|
|
throw new RuntimeException("重试过程被中断-------------", e);
|
|
|
|
throw new RuntimeException("重试过程被中断-------------", e);
|
|
|
|
@ -236,8 +235,7 @@ public class KhVoteEmpServiceImpl implements IKhVoteEmpService {
|
|
|
|
// if (retryCount < MAX_RETRY_COUNT) {
|
|
|
|
// if (retryCount < MAX_RETRY_COUNT) {
|
|
|
|
// 等待一段时间后重试,避免立即重试导致的持续冲突
|
|
|
|
// 等待一段时间后重试,避免立即重试导致的持续冲突
|
|
|
|
try {
|
|
|
|
try {
|
|
|
|
Thread.sleep(100); // 重试间隔递增
|
|
|
|
Thread.sleep(100* retryCount); // 重试间隔递增
|
|
|
|
//Thread.sleep(200 * retryCount); // 重试间隔递增
|
|
|
|
|
|
|
|
} catch (InterruptedException e) {
|
|
|
|
} catch (InterruptedException e) {
|
|
|
|
Thread.currentThread().interrupt();
|
|
|
|
Thread.currentThread().interrupt();
|
|
|
|
throw new RuntimeException("重试过程被中断-------------", e);
|
|
|
|
throw new RuntimeException("重试过程被中断-------------", e);
|
|
|
|
@ -269,8 +267,7 @@ public class KhVoteEmpServiceImpl implements IKhVoteEmpService {
|
|
|
|
// if (retryCount < MAX_RETRY_COUNT) {
|
|
|
|
// if (retryCount < MAX_RETRY_COUNT) {
|
|
|
|
// 等待一段时间后重试,避免立即重试导致的持续冲突
|
|
|
|
// 等待一段时间后重试,避免立即重试导致的持续冲突
|
|
|
|
try {
|
|
|
|
try {
|
|
|
|
Thread.sleep(100); // 重试间隔递增
|
|
|
|
Thread.sleep(100* retryCount); // 重试间隔递增
|
|
|
|
//Thread.sleep(200 * retryCount); // 重试间隔递增
|
|
|
|
|
|
|
|
} catch (InterruptedException e) {
|
|
|
|
} catch (InterruptedException e) {
|
|
|
|
Thread.currentThread().interrupt();
|
|
|
|
Thread.currentThread().interrupt();
|
|
|
|
throw new RuntimeException("重试过程被中断-------------", e);
|
|
|
|
throw new RuntimeException("重试过程被中断-------------", e);
|
|
|
|
|