distribution/xfer: add TODO for return error on Registered()
distribution/xfer: add TODO for return error on Registered()

There's currently four implementations in our code: one in distribution, two in
BuildKit-related code, and one "mock" for testing:

- https://github.com/moby/moby/blob/65b8bcc3216ec64c8f761f35c6caba109b788254/builder/builder-next/worker/worker.go#L452-L455
- https://github.com/moby/moby/blob/65b8bcc3216ec64c8f761f35c6caba109b788254/builder/builder-next/adapters/containerimage/pull.go#L648-L651
- https://github.com/moby/moby/blob/65b8bcc3216ec64c8f761f35c6caba109b788254/distribution/pull_v2.go#L318-L321
- https://github.com/moby/moby/blob/65b8bcc3216ec64c8f761f35c6caba109b788254/distribution/xfer/download_test.go#L186-L188

All of these call a metadata-service to register the DiffID, and all of those
may return an error, which currently gets ignored.

We should consider changing the signature to return possible errors, so that
the callsite can decide how to handle them (which could be just "log" the error
or handle them in other ways).

Signed-off-by: Sebastiaan van Stijn <64b2b6d12bfe4baae7dad3d018f8cbf6b0e7a044@gone.nl>

Ramzec/docker,moby/moby,jimjag/docker,Ramzec/docker,bearstech/moby,flavio/docker,flavio/docker,moul/docker,vdemeester/docker,moul/docker,mahak/docker,flavio/docker,jimjag/docker,cpuguy83/docker,Mokolea/docker,Ramzec/docker,thaJeztah/docker,cpuguy83/docker,nalind/docker,Mokolea/docker,vdemeester/docker,Mokolea/docker,nalind/docker,thaJeztah/docker,vdemeester/docker,Ramzec/docker,trebonian/docker,nalind/docker,jimjag/docker,cpuguy83/docker,gnailuy/docker,konstruktoid/docker-upstream,moby/moby,moby/moby,cpuguy83/docker,nawawi/docker,moby/moby,trebonian/docker,konstruktoid/docker-upstream,bearstech/moby,konstruktoid/docker-upstream,moul/docker,mahak/docker,bearstech/moby,gnailuy/docker,trebonian/docker,gnailuy/docker,jimjag/docker,nalind/docker,mahak/docker,thaJeztah/docker,nawawi/docker,mahak/docker,bearstech/moby,Mokolea/docker,gnailuy/docker,nawawi/docker,konstruktoid/docker-upstream,flavio/docker,trebonian/docker,thaJeztah/docker,moul/docker,nawawi/docker