Added timeout in DslActionDTO which is used to represent actions inside a layout and in turn is used for page load action execution.

This commit is contained in:
Trisha Anand 2020-05-07 15:06:16 +05:30
parent 3e2dea8f84
commit 485eb29e03
2 changed files with 6 additions and 0 deletions

View File

@ -6,6 +6,8 @@ import lombok.Setter;
import java.util.Set;
import static com.appsmith.external.constants.ActionConstants.DEFAULT_ACTION_EXECUTION_TIMEOUT_MS;
@Getter
@Setter
public class DslActionDTO {
@ -13,4 +15,5 @@ public class DslActionDTO {
String name;
PluginType pluginType;
Set<String> jsonPathKeys;
Integer timeoutInMillisecond = DEFAULT_ACTION_EXECUTION_TIMEOUT_MS;
}

View File

@ -175,6 +175,9 @@ public class LayoutActionServiceImpl implements LayoutActionService {
newAction.setPluginType(action.getPluginType());
newAction.setJsonPathKeys(action.getJsonPathKeys());
newAction.setName(action.getName());
if (action.getActionConfiguration() != null) {
newAction.setTimeoutInMillisecond(action.getActionConfiguration().getTimeoutInMillisecond());
}
return newAction;
})
.collect(toSet())