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

hansva pushed a commit to branch main
in repository https://gitbox.apache.org/repos/asf/hop.git


The following commit(s) were added to refs/heads/main by this push:
     new 2105dc6993 [FIX] Add null safety for Retries and Delay (#6492)
2105dc6993 is described below

commit 2105dc69935b56f5678061eb024ee015ab1569fb
Author: Hans Van Akelyen <[email protected]>
AuthorDate: Tue Feb 3 09:49:41 2026 +0100

    [FIX] Add null safety for Retries and Delay (#6492)
---
 .../main/java/org/apache/hop/pipeline/transforms/rest/Rest.java    | 7 +++++--
 1 file changed, 5 insertions(+), 2 deletions(-)

diff --git 
a/plugins/transforms/rest/src/main/java/org/apache/hop/pipeline/transforms/rest/Rest.java
 
b/plugins/transforms/rest/src/main/java/org/apache/hop/pipeline/transforms/rest/Rest.java
index 24dfd0ae05..0f041c5f82 100644
--- 
a/plugins/transforms/rest/src/main/java/org/apache/hop/pipeline/transforms/rest/Rest.java
+++ 
b/plugins/transforms/rest/src/main/java/org/apache/hop/pipeline/transforms/rest/Rest.java
@@ -56,6 +56,7 @@ import org.apache.hop.pipeline.Pipeline;
 import org.apache.hop.pipeline.PipelineMeta;
 import org.apache.hop.pipeline.transform.BaseTransform;
 import org.apache.hop.pipeline.transform.TransformMeta;
+import org.apache.hop.pipeline.transforms.rest.common.RestConst;
 import org.glassfish.jersey.apache.connector.ApacheConnectorProvider;
 import org.glassfish.jersey.client.ClientConfig;
 import org.glassfish.jersey.client.ClientProperties;
@@ -397,8 +398,10 @@ public class Rest extends BaseTransform<RestMeta, 
RestData> {
   }
 
   private Response executeWithRetry(Supplier<Response> requestSupplier) throws 
HopException {
-    int maxRetries = meta.getRetryTimes();
-    long baseDelay = meta.getRetryDelayMs();
+    int maxRetries =
+        meta.getRetryTimes() != null ? meta.getRetryTimes() : 
RestConst.DEFAULT_RETRY_TIMES;
+    long baseDelay =
+        meta.getRetryDelayMs() != null ? meta.getRetryDelayMs() : 
RestConst.DEFAULT_RETRY_DELAY_MS;
     List<String> retryMethods = meta.getRetryMethods();
     Exception lastException = null;
 

Reply via email to