Skip to content

Commit 9e4c930

Browse files
final edits
1 parent 81b17e3 commit 9e4c930

11 files changed

+31
-21
lines changed

articles/storage/blobs/storage-blob-container-create-go.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@ author: pauljewellmsft
77

88
ms.service: azure-blob-storage
99
ms.topic: how-to
10-
ms.date: 05/01/2024
10+
ms.date: 05/22/2024
1111
ms.author: pauljewell
1212
ms.devlang: golang
1313
ms.custom: devx-track-go, devguide-go
@@ -45,7 +45,7 @@ The following example shows how to create a container:
4545

4646
## Create the root container
4747

48-
A root container serves as a default container for your storage account. Each storage account may have one root container, which must be named *$root*. The root container must be explicitly created or deleted.
48+
A root container serves as a default container for your storage account. Each storage account can have one root container, which must be named *$root*. The root container must be explicitly created or deleted.
4949

5050
You can reference a blob stored in the root container without including the root container name. The root container enables you to reference a blob at the top level of the storage account hierarchy. For example, you can reference a blob in the root container as follows:
5151

articles/storage/blobs/storage-blob-container-delete-go.md

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@ author: pauljewellmsft
77

88
ms.service: azure-blob-storage
99
ms.topic: how-to
10-
ms.date: 05/01/2024
10+
ms.date: 05/22/2024
1111
ms.author: pauljewell
1212
ms.devlang: golang
1313
ms.custom: devx-track-go, devguide-go
@@ -35,15 +35,15 @@ To delete a container, call the following method:
3535

