Cloud platforms (such as Google App Engine and Windows Azure) offer a simple deployment experience. Just upload your code, and the cloud takes care of the rest. GigaSpaces XAP v8 brings this user experience without the cloud vendor lock-in. Your application can now be deployed on your laptop, in the data center or on any cloud infrastructure.
Step 1: Start Agent on each machine.
The first step is running an Agent on each machine. Simply run the “gs-agent” script, or write a plugin that does it for you. The GigaSpaces test lab uses two different plugins. The default plugin automatically discovers agents that have been started in advance; the XenServer plugin simulates a cloud environment by starting a new Virtual Machine on-demand. Plugins for public clouds will follow.
Step 2: Deploy and specify maximum Memory and CPU
The second step is specifying the required memory and CPU at any time after deployment. GigaSpaces applications can achieve low latency data access by loading the data and the code into the same process. That requires memory capacity planning (for your data), and CPU capacity planning (for your code). The admin API uses this declarative semantic to describe the application deployment across different machines:
Step 3: Trigger Scale-Out or Scale-In
The manager continuously enforces the specified capacity. It automatically discovers new machines, detects their memory and CPU capabilities, and scales the application on demand to meet the specified capacity. The manager automatically performs corrective actions if a process or a machine fails and maintains a balanced application deployment across machines. Which leaves one thing – the trigger. Triggering the scale-in or scale-out is manually performed by the administrator by issuing the pu.scale() API call.