Skip to content

Commit

Permalink
[dingo-proxy] Support set dingo client retry
Browse files Browse the repository at this point in the history
  • Loading branch information
JYcz committed Dec 27, 2023
1 parent 0f9e50e commit e325bbd
Showing 1 changed file with 8 additions and 2 deletions.
10 changes: 8 additions & 2 deletions dingo-proxy/src/main/java/io/dingodb/proxy/bean/ClientBean.java
Original file line number Diff line number Diff line change
Expand Up @@ -27,8 +27,14 @@
public class ClientBean {

@Bean
public static DingoClient dingoClient(@Value("${server.coordinatorExchangeSvrList}") String coordinator) {
return new DingoClient(coordinator);
public static DingoClient dingoClient(
@Value("${server.coordinatorExchangeSvrList}") String coordinator,
@Value("${server.client.retry:0}") int retry
) {
if (retry <= 0) {
retry = 30;
}
return new DingoClient(coordinator, retry);
}

@Bean
Expand Down

0 comments on commit e325bbd

Please sign in to comment.