Archive for the ‘ Windows Azure ’ Category

In the previous post I wrote about Windows Azure Queue. But back then, when I was playing with it I had a significant problem with creating it. The main difficulty was connecting to real Azure Queue (not emulated one). I couldn’t find anywhere how connection string should look like. After some ‚shotgun debugging’ I came up with something that works.

$queueRestProxy = ServicesBuilder::getInstance()->createQueueService('DefaultEndpointsProtocol=https;AccountName={your_account_name};AccountKey=4Gu6Jvm9c5zlaaGEmuA9GZqYr3RzqRfC0W20Yrjnu0sayRnhXeHMCQYWy0IfXnlwTWwPHW2fU+bJ8bqlJRBPgg==');

My AccountName in this string was lower case and you may want to write it that way if something doesn’t work with upper case letters.

I don’t know if it is still valid because it was 6 months ago or more but maybe it will be useful for someone.

Author : beriba | 11/07/2013

This post should have landed here long time ago. It haven’t because I didn’t have enough time to prepare it.

Some time ago I was testing Windows Azure combined with PHP. There were some tools and tutorials around the web. Tutorials were not really up to date. They were saying that development could be done both on windows or linux. And it’s almost true… almost. If you’ll combine it with continuous deployment from git repository, making your „hello world” is just a pleasure. But if you want to do something more, let’s say, add some database to your application, it’s getting tricky. You can develop it only on windows because sqlsrv drivers are out of date and they’re not working on linux. And there are more tricky moments.

One of them shows up when you want to get messages from the queue. Everything is normal when you want to peek 2, 10 or 20 messages. But when you want to peek more than 31 messages there is an unexpected fail. Below code is an example which triggers this error.

$message_options = new PeekMessagesOptions();

An error is saying what happened but that’s all.

400: Fail: Code: 400 Value: One of the query parameters specified in the 
request URI is outside the permissible range. details (if any): 
ďťżOutOfRangeQueryParameterValueOne of the query parameters specified in 
the request URI is outside the permissible range. 

I’m a developer for a long time and I don’t expect any error to tell me every detail. And I’m aware that every technology has it’s limitations but let’s face it – possibility to peek just 31 messages? In cloud? Not good. Instead of saying the same thing twice, there could be some explanation in error message.
I still don’t know why this limit is so low but I don’t want to know. I hope this will be changed.

But there is one thing that I loved about Windows Azure. It’s the best admin panel (or whatever it is called) I’ve ever used. Everything is plain, simple and beautifully animated.