Add support for AppendBlob
See original GitHub issueWhich service(blob, file, queue, table) does this issue concern?
blob
Which version of the Azurite was used?
3.2.0-preview
Where do you get Azurite? (npm, DockerHub, NuGet, Visual Studio Code Extension)
docker: mcr.microsoft.com/azure-storage/azurite:3.2.0-preview
What problem was encountered?
Append Blob is not supported by Azurite
log:
172.17.0.1 - - [05/Nov/2019:09:55:23 +0000] “PUT /devstoreaccount1/mycontainer/appendblob HTTP/1.1” 500 -
info: BlobStorageContextMiddleware: RequestMethod=PUT RequestURL=http://127.0.0.1/devstoreaccount1/mycontainer/appendblob RequestHeaders:{"host":"127.0.0.1:10000","accept":"*/*","date":"Tue, 05 Nov 2019 09:55:23 GMT","if-none-match":"*","x-ms-version":"2019-02-02","x-ms-blob-type":"AppendBlob","authorization":"SharedKey devstoreaccount1:lZfU9I9bfLtHQpmtQOLKx7dstF6PYPxx0HuNV4DQpj8=","x-ms-client-request-id":"7dd82105-6b37-4918-a61b-8020ace87e5a","user-agent":"azsdk-java-azure-storage-blob/12.1.0-preview.1 11.0.4; Mac OS X 10.15","content-length":"0"} ClientIP=172.17.0.1 Protocol=http HTTPVersion=1.1
info: BlobStorageContextMiddleware: Account=devstoreaccount1 Container=mycontainer Blob=appendblob
debug: PublicAccessAuthenticator:validate() Retrieved account name from context: devstoreaccount1, container: mycontainer, blob: appendblob
info: BlobSharedKeyAuthenticator:validate() Signature 1 matched.
info: HandlerMiddleware: DeserializedParameters={"options":{"metadata":{},"requestId":"7dd82105-6b37-4918-a61b-8020ace87e5a","blobHTTPHeaders":{},"leaseAccessConditions":{},"modifiedAccessConditions":{"ifNoneMatch":"*"}},"contentLength":0,"version":"2019-02-02","blobType":"AppendBlob"}
error: ErrorMiddleware: Received a MiddlewareError, fill error information to HTTP response
error: ErrorMiddleware: ErrorName=StorageError ErrorMessage=Current API is not implemented yet. Please vote your wanted features to https://github.com/azure/azurite/issues ErrorHTTPStatusCode=500 ErrorHTTPStatusMessage=undefined ErrorHTTPHeaders={"x-ms-error-code":"APINotImplemented","x-ms-request-id":"a9ca0f8e-682e-49a2-a56f-4845c96c2569"} ErrorHTTPBody="<?xml version=\"1.0\" encoding=\"UTF-8\" standalone=\"yes\"?>\n<Error>\n <Code>APINotImplemented</Code>\n <Message>Current API is not implemented yet. Please vote your wanted features to https://github.com/azure/azurite/issues\nRequestId:a9ca0f8e-682e-49a2-a56f-4845c96c2569\nTime:2019-11-05T09:55:23.448Z</Message>\n</Error>" ErrorStack="StorageError: Current API is not implemented yet. Please vote your wanted features to https://github.com/azure/azurite/issues\n at AppendBlobHandler.create (/opt/azurite/dist/src/blob/handlers/AppendBlobHandler.js:8:15)\n at /opt/azurite/dist/src/blob/generated/middleware/HandlerMiddlewareFactory.js:58:18\n at /opt/azurite/dist/src/blob/generated/ExpressMiddlewareFactory.js:77:63\n at Layer.handle [as handle_request] (/opt/azurite/node_modules/express/lib/router/layer.js:95:5)\n at trim_prefix (/opt/azurite/node_modules/express/lib/router/index.js:317:13)\n at /opt/azurite/node_modules/express/lib/router/index.js:284:7\n at Function.process_params (/opt/azurite/node_modules/express/lib/router/index.js:335:12)\n at next (/opt/azurite/node_modules/express/lib/router/index.js:275:10)\n at process._tickCallback (internal/process/next_tick.js:68:7)"
error: ErrorMiddleware: Set HTTP code: 500
error: ErrorMiddleware: Set HTTP Header: x-ms-error-code=APINotImplemented
error: ErrorMiddleware: Set HTTP Header: x-ms-request-id=a9ca0f8e-682e-49a2-a56f-4845c96c2569
error: ErrorMiddleware: Set content type: application/xml
Steps to reproduce the issue?
docker run -p 10000:10000 mcr.microsoft.com/azure-storage/azurite:3.2.0-preview azurite-blob -l /data --blobHost 0.0.0.0 -d debug.log
public class LocalAzurite {
public static void main(String[] args) throws NoSuchFieldException, IOException {
BlobServiceClientBuilder blobServiceClientBuilder = new BlobServiceClientBuilder()
.connectionString("UseDevelopmentStorage=true;");
BlobServiceClient serviceClient = blobServiceClientBuilder.buildClient();
BlobContainerClient container = serviceClient.getBlobContainerClient("mycontainer");
if (!container.exists()) container.create();
System.out.println(container.exists());
AppendBlobClient append = container.getBlobClient("appendblob").getAppendBlobClient();
append.create();
try (BlobOutputStream blobOutputStream = append.getBlobOutputStream()) {
blobOutputStream.write("hello".getBytes());
}
}
}
pom.xml: (current master branch, built locally)
<dependency>
<groupId>com.azure</groupId>
<artifactId>azure-storage-blob</artifactId>
<version>12.1.0-preview.1</version>
</dependency>
```
### Have you found a mitigation/solution?
no
Issue Analytics
- State:
- Created 4 years ago
- Reactions:4
- Comments:5 (2 by maintainers)
Top Results From Across the Web
Append blob support in Azure Data Lake Storage is now ...
Applications can now create append blobs in addition to block blobs in Azure Data Lake Storage accounts and append to them using Append...
Read more >Create and manage append blobs with PowerShell - 4sysops
To create an append blob using PowerShell, we can either use the Set-AzStorageBlobContent cmdlet or the REST API. Option 1: Upload a local...
Read more >Creating and Managing Append Blob — with Azure Storage ...
Azure Blob Storage is one of the cost effective and easy to use service when it comes to storing and sharing unstructured data...
Read more >Can you please explain the Append Blob in Microsoft Azure ...
Append Blob is specifically optimized for operations where we need to keep adding data to a blob in chunks without modifying the already ......
Read more >MSP360 Explorer for Azure Supports Append Blobs
Microsoft announced an Append Blob. It allows multiple clients to write in the same blob without synchronization. MSP360 Explorer now supports it!
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
Hi @raztiff Append blob is planned in v3.7.0 release.
Thanks for all the efforts! However, Is this planned into your feature development roadmap, I think it is quite a common usecase for using blob storage?