Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Using Azure.Storage.Blobs for storage access #10018

Merged
merged 64 commits into from
Jun 27, 2024
Merged
Changes from 1 commit
Commits
Show all changes
64 commits
Select commit Hold shift + click to select a range
018faec
WIP
agr May 21, 2024
56ec658
Unused args.
agr May 21, 2024
5dda8bf
Removing BlobRequestOptions
agr May 22, 2024
cf3c800
Less usings.
agr May 22, 2024
812662d
BlobContinuationTokens.
agr May 22, 2024
cb98c41
BLob list details wrapper.
agr May 22, 2024
ed59f66
BlobProperties
agr May 23, 2024
99b4180
CopyState
agr May 23, 2024
6d65715
AccessCondition
agr May 23, 2024
f81cc7f
SAS permissions enum
agr May 23, 2024
435d521
Method rename
agr May 23, 2024
217c7e6
ContentEncoding property
agr May 24, 2024
5526e3d
Overwrite fix.
agr May 24, 2024
379d154
Exceptions!
agr May 25, 2024
d08d4e6
Pulling back nuget.jobs changes.
agr May 28, 2024
cdf1063
WrapStorageExceptionAsync
agr May 29, 2024
bfd2449
Missed `?`
agr May 29, 2024
b919573
Catching more cases of blob/container not found.
agr May 29, 2024
c747941
Aligning exception checks with old code.
agr May 29, 2024
5b72650
NuGet.Jobs version update
agr May 29, 2024
97937be
WIP
agr May 31, 2024
20b1ca6
WIP
agr Jun 1, 2024
32428bc
WIP
agr Jun 5, 2024
617b1b4
WIP
agr Jun 5, 2024
e0f4793
WIP
agr Jun 5, 2024
1f68b56
WIP
agr Jun 6, 2024
471e8fe
WIP
agr Jun 6, 2024
e26c9bc
Compiles
agr Jun 6, 2024
f901d4a
Test "fixes"
agr Jun 6, 2024
8fdc168
Connection string fixes.
agr Jun 6, 2024
a35e574
More binding redirects.
agr Jun 6, 2024
76c954e
FetchAttributes after blob upload because calling code expects to be …
agr Jun 7, 2024
290ecc7
Using DownloadContent for DownloadText.
agr Jun 7, 2024
bba277f
Request timeout in CloudBlobClientWrapper constructor.
agr Jun 10, 2024
fc24eb3
FetchAttributes in OpenRead call as there is expectations that proper…
agr Jun 11, 2024
c6eab65
Better(?) way to get properties/metadata for OpenReadAsync.
agr Jun 11, 2024
fe65c21
The expectations are that we should always be able to set HTTP headers.
agr Jun 12, 2024
946c6de
More FetchAttributes
agr Jun 14, 2024
ce5112c
Test fix
agr Jun 14, 2024
d173bda
named parameter
agr Jun 14, 2024
b452051
Dropping Continuation token interface.
agr Jun 14, 2024
a0f87db
Preserving SAS URL for copying.
agr Jun 14, 2024
f88895d
Continuation token.
agr Jun 14, 2024
b3a543f
CloudBlobWrapper.Uri would not contain query
agr Jun 18, 2024
1af9756
PR feedback.
agr Jun 19, 2024
ae380dc
More PR feedback.
agr Jun 19, 2024
c6d0cfa
Less warnings.
agr Jun 20, 2024
e96561e
fix Priviledged typo
SimonCropp Jun 5, 2024
7c88c7e
Bringing back updated NuGet.Jobs packges.
agr Jun 21, 2024
e0174a0
Merge remote-tracking branch 'origin/dev' into agr-st-sdk
agr Jun 25, 2024
51e101b
Cosntructor argument type fix
agr Jun 25, 2024
8c6d504
Tests
agr Jun 25, 2024
a857b1d
Dropped blob client wrapper facts.
agr Jun 25, 2024
d9a1d9b
Not using HasFlag
agr Jun 25, 2024
eb0f21b
Comment update.
agr Jun 25, 2024
308965f
Content Hash header uses base64
agr Jun 26, 2024
942951c
ContentType for OpenWriteAsync
agr Jun 26, 2024
cfd15f8
Extracting HTTP headers for DownloadToStreamAsync call.
agr Jun 26, 2024
9e7828b
Apparently, we can't just call `ETag.ToString()`.
agr Jun 26, 2024
95c793c
OpenReadAsync throws on "Not modified".
agr Jun 26, 2024
4c9ba5d
CloudBlobCoreFileStorageServiceIntegrationTests updates.
agr Jun 26, 2024
584ffe6
Test cleanup
agr Jun 26, 2024
6e15c61
Proper exception
agr Jun 26, 2024
b15857c
Removing test for which I can't find relevant use case in our codebase.
agr Jun 26, 2024
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Removing test for which I can't find relevant use case in our codebase.
  • Loading branch information
agr committed Jun 26, 2024
commit b15857cd96a74755efdbea9ec568a998c7dbf4de
Original file line number Diff line number Diff line change
@@ -263,42 +263,6 @@ await _targetA.SaveFileAsync(
});
}

[BlobStorageFact]
public async Task OpenWriteAsyncRejectsETagMismatchFoundAfterUploadStarts()
{
// Arrange
var folderName = CoreConstants.Folders.ValidationFolderName;
var fileName = _prefixA;
var expectedContent = "Hello, world.";

var container = _clientA.GetContainerReference(folderName);
var file = container.GetBlobReference(fileName);
var writeCount = 0;

// Act & Assert
var ex = await Assert.ThrowsAsync<CloudBlobStorageException>(
async () =>
{
using (var stream = await file.OpenWriteAsync(AccessConditionWrapper.GenerateIfNotExistsCondition()))
{
stream.Write(new byte[1], 0, 1);
await stream.FlushAsync();
writeCount++;

await _targetA.SaveFileAsync(
folderName,
fileName,
new MemoryStream(Encoding.ASCII.GetBytes(expectedContent)),
overwrite: false);

stream.Write(new byte[1], 0, 1);
await stream.FlushAsync();
writeCount++;
}
});
Assert.Equal(2, writeCount);
}

[BlobStorageFact]
public async Task OpenReadAsyncReturnsReadableStreamWhenBlobExistsAndPopulatesProperties()
{