 | News Feed |
 | Jobs Feed |
Sections
|
| feed this: |  |
Brian Swan's Blog: Using SQL Azure Federations via PHP
by Chris Cornutt January 20, 2012 @ 08:31:46
Brian Swan has a new post to his blog about using Azure Federations in your PHP applications:
In a nutshell, SQL Azure Federations introduces an abstraction layer for the sharding of SQL Azure databases. The value in federations lies in your ability to have elastic scalability of the database layer of your application (to match the elastic scalability of the rest of your application when it's running in the cloud). And, one nice thing about the way federations work is that nearly everything can be done with simple SQL commands. Of course, that means that using SQL Azure Federations via PHP should be easy. So in this post, I'll introduce you to SQL Azure federations by showing you how to use them via PHP.
He uses the SQL Server drivers to make the connection to the Azure instance and, based on his included code, creates a federation and tables inside it.
He also shows how to insert data into these tables, split up a federation, insert data after this split and how to query a federation member with the filtering on or off.
voice your opinion now!
azure federation tutorial windows sharding database
Brian Swan's Blog: Automating PHPUnit Tests in Windows Azure
by Chris Cornutt January 05, 2012 @ 11:58:46
Brian Swan has posted another tutorial in a series looking at testing applications on the Azure platform. In this latest post he talks about how to automate your PHPUnit tests as a part of the start up of the instance.
In this post, I'll show you how to deploy your PHPUnit tests with your application, have the tests run as a start up task, and have the results written to your storage account for analysis. Attached to this post is a .zip file that contains a skeleton project that you can use to automatically run PHPUnit tests when you deploy a PHP application to Azure. I'll walk you though how to use the skeleton project, then provide a bit more detail as to how it all works (so you can make modifications where necessary).
He has it broken up into a few easy-to-follow steps:
- Download the AzurePHPWebRole zip archive and unpack it
- Copy your application, tests and PHP installation into the resulting file structure
- Create a skeleton "ServiceConfiguration.cscfg" file with the "cspack" command and edit it to change the "osfamily" and "osversion" settings
- Use "cspack" to package up the application and deploy the application
He walks you through the "how it works" steps too - the things that happen for you automatically on the server side to do things like set up the file to log to, configure the PHP environment and execute the "runtests" Powershell file as included in the AzurePHPWebRole download.
voice your opinion now!
automate test phpunit windows azure deploy automatic tutorial
Michaelangelo van Dam' Blog: Windows Azure for PHP developers
by Chris Cornutt December 12, 2011 @ 09:17:55
In a new post to his blog, Michelangelo van Dam starts off a series looking at Windows Azure for PHP developer, an introduction to the service and what sorts of features it has to offer.
I'm a developer and I don't want to fiddle with setting up and maintaining an operating system, basically since I don't have the time for it. [...] I was completely sold when Josh Holmes came to Brussels in 2009 and told us more about what Windows Azure has to offer and how perfectly it is to build applications consuming these cloud services, without having to deal with setting up and maintaining the platform the run on.
He points out just a few of the features of an Azure instance - pre-installed OS (similar to Windows 2008 Server + IIS7), the five types of storage available (including Queue, SQL Azure and Blob storage). He also mentions working with file uploads, sessions, caching, database interaction and a brief comparison of cloud versus non-cloud scaling methods. In the next part of his series, he'll get more practical and show how to set up a Zend Framework application on an Azure instance.
voice your opinion now!
windows azure introduction series features
Brian Swan's Blog: Running PHPUnit in Windows Azure
by Chris Cornutt December 09, 2011 @ 10:08:47
Brian Swan has a recent post to his MSDN blog about setting up PHPUnit for testing on a Windows Azure platform (as installed via PEAR).
After figuring out how to run PHPUnit from the command line in a Windows Azure instance, I did find that a bit more configuration work than I anticipated was necessary. I'm not 100% certain that this is the best way to run PHPUnit in Windows Azure, but it is one way. I'd be interested in hearing better ways to do this.
He breaks it up into a few different steps:
- Building the application with your tests locally
- Package the application up for Azure deployment
- Enable RDP access on your Azure instance
- Find your PHP and PEAR install on your instance and, logged in via RDP, add their locations to your current path
- Edit the phpunit.bat file to point to the right PHP location
- Execute the tests!
For other options for testing Azure-based applications, see Brian's previous post.
voice your opinion now!
phpunit windows azure unittest rdp
Maarten Balliauw's Blog: Running Memcached on Windows Azure for PHP
by Chris Cornutt October 24, 2011 @ 21:52:11
Maarten Balliauw has a new post to his blog with a guide to running mamcached on Windows Azure for PHP, a tool targeted towards PHP on Windows users to provide them with the ability to cache outside of their application.
While Windows Azure offers a distributed caching layer under the form of the Windows Azure Caching, that components currently lacks support for non-.NET technologies. I've heard there's work being done there, but that's not very interesting if you are building your app today. This blog post will show you how to modify a Windows Azure deployment to run and use Memcached in the easiest possible manner. Note: this post focuses on PHP but can also be used to setup Memcached on Windows Azure for NodeJS, Java, Ruby, Python...
He provides a phar-based scaffolding you can use to set up the instance and describes two ways of accomplishing it - the "short way" of relying on the scaffolding or the "long way" describing what the scaffolder does behind the scenes (complete with code). For this, you can also download the source and look through it.
voice your opinion now!
windows azure memcached caching tool tutorial
Brian Swan's Blog: Using SQL Azure to Store PHP Session Data
by Chris Cornutt October 21, 2011 @ 08:32:46
In a recent post to his blog Brian Swan takes a look at working with sessions in PHP and, specifically, how to save them to Azure along with all of their data.
In my last post, I looked at the session handling functionality that is built into the Windows Azure SDK for PHP, which uses Azure Tables or Azure Blobs for storing session data. As I wrote that post, I wondered how easy it would be to use SQL Azure to store session data, especially since using a database to store session data is a common and familiar practice when building distributed PHP applications. As I found out, using SQL Azure to store session data was relatively easy (as I'll show in this post), but I did run into a couple of small hurdles that might be worth taking note of.
He uses PHP's own session_set_save_handler to point to his custom Azure handling class with the needed methods (like write, close and destroy). He breaks it out into three simple steps, some with a bit of code attached:
- Create the database, table, and stored procedure
- Add the SqlAzureSessionHandler class to your project
- Instantiate SqlAzureSessionHandler before calling session functions as you normally would
The code for the Azure handling class can be downloaded here.
voice your opinion now!
sql azure session data cache sqlserver windows
Web Species Blog: We built a cloud platform for PHP. Wait...what?
by Chris Cornutt October 04, 2011 @ 10:33:04
As mentioned on the Web Species blog in this recent post, they've developed a "Windows Azure done right" platform (Azure++, name pending) that makes deploying to an Azure platform a much simpler process, pulling from something like a remote code repository (maybe github) and deploying in less than five seconds.
Azure is just impossible to use for PHP today. This is a fact. Doesn't matter which way you look at it, it just su.. isn't particularly good. The amount of steps you need to make, the knowledge you need to have and the fact that you can only deploy from Windows host are some of the things which make it a very painful experience. I had enough of this pain.
The service helps you make quick and easy Azure deployments. Features include multiple datacenter support, your choice of PHP versions (5.2 or 5.3) and the ability to deploy in "production" or "development" environments. You can find out more about the service here.
voice your opinion now!
cloud platform windowsazure azure deployment github service
Maarten Balliauw's Blog: Windows Azure SDK for PHP 4 released
by Chris Cornutt July 29, 2011 @ 09:53:19
Maarten Balliauw has a new post announcing the release of the latest Windows SDK for Azure for PHP, version 4.
The Windows Azure SDK 4 contains some significant feature enhancements. For example, it now incorporates a PHP library for accessing Windows Azure storage, a logging component, a session sharing component and clients for both the Windows Azure and SQL Azure Management API's. On top of that, all of these API's are now also available from the command-line both under Windows and Linux. This means you can batch-script a complete datacenter setup including servers, storage, SQL Azure, firewalls, ... If that's not cool, move to the North Pole.
He includes a few things from the changelog including service management API support for SQL Azure, package scaffolders and various performance enhancements. You can find out more about the release and the latest on the project on the Microsoft Interoperability website.
voice your opinion now!
windows azure sdk api release version microsoft
|
Community Events
Don't see your event here? Let us know!
|