Questions asking us to recommend or find a book, tool, software library, tutorial or other off-site resource are off-topic for Stack Overflow as they tend to attract opinionated answers and spam. Instead, describe the problem and what has been done so far to solve it.
Closed 10 years ago.
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
接受
或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
发布评论
评论(2)
使用 Windows Azure Blob 存储,您可以根据需要继续追加到同一个 Blob(并在每次写入后提交块列表),并且在读取时可以请求任何字节范围。但是,您仍然无法获得数据不断向下流动的单个 HTTP 请求的行为。 (您必须请求一个范围,然后对下一个范围发出另一个请求,等等。换句话说,在任何给定时间,blob 的长度都是有限的。)
构建您自己的代码来前端数据(socket-如果我正确理解了需求,基于或可能是分块的 HTTP 响应)可能是您唯一的选择。
With Windows Azure blob storage, you can keep appending to the same blob (and committing the block list after each write) as long as you want, and you can request any byte range when reading. However, you still wouldn't get the behavior of a single HTTP request with data continually streaming down. (You'd have to request a range and then make another request for the next range, etc. In other words, at any given time, the blob has finite length.)
Building your own code to front-end the data (socket-based or maybe a chunked HTTP response) may be your only option, if I'm understanding the requirements correctly.
您需要的是 Windows Azure Page Blob,而不是 Block Blob。有关页面 blob 的信息,请参阅:http://msdn.microsoft.com/ en-us/library/windowsazure/ee691964.aspx。
使用页面 Blob,您将能够附加到现有的 Blob,主要考虑因素是您必须写入整个 512 字节的页面,因此如果附加到现有文件,您可能还必须发送最多 511 字节的现有数据从文件末尾开始。
What you want is a Windows Azure Page Blob, rather than a Block Blob. For info about page blobs see: http://msdn.microsoft.com/en-us/library/windowsazure/ee691964.aspx.
With a Page Blob you will be able to append to an existing blob, the main consideration is that you have to write whole 512 byte pages, so if you appending to an existing file you may have to also send up to 511 bytes of existing data from the end of your file.