DeepSpace101
DeepSpace101

Reputation: 13722

Monitor upload/download progress via `CloudBlockBlob` class?

If you're transferring a Stream to Azure Blob Storage via the official CloudBlockBlob class, how does one monitor the progress of the upload/download itself? I was expecting some events to that class since it's a network IO class but none seem to exist.

Right now our application sends the entire stream to CloudBlockBlob and it appears like it's done - but we know CloudBlockBlob is still uploading the bytes delivered to it in the stream, so it's really not done...

Am I missing something? Is an entirely different way of doing this (without reinventing the wheel!)

Upvotes: 3

Views: 1649

Answers (1)

kwill
kwill

Reputation: 10998

See the code at http://blogs.msdn.com/b/kwill/archive/2013/03/06/asynchronous-parallel-block-blob-transfers-with-progress-change-notification-2-0.aspx. It uses a ProgressStream wrapper around the file stream in order to raise events whenever data is transferred.

Upvotes: 3

Related Questions