3

I am working with Windows Azure and am just using the Blob Storage. I have setup my Blob Storage to run in its own Solution file with a dummy web role. I run it first on my development machine so the Azure Services start. I have configured the service to use the development shared key and account name.

I am running into an issue when I point my web application (in another solution) to the local Blob Storage service. I can upload a file to the Blob Storage and I can see the records in my local database. Therefore, I have entered the correct settings in the web.config. However, I cannot access the file via a simple Get request. I have verified that the container is public.

The URI I am using is:

http://127.0.0.1:10000/{container-name}/{filename}.{extension}

My code works when I use my production Azure Services, so is there something different about the Development Environment that I am missing? Does the local environment allow REST access?

UPDATE: I recently found this MSDN Article that describes the differences between production and development Storage URIs. I also documented my environment here on my blog.

1
  • What do you mean by "Does the local environment allow REST access?" For the blob, you should just be able to put the url in your browser and it should be served up (only uses a get with no auth) ... Are you trying to do something fancier than that? For a local storage sample I have the following image url returns the blob in my local storage (incident1=container name): 127.0.0.1:10000/devstoreaccount1/incident1/chrysanthemum.jpg Commented Dec 10, 2009 at 12:44

2 Answers 2

9

The uri looks to be slightly incorrect, the format for the development storage uri is:

http://<local-machine-address>:<port>/<account-name>/<resource-path>

Given that the account name is always devstoreaccount1 your uri should be:

http://127.0.0.1:10000/devstoreaccount1/{container-name}/{filename}.{extension}
Sign up to request clarification or add additional context in comments.

2 Comments

Nigel, your suggestion worked and is perfect. However, I wasted some time thinking that it did not work because there is a space between devstoreaccount1 and the "/". If you edit your post to remove that I will choose yours as the answer. I was copying and pasting the first part of your URI and appending mine which is why I had the problem.
Sorry about that, I was copying and pasting around the account name.
0

What kind of response or error code are you getting? If you are using IE- you can install Fiddler or use the built in developer tools in IE8 to help debug a communication problem. Sure- the development fabric works in REST!

Comments

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.