This is an automated email from the ASF dual-hosted git repository.

liubao pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/servicecomb-java-chassis.git


The following commit(s) were added to refs/heads/master by this push:
     new c6bfa7222 [#4516]guard wait at least 30 seconds (#4524)
c6bfa7222 is described below

commit c6bfa72221ec6010887abe1795cb693dd5d07674
Author: liubao68 <[email protected]>
AuthorDate: Sat Sep 14 18:03:35 2024 +0800

    [#4516]guard wait at least 30 seconds (#4524)
---
 .../servicecomb/core/provider/consumer/SyncResponseExecutor.java     | 5 ++---
 1 file changed, 2 insertions(+), 3 deletions(-)

diff --git 
a/core/src/main/java/org/apache/servicecomb/core/provider/consumer/SyncResponseExecutor.java
 
b/core/src/main/java/org/apache/servicecomb/core/provider/consumer/SyncResponseExecutor.java
index b0351ac64..8e86d9d7f 100644
--- 
a/core/src/main/java/org/apache/servicecomb/core/provider/consumer/SyncResponseExecutor.java
+++ 
b/core/src/main/java/org/apache/servicecomb/core/provider/consumer/SyncResponseExecutor.java
@@ -98,8 +98,7 @@ public class SyncResponseExecutor implements Executor {
 
     // 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);
   }
 }

Reply via email to