The retry feature will restart the build step from the beginning. In our case it means it will try the build again, starting at A. To avoid the full rebuild, use 'build required datasets' instead of using 'force rebuild' . This way it will only rebuild the datasets that were not built.
In spite of the above, the main point of interest here is jobs failing/aborting because of lack of resources. The root reason for why that occurs should be investigated. We would gladly help in the investigation. For that create a support ticket in https://support.dataiku.com