3636
- [DeleteContainer](https://pkg.go.dev/github.com/Azure/azure-sdk-for-go/sdk/storage/azblob#Client.DeleteContainer)
3737

38-
After you delete a container, you can't create a container with the same name for *at least* 30 seconds. Attempting to create a container with the same name will fail with HTTP error code `409 (Conflict)`. Any other operations on the container or the blobs it contains will fail with HTTP error code `404 (Not Found)`.
38+
After you delete a container, you can't create a container with the same name for *at least* 30 seconds. Attempting to create a container with the same name fails with HTTP error code `409 (Conflict)`. Any other operations on the container or the blobs it contains fail with HTTP error code `404 (Not Found)`.
3939

4040
The following example shows how to delete a specified container:
4141

4242
:::code language="go" source="~/blob-devguide-go/cmd/delete-container/delete_container.go" id="snippet_delete_container":::
4343

4444
## Restore a deleted container
4545

46-
When container soft delete is enabled for a storage account, a deleted container and its contents may be recovered within a specified retention period. To learn more about container soft delete, see [Enable and manage soft delete for containers](soft-delete-container-enable.md). You can restore a soft-deleted container by calling the following method from the embedded [ServiceClient](https://pkg.go.dev/github.com/Azure/azure-sdk-for-go/sdk/storage/azblob#Client.ServiceClient) for the client object:
46+
When container soft delete is enabled for a storage account, a deleted container and its contents can be recovered within a specified retention period. To learn more about container soft delete, see [Enable and manage soft delete for containers](soft-delete-container-enable.md). You can restore a soft-deleted container by calling the following method from the embedded [ServiceClient](https://pkg.go.dev/github.com/Azure/azure-sdk-for-go/sdk/storage/azblob#Client.ServiceClient) for the client object:
4747

4848
- [RestoreContainer](https://pkg.go.dev/github.com/Azure/azure-sdk-for-go/sdk/storage/azblob/service#Client.RestoreContainer)
4949

articles/storage/blobs/storage-blob-container-properties-metadata-go.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@ author: pauljewellmsft
77

88
ms.service: azure-blob-storage
99
ms.topic: how-to
10-
ms.date: 05/01/2024
10+
ms.date: 05/22/2024
1111
ms.author: pauljewell
1212
ms.devlang: golang
1313
ms.custom: devx-track-go, devguide-go

articles/storage/blobs/storage-blob-containers-list-go.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@ author: pauljewellmsft
77

88
ms.service: azure-blob-storage
99
ms.topic: how-to
10-
ms.date: 05/01/2024
10+
ms.date: 05/22/2024
1111
ms.author: pauljewell
1212
ms.devlang: golang
1313
ms.custom: devx-track-go, devguide-go
@@ -43,7 +43,7 @@ You can specify options for listing containers by using the [ListContainersOptio
4343

4444
### Manage how many results are returned
4545

46-
By default, a listing operation returns up to 5000 results at a time. To return a smaller set of results, provide a nonzero value for the `MaxResults` field in the [ListContainersOptions](https://pkg.go.dev/github.com/Azure/azure-sdk-for-go/sdk/storage/azblob#ListContainersOptions) struct.
46+
By default, a listing operation returns up to 5,000 results at a time. To return a smaller set of results, provide a nonzero value for the `MaxResults` field in the [ListContainersOptions](https://pkg.go.dev/github.com/Azure/azure-sdk-for-go/sdk/storage/azblob#ListContainersOptions) struct.
4747

4848
### Filter results with a prefix
4949

articles/storage/blobs/storage-blob-delete-go.md

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,12 +1,12 @@
11
---
22
title: Delete and restore a blob with Go
33
titleSuffix: Azure Storage
4-
description: Learn how to delete and restore a blob in your Azure Storage account using the Go client library
4+
description: Learn how to delete and restore a blob in your Azure Storage account using the Go client library.
55
services: storage
66
author: pauljewellmsft
77

88
ms.author: pauljewell
9-
ms.date: 05/01/2024
9+
ms.date: 05/22/2024
1010
ms.service: azure-blob-storage
1111
ms.topic: how-to
1212
ms.devlang: golang
@@ -47,7 +47,7 @@ To delete *only* the snapshots and not the blob itself, you can pass the value `
4747

4848
## Restore a deleted blob
4949

50-
Blob soft delete protects an individual blob and its versions, snapshots, and metadata from accidental deletes or overwrites by maintaining the deleted data in the system for a specified period of time. During the retention period, you can restore the blob to its state at deletion. After the retention period has expired, the blob is permanently deleted. For more information about blob soft delete, see [Soft delete for blobs](soft-delete-blob-overview.md).
50+
Blob soft delete protects an individual blob and its versions, snapshots, and metadata from accidental deletes or overwrites by maintaining the deleted data in the system for a specified period of time. During the retention period, you can restore the blob to its state at deletion. After the retention period expires, the blob is permanently deleted. For more information about blob soft delete, see [Soft delete for blobs](soft-delete-blob-overview.md).
5151

5252
You can use the Azure Storage client libraries to restore a soft-deleted blob or snapshot.
5353

articles/storage/blobs/storage-blob-download-go.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@ services: storage
66
author: pauljewellmsft
77

88
ms.author: pauljewell
9-
ms.date: 05/01/2024
9+
ms.date: 05/22/2024
1010
ms.service: azure-blob-storage
1111
ms.topic: how-to
1212
ms.devlang: golang
@@ -31,7 +31,7 @@ The authorization mechanism must have the necessary permissions to perform a dow
3131

3232
## Download a blob
3333

34-
You can use any of the following method to download a blob:
34+
You can use any of the following methods to download a blob:
3535

3636
- [DownloadBuffer](https://pkg.go.dev/github.com/Azure/azure-sdk-for-go/sdk/storage/azblob#Client.DownloadBuffer)
3737
- [DownloadFile](https://pkg.go.dev/github.com/Azure/azure-sdk-for-go/sdk/storage/azblob#Client.DownloadFile)

articles/storage/blobs/storage-blob-go-get-started.md

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@ ms.author: pauljewell
88

99
ms.service: azure-blob-storage
1010
ms.topic: how-to
11-
ms.date: 05/01/2024
11+
ms.date: 05/22/2024
1212
ms.devlang: golang
1313
ms.custom: devx-track-go, devguide-go
1414
---
@@ -116,13 +116,13 @@ The following guides show you how to work with data resources and perform specif
116116
| Guide | Description |
117117
|--|---|
118118
| [Create a container](storage-blob-container-create-go.md) | Create containers. |
119-
| [Delete and restore containers](storage-blob-container-delete-go.md) | Delete containers, and if soft-delete is enabled, restore deleted containers. |
119+
| [Delete and restore containers](storage-blob-container-delete-go.md) | Delete containers, and if soft-delete is enabled, restore deleted containers. |
120120
| [List containers](storage-blob-containers-list-go.md) | List containers in an account and the various options available to customize a listing. |
121121
| [Manage properties and metadata (containers)](storage-blob-container-properties-metadata-go.md) | Manage container properties and metadata. |
122122
| [Upload blobs](storage-blob-upload-go.md) | Learn how to upload blobs by using strings, streams, file paths, and other methods. |
123123
| [Download blobs](storage-blob-download-go.md) | Download blobs by using strings, streams, and file paths. |
124124
| [List blobs](storage-blobs-list-go.md) | List blobs in different ways. |
125-
| [Delete and restore blobs](storage-blob-delete-go.md) | Delete blobs, and if soft-delete is enabled, restore deleted blobs. |
125+
| [Delete and restore blobs](storage-blob-delete-go.md) | Delete blobs, and if soft-delete is enabled, restore deleted blobs. |
126126
| [Manage properties and metadata (blobs)](storage-blob-properties-metadata-go.md) | Manage container properties and metadata. |
127127

128128
[!INCLUDE [storage-dev-guide-code-samples-note-go](../../../includes/storage-dev-guides/storage-dev-guide-code-samples-note-go.md)]

articles/storage/blobs/storage-blob-properties-metadata-go.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@ services: storage
66
author: pauljewellmsft
77

88
ms.author: pauljewell
9-
ms.date: 05/01/2024
9+
ms.date: 05/22/2024
1010
ms.service: azure-blob-storage
1111
ms.topic: how-to
1212
ms.devlang: golang

articles/storage/blobs/storage-blob-upload-go.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@ services: storage
66
author: pauljewellmsft
77

88
ms.author: pauljewell
9-
ms.date: 05/01/2024
9+
ms.date: 05/22/2024
1010
ms.service: azure-blob-storage
1111
ms.topic: how-to
1212
ms.devlang: golang
@@ -37,7 +37,7 @@ To upload a blob, call any of the following methods from the client object:
3737
- [UploadFile](https://pkg.go.dev/github.com/Azure/azure-sdk-for-go/sdk/storage/azblob#Client.UploadFile)
3838
- [UploadStream](https://pkg.go.dev/github.com/Azure/azure-sdk-for-go/sdk/storage/azblob#Client.UploadStream)
3939

40-
To perform the upload, the client library may use either [Put Blob](/rest/api/storageservices/put-blob) or a series of [Put Block](/rest/api/storageservices/put-block) calls followed by [Put Block List](/rest/api/storageservices/put-block-list). This behavior depends on the overall size of the object and how the data transfer options are set.
40+
To perform the upload, the client library might use either [Put Blob](/rest/api/storageservices/put-blob) or a series of [Put Block](/rest/api/storageservices/put-block) calls followed by [Put Block List](/rest/api/storageservices/put-block-list). This behavior depends on the overall size of the object and how the data transfer options are set.
4141

4242
## Upload a block blob from a local file path
4343

articles/storage/blobs/storage-quickstart-blobs-go.md

Lines changed: 11 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@ titleSuffix: Azure Storage
44
description: In this quickstart, you learn how to use the Azure Blob Storage client module for Go to create a container and a blob in Blob (object) storage. Next, you learn how to download the blob to your local computer, and how to list all of the blobs in a container.
55
author: pauljewellmsft
66
ms.author: pauljewell
7-
ms.date: 08/29/2023
7+
ms.date: 05/22/2024
88
ms.service: azure-blob-storage
99
ms.topic: quickstart
1010
ms.devlang: golang
@@ -175,6 +175,8 @@ _, err = client.CreateContainer(ctx, containerName, nil)
175175
handleError(err)
176176
```
177177

178+
To learn more about creating a container, and to explore more code samples, see [Create a blob container with Go](storage-blob-container-create-go.md).
179+
178180
### Upload blobs to the container
179181

180182
The code sample creates a byte array with some data, and uploads the data as a buffer to a new blob resource in the specified container.
@@ -191,6 +193,8 @@ _, err = client.UploadBuffer(ctx, containerName, blobName, data, &azblob.UploadB
191193
handleError(err)
192194
```
193195

196+
To learn more about uploading blobs, and to explore more code samples, see [Upload a blob with Go](storage-blob-upload-go.md).
197+
194198
### List the blobs in a container
195199

196200
The code sample lists the blobs in the specified container. This example uses [NewListBlobsFlatPager](https://pkg.go.dev/github.com/Azure/azure-sdk-for-go/sdk/storage/azblob#Client.NewListBlobsFlatPager), which returns a pager for blobs starting from the specified Marker. Here, we use an empty Marker to start enumeration from the beginning, and continue paging until there are no more results. This method returns blob names in lexicographic order.
@@ -215,6 +219,8 @@ for pager.More() {
215219
}
216220
```
217221

222+
To learn more about listing blobs, and to explore more code examples, see [List blobs with Go](storage-blob-list-go.md).
223+
218224
### Download the blob
219225

220226
The code sample downloads a blob using the [DownloadStream](https://pkg.go.dev/github.com/Azure/azure-sdk-for-go/sdk/storage/azblob#Client.DownloadStream) method, and creates a retry reader for reading data. If a connection fails while reading, the retry reader makes other requests to re-establish a connection and continue reading. You can specify retry reader options using the [RetryReaderOptions](https://pkg.go.dev/github.com/Azure/azure-sdk-for-go/sdk/storage/azblob/blob#RetryReaderOptions) struct.
@@ -239,6 +245,8 @@ fmt.Println("Blob contents:")
239245
fmt.Println(downloadedData.String())
240246
```
241247

248+
To learn more about downloading blobs, and to explore more code examples, see [Download a blob with Go](storage-blob-download-go.md).
249+
242250
### Clean up resources
243251

244252
If you no longer need the blobs uploaded in this quickstart, you can delete the individual blob using the [DeleteBlob](https://pkg.go.dev/github.com/Azure/azure-sdk-for-go/sdk/storage/azblob#Client.DeleteBlob) method, or the entire container and its contents using the [DeleteContainer](https://pkg.go.dev/github.com/Azure/azure-sdk-for-go/sdk/storage/azblob#Client.DeleteContainer) method.
@@ -256,6 +264,8 @@ _, err = client.DeleteContainer(ctx, containerName, nil)
256264
handleError(err)
257265
```
258266

267+
To learn more about deleting blobs and containers, and to explore more code examples, see [Delete a blob with Go](storage-blob-delete-go.md) and [Delete a container with Go](storage-blob-container-delete-go.md).
268+
259269
## Next steps
260270

261271
In this quickstart, you learned how to upload, download, and list blobs using Go.

0 commit comments

Comments
 (0)