This repository was archived by the owner on Oct 21, 2024. It is now read-only.
This repository was archived by the owner on Oct 21, 2024. It is now read-only.
Need to expose blob metadata in GetAsync #1
Closed
Description
Problem
This code hides away the internal CloudBlockBlob metadata.
Such information might be useful for consumers, for example Properties.ContentType
.
This came up because we were trying to assert that .AddAsync
was being called with the correct content type in a test. To assert that, we needed to verify the metadata in .GetAsync
, but it's being hidden away.
Suggestion
Instead of returning T
in GetAsync
, return a class that has T
, but also the other attributes, in case the consumer wants it.
e.g
public class BlobData<T>
{
public T Model { get; set; }
public BlobProperties Properties { get; set; }
}
The consumer might need other metadata in CloudBlockBlob
, but maybe we start with this?