-
Notifications
You must be signed in to change notification settings - Fork 0
RFC ZendService_OpenStack
This RFC proposes the implementation of an OpenStack service component for ZF2. The OpenStack initiative has grown very fast in the last months and we can decide to support it with an dedicated service component for ZF2.
OpenStack is a cloud operating system that controls large pools of compute, storage, and networking resources throughout a datacenter, all managed through a dashboard that gives administrators control while empowering their users to provision resources through a web interface.
We released the ZendService_Rackspace components some months ago to support the Rackspace cloud services. Rackspace uses the OpenStack API protocol to manage the cloud infrastructures, that means an OpenStack service components can be implemented starting from the existing ZendService_Rackspace.
We propose to implement a new ZendService_OpenStack component for ZF2.
The OpenStack software manages three different services:
- compute;
- networking;
- storage.
The ZendService_OpenStack should support all these services using the OpenStack API protocol. The last API versions for OpenStack are:
- Compute API 2.0;
- Identity API 2.0;
- Image API 2.0;
- Object Storage API 1.0;
- Networking API 2.0;
- Volume API 1.0.
The idea of the ZendService_OpenStack is to provide an OO interface to the API such as the one implemented in ZendService_Rackspace. Using this interface we will facilitate the usage of the OpenStack API using a layer of abstraction. For instance, a usage of the ZendService_OpenStack to store a file using the storage service can be expressed as follow:
$name = 'example.jpg';
$openstack = new ZendService\OpenStack\Storage($user, $key);
if (!$openstack->authenticate()) {
printf("ERROR: %s", $openstack->getErrorMsg());
exit();
}
if ($openstack->createContainer('test')) {
$name = 'example.jpg';
$openstack->storeObject('test', $name, file_get_contents($name));
}