MOCKSTACKS
EN
Questions And Answers

More Tutorials









Swift Debugging

Retries


If an application procedure execution fails, Swift will attempt that execution again repeatedly until it succeeds, up until the limit defined in the execution.retries configuration property.

Site selection will occur for retried jobs in the same way that it happens for new jobs. Retried jobs may run on the same site or may run on a different site.

If the retry limit execution.retries is reached for an application procedure, then that application procedure will fail. This will cause the entire run to fail - either immediately (if the lazy.errors property is false) or after all other possible work has been attempted (if the lazy.errors property is true).

With or without lazy errors, each app is re-tried times before it is considered failed for good. An app that has failed but still has retries left will appear as "Failed but can retry".

Without lazy errors, once the first (time-wise) app has run out of retries, the whole run is stopped and the error reported.

With lazy errors, if an app fails after all retries, its outputs are marked as failed. All apps that depend on failed outputs will also fail and their outputs marked as failed. All apps that have non-failed outputs will continue to run normally until everything that can proceed completes.

For example, if you have:

foreach x in [1:1024] {
app(x);
}

If the first started app fails, all the other ones can still continue, and if they don’t otherwise fail, the run will only terminate when all 1023 of them will complete.

So basically the idea behind lazy errors is to run EVERYTHING that can safely be run before stopping.

Some types of errors (such as internal swift errors happening in an app thread) will still stop the run immediately even in lazy errors mode. But we all know there are no such things as internal swift errors :)

Conclusion

In this page (written and validated by ) you learned about Swift Debugging . What's Next? If you are interested in completing Swift tutorial, your next topic will be learning about: Swift Restarts.



Incorrect info or code snippet? We take very seriously the accuracy of the information provided on our website. We also make sure to test all snippets and examples provided for each section. If you find any incorrect information, please send us an email about the issue: mockstacks@gmail.com.


Share On:


Mockstacks was launched to help beginners learn programming languages; the site is optimized with no Ads as, Ads might slow down the performance. We also don't track any personal information; we also don't collect any kind of data unless the user provided us a corrected information. Almost all examples have been tested. Tutorials, references, and examples are constantly reviewed to avoid errors, but we cannot warrant full correctness of all content. By using Mockstacks.com, you agree to have read and accepted our terms of use, cookies and privacy policy.