1
0
-1

We are making a call to a Dynamic Data service call that could take a very long time to respond - potentially as long as 5 minutes. We would like to control the timeout, so that Maestro will wait longer than usual before displaying an error.

Is there any way to do this?

A similar question has been asked previously, with no answer: Can I configure a session timeout in an anonymous Maestro form?

    CommentAdd your comment...

    2 answers

    1.  
      1
      0
      -1

      Hi Howard,

      If you provide a number as a third parameter to DynamicData.call, it will eventually make its way through to Angular's $http.post call as the config.timeout setting in milliseconds.

      Setting a 10 minute timeout would then be something like:

          DynamicData.call("Service Name", {}, 600000)
          .then(function(response) {
          ...

      The API documentation refers to this third parameter as 'cancelPromise', but Angular itself allows it to be a Promise or a number.  Refer to https://docs.angularjs.org/api/ng/service/$http  (Search for 'arguments' or click the arguments link, then see the Details column of the 'config' param)

      Some browsers will not timeout anyway, but to ensure consistent results across all browsers, this is probably the best way to do it with the existing APIs.

      1. Kevin Atkinson

        From my test results (in Chrome), I believe this approach can be used to decrease the request timeout, but not to increase it (above the current value of the Apache web server timeout).

        The default value of the Apache timeout parameter/directive is 60s.  To support a longer response time, this must be increased.

      CommentAdd your comment...
    2.  
      1
      0
      -1

      For HSBC we implemented a dual call.  The initial DDS call returns immediately and then triggers Status DDS calls.  The Server state is checked and returns a processing status or Complete message.  The Client side has a configure length of time that it checks status for and reports issue if reached.  This also allows for better feedback to client with %complete or processing state info.

        CommentAdd your comment...