Find out how to get a reference to each of the Blobs in the Azure container.
- [Instructor] All right, once again we're going to take off the breakpoint, back out, and back out again. And the last one that we have here is ListContainersWithPrefixAsync, and that one's exactly like we just saw. So what we're going to do now is to step into the call container samples. So let's scroll down to call container samples.
Many of these do not have any output, but the first one that we do want to see the output from, is PrintContainerPropertiesAndMetadata. Let's take a look at that definition. And here you can see that we're going to printout many of the properties of the container. So let's put a breakpoint after we iterate through the metadata for each of these.
We'll put a breakpoint on the right line, and we'll run to here and we'll be able to see this display. So let's start. And we hit our breakpoint. So let's go back. And here we have the container properties. And at the top we have the name, as we saw before, the URI, which is the unique URI for this container. ETag, last modified, and then we iterate through the leasing properties, and you can see that the state is available, the duration is unspecified and so forth.
The container metadata is empty. And that's not surprising, because we have not added any metadata. So we can stop the run, take off our breakpoint, back up, and as our final run in our blob samples, we're going to call GetExistingBlobReferenceAsync.
Let's step into that definition. Here we see that we're past in the cloud blob container, and a string for the blob name. We're going to call GetBlobReferenceFromServerAsync on the container, passing in that blob name, and that will give us back an iCloudBlob, which we will name blob. And then we will write out some statistics about that blob, specifically when the last time it was modified. Run that with a breakpoint so that we can see the results.
And we hit our right line, so let's go over to the display. And turning to the output, we see that the blob was last modified at this date and time. Let's stop. That concludes the list of tests and their output. There's more to examine in the sample applications, but we've looked at the most important aspects of creating blobs, getting their properties, creating containers and so forth.
- Creating an MVC web app
- Publishing an MVC app to Azure
- Creating a SQL database on Azure
- Enabling migrations
- Updating an Azure database
- Changing the schema
- Exploring various types of Blob storage
- Creating Blob storage accounts in Azure
- Examining Azure statistics for monitoring Blob storage