Skip to content

Commit

Permalink
[#4516]guard wait at least 30 seconds (#4524)
Browse files Browse the repository at this point in the history
  • Loading branch information
liubao68 authored Sep 14, 2024
1 parent 69863e5 commit c6bfa72
Showing 1 changed file with 2 additions and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -98,8 +98,7 @@ private long getWaitTime(Invocation invocation) {

// In invocation handlers, may call other microservices, invocation
// timeout may be much longer than request timeout.
// But this is quite rare, for simplicity, default two times of request timeout.
// If users need longer timeout, can configure invocation timeout.
return invocation.getOperationMeta().getConfig().getMsRequestTimeout() * 2;
// For simplicity, default 30000 or two times of request timeout.
return Math.max(invocation.getOperationMeta().getConfig().getMsRequestTimeout() * 2, 30000);
}
}

0 comments on commit c6bfa72

Please sign in to comment.