retry to retrieve metadata on failure during pull

This makes Docker retry to retrieve the JSON metadata for the layers.
Docker will make 5 attempts to retrieve the metadata before failing and
it will increase the delay between attempts after each failed attempt.

Docker-DCO-1.1-Signed-off-by: Cristian Staretu <cristian.staretu@gmail.com> (github: unclejack)
Merge pull request #4387 from unclejack/multiple_metadata_retrieval_attempts

retry to retrieve layer metadata on failure during pull