The Elastic PU Feb 2011
The Elastic PU <ul><li>SLA based deployed (memory/cores). </li></ul><ul><li>Support Data-Grid and Custom PU. </li></ul><ul...
Entire Container Lifecycle Management <ul><li>When using the EPU, GigaSpaces manage the  entire  life cycle of the contain...
EPU Deployment Flow <ul><li>Start agents </li></ul><ul><li>Deploy PU </li></ul><ul><ul><li>Specify maximum PU capacity </l...
Step 1 - Start a GigaSpaces agent on each machine <ul><li>gs-agent.bat  gsa.global.esm 1  gsa.gsc 0 gsa.global.gsm 2 gsa.g...
Step 2 - Run the deployment code <ul><li>Admin admin = new AdminFactory().addGroup(&quot;myGroup&quot;).create(); </li></u...
Step 3 - Scale the PU by increasing the memory and CPU capacity – Manual Mode <ul><li>pu.scale( </li></ul><ul><li>new Manu...
Deployment  Server Deploy New Stateful EPU: -   64 GB Max Capacity - 32 GB Initial capacity - Highly Available - 4GB JVM h...
Scale Out – Manual Mode Server Grid Service Manager Data Center Server Server Agent Agent JVM JVM Server Server Agent Agen...
Scale Out – Eager Mode Server Grid Service Manager Data Center Server Server Agent Agent JVM JVM Server Server Agent Agent...
Step 4 - undeploy <ul><li>ProcessingUnit pu = admin.getProcessingUnits().waitFor(&quot;myPU&quot;,10,TimeUnit.SECONDS); </...
Automatic Rebalancing <ul><li>Enforce equal amount of primary and backup instances across all the available machines. </li...
Automatic Machine Provisioning <ul><li>The EPU supports automatic Virtual Machines provisioning through custom plugins.  <...
<ul><li>End! </li></ul>
Upcoming SlideShare
Loading in …5
×

The Elastic PU

7,057 views
6,963 views

Published on

The Elastic PU

Published in: Technology
0 Comments
1 Like
Statistics
Notes
  • Be the first to comment

No Downloads
Views
Total views
7,057
On SlideShare
0
From Embeds
0
Number of Embeds
5,165
Actions
Shares
0
Downloads
8
Comments
0
Likes
1
Embeds 0
No embeds

No notes for slide
  • Anmations: deploy, failover, scale out
  • The Elastic PU

    1. 1. The Elastic PU Feb 2011
    2. 2. The Elastic PU <ul><li>SLA based deployed (memory/cores). </li></ul><ul><li>Support Data-Grid and Custom PU. </li></ul><ul><li>Automatic container lifecycle management. </li></ul><ul><li>Automatic rebalancing (repartitioning). </li></ul><ul><li>Automatic partition count calculation. </li></ul><ul><li>Scale up/down or in/out without system downtime. </li></ul><ul><li>Eager and manual scale strategies. </li></ul><ul><li>Automatic Machine Provisioning plug-in. </li></ul>
    3. 3. Entire Container Lifecycle Management <ul><li>When using the EPU, GigaSpaces manage the  entire  life cycle of the container. </li></ul><ul><li>Once the EPU is deployed containers are started and the EPU instances are provisioned into these containers. </li></ul><ul><li>When the EPU scales up, additional containers are started and instances are relocated into these containers. </li></ul><ul><li>When the EPU is un-deployed, all the containers associated with the EPU are automatically terminated. </li></ul>
    4. 4. EPU Deployment Flow <ul><li>Start agents </li></ul><ul><li>Deploy PU </li></ul><ul><ul><li>Specify maximum PU capacity </li></ul></ul><ul><ul><li>Specify container memory capacity </li></ul></ul><ul><ul><li>Specify initial PU capacity </li></ul></ul><ul><li>Scale up/down or in/out </li></ul><ul><li>Undeploy </li></ul>
    5. 5. Step 1 - Start a GigaSpaces agent on each machine <ul><li>gs-agent.bat gsa.global.esm 1 gsa.gsc 0 gsa.global.gsm 2 gsa.global.lus 2&quot; </li></ul>You should have one GigaSpaces agent running the ESM. No GSCs should be started manually!
    6. 6. Step 2 - Run the deployment code <ul><li>Admin admin = new AdminFactory().addGroup(&quot;myGroup&quot;).create(); </li></ul><ul><li>admin.getGridServiceAgents().waitForAtLeastOne(); </li></ul><ul><li>admin.getElasticServiceManagers().waitForAtLeastOne(); </li></ul><ul><li>GridServiceManager gsm = admin.getGridServiceManagers().waitForAtLeastOne(); </li></ul><ul><li>// Deploy the Elastic Processing Unit. Set the maximum memory and CPU capacity and initial capacity </li></ul><ul><li>File puArchive = new File(&quot;/opt/gigaspaces/myPU.jar&quot;); </li></ul><ul><li>ProcessingUnit pu = gsm.deploy( </li></ul><ul><li>new ElasticStatefulProcessingUnitDeployment( puArchive ) </li></ul><ul><li>.memoryCapacityPerContainer(16,MemoryUnit.GIGABYTES) </li></ul><ul><li>.maxMemoryCapacity(512,MemoryUnit.GIGABYTES) </li></ul><ul><li>.maxNumberOfCpuCores(32) </li></ul><ul><li>//.singleMachineDeployment() // uncomment when working with a single machine agent </li></ul><ul><li>// set the initial memory and CPU capacity </li></ul><ul><li>.scale(new ManualCapacityScaleConfigurer() </li></ul><ul><li>.memoryCapacity(128,MemoryUnit.GIGABYTES) </li></ul><ul><li>.numberOfCpuCores(8) </li></ul><ul><li>.create()) </li></ul><ul><li>); </li></ul>
    7. 7. Step 3 - Scale the PU by increasing the memory and CPU capacity – Manual Mode <ul><li>pu.scale( </li></ul><ul><li>new ManualCapacityScaleConfigurer() </li></ul><ul><li>.memoryCapacity(256,MemoryUnit.GIGABYTES) </li></ul><ul><li>.numberOfCpuCores(16) </li></ul><ul><li>.create() </li></ul><ul><li>);i </li></ul>
    8. 8. Deployment Server Deploy New Stateful EPU: - 64 GB Max Capacity - 32 GB Initial capacity - Highly Available - 4GB JVM heap size Grid Service Manager Data Center Server Server Agent Agent JVM JVM Server Server Agent Agent JVM JVM JVM JVM JVM JVM B B B B P P P P P P B B P P B B
    9. 9. Scale Out – Manual Mode Server Grid Service Manager Data Center Server Server Agent Agent JVM JVM Server Server Agent Agent JVM JVM Server Agent JVM JVM JVM JVM JVM JVM Scale Stateful EPU: - Increase memory Capacity to 40GB Capacity B B B P P P P P P B B P B B P B
    10. 10. Scale Out – Eager Mode Server Grid Service Manager Data Center Server Server Agent Agent JVM JVM Server Server Agent Agent JVM JVM Server Agent JVM JVM JVM JVM JVM Monitoring Available Memory/Cores Resource Capacity JVM B B B P P P P P P B B P B B P B
    11. 11. Step 4 - undeploy <ul><li>ProcessingUnit pu = admin.getProcessingUnits().waitFor(&quot;myPU&quot;,10,TimeUnit.SECONDS); </li></ul><ul><li>if (pu != null) { </li></ul><ul><li>pu.undeploy(); </li></ul><ul><li>} </li></ul>
    12. 12. Automatic Rebalancing <ul><li>Enforce equal amount of primary and backup instances across all the available machines. </li></ul><ul><li>Start new containers as needed based on the pre-defined SLA. </li></ul>
    13. 13. Automatic Machine Provisioning <ul><li>The EPU supports automatic Virtual Machines provisioning through custom plugins. </li></ul><ul><li>The plugins are open source  http:// svn.openspaces.org/cvi/trunk  and provide an implementation of ElasticMachineProvisioningConfig  and  ElasticMachineProvisioning </li></ul>ProcessingUnit pu = gsm.deploy( new ElasticStatefulProcessingUnitDeployment(new File(&quot;myPU.jar&quot;)) .memoryCapacityPerContainer(16,MemoryUnit.GIGABYTES) .maxMemoryCapacity(512,MemoryUnit.GIGABYTES) .maxNumberOfCpuCores(32) //automatically start new virtual machines on demand .machineProvisioning(new XenServerMachineProvisioning(&quot;xenserver.properties&quot;)) );
    14. 14. <ul><li>End! </li></ul>

    ×