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

Added Change Feed #11692

Merged
Show file tree
Hide file tree
Changes from 1 commit
Commits
Show all changes
36 commits
Select commit Hold shift + click to select a range
34ef0a6
Added Change Feed
seanmcc-msft Apr 30, 2020
821c433
Added Chunk unit tests
seanmcc-msft Apr 30, 2020
e1e48b8
Added Shard tests
seanmcc-msft Apr 30, 2020
a838204
Added some Segment tests
seanmcc-msft May 1, 2020
2e0c2c2
changed service version back to 12-12
seanmcc-msft May 1, 2020
460887c
Added another Segment test
seanmcc-msft May 1, 2020
fb21295
Recorded tests
seanmcc-msft May 1, 2020
f728c6c
Merge branch 'feature/storage/stg73base' into feature/storage/changeFeed
seanmcc-msft May 1, 2020
f60dc32
Fixed build
seanmcc-msft May 1, 2020
6825791
Merge branch 'feature/storage/stg73base' into feature/storage/changeFeed
seanmcc-msft May 2, 2020
c629fed
Added factories to Chunk
seanmcc-msft May 6, 2020
60fc649
Added factories to Shard
seanmcc-msft May 6, 2020
39f5bc2
Most the way through adding Factories to Segment
seanmcc-msft May 6, 2020
52be7ed
Finished adding Factories to Segment
seanmcc-msft May 6, 2020
a1ec00f
Half way through adding Factories to Change Feed
seanmcc-msft May 6, 2020
265c1e8
Finshed adding Factories to Change Feed
seanmcc-msft May 7, 2020
4db0102
Moved Chunk initalization logic to ChunkFactory
seanmcc-msft May 7, 2020
68d772f
Re-recorded tests
seanmcc-msft May 7, 2020
4757ce3
Fixed CI
seanmcc-msft May 7, 2020
34e837e
PR comments
seanmcc-msft May 7, 2020
4e6cc08
Merge branch 'feature/storage/stg73base' into feature/storage/changeFeed
seanmcc-msft May 8, 2020
442c07a
Filled out readme
seanmcc-msft May 8, 2020
d50a2b7
Added samples
seanmcc-msft May 8, 2020
21bedda
PR comments
seanmcc-msft May 11, 2020
743207f
Merge branch 'feature/storage/stg73base' into feature/storage/changeFeed
seanmcc-msft May 12, 2020
e8ef59b
Merge branch 'feature/storage/stg73base' into feature/storage/changeFeed
seanmcc-msft May 26, 2020
85848d7
Merge branch 'feature/storage/stg73base' into feature/storage/changeFeed
seanmcc-msft May 27, 2020
353b928
Updated readme to pass CI
seanmcc-msft May 27, 2020
105c435
Fixed some edge cases and added tests
seanmcc-msft May 27, 2020
20d364d
fixed ending the change feed
seanmcc-msft May 27, 2020
669337b
PR comments
seanmcc-msft May 27, 2020
1a07ef1
PR comments
seanmcc-msft May 27, 2020
c942c1f
Changed default page size
seanmcc-msft May 28, 2020
83dba4d
PR comments
seanmcc-msft May 28, 2020
04431b3
PR comments
seanmcc-msft May 29, 2020
74e6e05
PR comments
seanmcc-msft Jun 1, 2020
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
5 changes: 5 additions & 0 deletions sdk/storage/Azure.Storage.Blobs.ChangeFeed/src/ChangeFeed.cs
Original file line number Diff line number Diff line change
Expand Up @@ -107,6 +107,11 @@ public async Task<Page<BlobChangeFeedEvent>> GetPage(
return BlobChangeFeedEventPage.Empty();
}

if (pageSize > Constants.ChangeFeed.DefaultPageSize)
{
seanmcc-msft marked this conversation as resolved.
Show resolved Hide resolved
pageSize = Constants.ChangeFeed.DefaultPageSize;
ljian3377 marked this conversation as resolved.
Show resolved Hide resolved
}

// Get next page
List<BlobChangeFeedEvent> blobChangeFeedEvents = new List<BlobChangeFeedEvent>();

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -976,14 +976,14 @@ public async Task NoSegmentsRemainingInStartYear()

segments[0].Verify(r => r.GetPage(
IsAsync,
512,
Constants.ChangeFeed.DefaultPageSize,
default));

segments[1].Verify(r => r.HasNext(), Times.Exactly(3));

segments[1].Verify(r => r.GetPage(
IsAsync,
511,
Constants.ChangeFeed.DefaultPageSize - 1,
default));

containerClient.Verify(r => r.Uri, Times.Exactly(1));
Expand Down
2 changes: 1 addition & 1 deletion sdk/storage/Azure.Storage.Common/src/Shared/Constants.cs
Original file line number Diff line number Diff line change
Expand Up @@ -313,7 +313,7 @@ internal static class ChangeFeed
public const string InitalizationSegment = "1601";
public const string MetaSegmentsPath = "meta/segments.json";
public const long ChunkBlockDownloadSize = MB;
public const int DefaultPageSize = 512;
public const int DefaultPageSize = 5000;

internal static class Event
{
Expand Down