Merge pull request #1832 from apache/tristan/fix-downloadablefile-race

Fix downloadablefile race condition