Pull request for Ticket "Create a timeout mechanism for transactions"

After some struggling with git, here the new pull request with the suggested changes incorporated