Archive for August, 2010

What is Cloud Computing ?

August 31st, 2010

Cloud Computing is a comparatively leading edge technology that virtualizes the utilization of applications through the channel of the web. Instead of physical installation of software and other applications on PC systems, cloud computing calls for installation and upkeep of the same applications on a single, centralized server. Multiple users may be able to access and share this centrally stored application and info and use it in real time to attain results not just quickly but also more effectively. The commonest examples of cloud computing are found in common business applications that were earlier used thru PCs but are now used thru the Net.

While application data in traditional software was stored hereabouts on the machine, cloud computing takes this information and stores it on an internet server.

Cloud Computing Types :

While cloud computing applications are wide and divided, they can be broadly divided into 7 classes:

1. Software as a Service
2. Platform as a Service
3. Application Computing
4. Web Services
5. Managed Service Suppliers
6. Web Integration and
7. Service Commerce

Cloud computing is reliant on inspiration drawn from the telecoms industry, which popped up with the idea of Virtual Personal Network ( VPN ) to meet the demands of long distance telephony at lower costs. By offering shared use of bandwidth thru perfect load balancing, VPN authorized telecoms suppliers to chop cost while expanding their service range. In cloud computing some of the earliest players have been, Amazon and Microsoft, though commercial cloud computing was introduced by a less well-known company named Loud cloud. Microsoft and Amazon though can be credited with the expansion in use of the technology and also the rise in demand for cloud computing education.

Symfony multiple versions on the same environment

August 17th, 2010

Follow under given steps for best way of running multiple versions of Symfony apps together on the one environment…

Step 1 – Un-install Symfony via PEAR
If you have Symfony installed via PEAR, get rid of it, it will only confuse you with what we are about to do.

express@express-dev:~$ sudo pear uninstall symfony/symfony
uninstall ok: channel://pear.symfony-project.com/symfony-1.1.0

Step 2 – Setup a structure for Symfony
In our case, I still want to install symfony in /usr/share/php/symfony, so lets set that up:

express@express-dev:~$ cd /usr/share/php
express@express-dev:/usr/share/php$ sudo mkdir symfony

Step 3 – Checkout each Symfony version you need
Now lets use SVN checkout to grab each Symfony version we are after, lets put these in a different folder under the base Symfony directory. Note: If you are behind a proxy, change your SVN settings first to go through your proxy. To change your proxy settings:

express@express-dev:/usr/share/php/symfony$ sudo nano /etc/subversion/servers

Now lets checkout each symfony version:
express@express-dev:/usr/share/php$ cd symfony/
express@express-dev:/usr/share/php/symfony$ sudo svn co http://svn.symfony-project.com/branches/1.0 symfony10

express@express-dev:/usr/share/php/symfony$ sudo svn co http://svn.symfony-project.com/branches/1.1 symfony11

express@express-dev:/usr/share/php/symfony$ sudo svn co http://svn.symfony-project.com/branches/1.2 symfony12

We now have created three installations of Symfony.

Step 4 – Create symbolic links for each version
The next step is for us to create symlinks for each version of Symfony. Lets place these in the standard bin directory:

sudo ln -s /usr/share/php/symfony/symfony10/data/bin/symfony /usr/bin/symfony10
sudo ln -s /usr/share/php/symfony/symfony11/data/bin/symfony /usr/bin/symfony11
sudo ln -s /usr/share/php/symfony/symfony12/data/bin/symfony /usr/bin/symfony12

Now lets test the sym links:

express@express-dev:~$ symfony10 -V
symfony version 1.0.19-PRE
express@express-dev:~$ symfony11 -V
symfony version 1.1.5-DEV (/usr/share/php/symfony/symfony11/lib)
express@express-dev:~$ symfony12 -V
symfony version 1.2.0-DEV (/usr/share/php/symfony/symfony12/lib)

What next? – Creating a new project
So to create a new project, you will need to use the relevant Symfony command. For example, to create a Symfony 1.0 project:

sudo symfony10 init-project test1

or to create a Symfony 1.1 or Symfony 1.2 Project:

sudo symfony11 generate:project test11
sudo symfony12 generate:project test12

Once you create a new project, check in the project Config to ensure its picked up the right version. For Symfony 1.0:

express@express-dev:/usr/local/express/projects/$ sudo symfony10 init-project test10
express@express-dev:/usr/local/express/projects/$ cat config/config.php

// symfony directories
$sf_symfony_lib_dir = ‘/usr/share/php/symfony/symfony10/lib’;
$sf_symfony_data_dir = ‘/usr/share/php/symfony/symfony10/data’;

for Symfony 1.1:
express@express-dev:/usr/local/express/projects/test$ cat config/ProjectConfiguration.class.php

require_once ‘/usr/share/php/symfony/symfony11/lib/autoload/sfCoreAutoload.class.php’;
sfCoreAutoload::register();
class ProjectConfiguration extends sfProjectConfiguration
{
public function setup()
{
}
}

and for Symfony 1.2, its the same, just make sure its including the right 1.2 files. Thats it! Hope this helps!