GigaSpaces Scalability Live Demo


Published on

Experience how XAP scales web servers based on load. Learn how our In-Memory Data Grid performs automatic recovery when a machine failes.

Published in: Technology
  • Be the first to comment

  • Be the first to like this

No Downloads
Total views
On SlideShare
From Embeds
Number of Embeds
Embeds 0
No embeds

No notes for slide

GigaSpaces Scalability Live Demo

  1. 1. GigaSpaces Scalability Live Demo
  2. 2. In this Demo <ul><li>Experience automatic scaling based on request throughput </li></ul><ul><li>See how the application fails over and auto-recovers after failure </li></ul>
  3. 3. How to Experience Automatic Scaling <ul><li>Deploy the demo on the cloud </li></ul><ul><li>Study the demo architecture </li></ul><ul><li>Web auto-scaling (requests/sec threshold) </li></ul><ul><li>Automatic failover and auto-recovery </li></ul>
  4. 4. <ul><li>STEP 1 – </li></ul><ul><li>DEPLOY THE DEMO ON THE CLOUD </li></ul>
  5. 5. How to Experience Automatic Scaling? <ul><li>Click Deploy </li></ul><ul><li>Click Refresh Status </li></ul><ul><li>Wait until application status = </li></ul>Deployed Expected waiting time: ~7 min In the meantime let’s study the stock demo architecture…
  6. 6. <ul><li>STEP 2 – </li></ul><ul><li>STOCK DEMO ARCHITECTURE </li></ul>
  7. 7. Architecture – Processor Space <ul><li>Stock feeder simulates stock price changes </li></ul><ul><li>Processor analyzes data as it arrives (price change delta) </li></ul>Processor (Code + Data) Write Data
  8. 8. <ul><li>Stock data exposed to web browser with AJAX </li></ul>Architecture – Embedded Web Server Web Load-Balancer http:// http:// Read Data (SQL Query), Get Statistics (Admin API) Write Data Processor (Code + Data)
  9. 9. Stock Application Home Page Stock data exposed via REST
  10. 10. Stock Application Home Page <ul><li>Map/Reduce query via REST </li></ul>
  11. 11. Application Home Page – Statistics Space (data) statistics JVM statistics Web statistics
  12. 12. <ul><li>STEP 3 – </li></ul><ul><li>WEB AUTO-SCALING </li></ul>
  13. 13. How to Experience Automatic Scaling <ul><li>Wait until application status = </li></ul><ul><li>Click View Stocks </li></ul><ul><li>Note the Web Requests/Second gauge </li></ul>Deployed
  14. 14. Web Container Auto-Scaling Load Balancer monitors web availability Web Web Load-Balancer
  15. 15. Web Web Web Load-Balancer Web Container Auto-Scaling A new machine is started when the requests-per-second threshold is breached
  16. 16. Increase Load – Auto-scale-out Click View Stocks twice A total of 3 “View Stocks” pages are open. Note that the gauge is above threshold.
  17. 17. Increase Load – Auto-scale-out Wait for a machine to start automatically.
  18. 18. Increase Load – Auto-scale-out When the machine starts, the number of web Processing Units (PUs) increases from 2 to 3
  19. 19. Decrease Load – Auto-scale-in Close 2 “View Stocks” pages (leave only 1 open) Note the gauge is below threshold
  20. 20. Decrease Load – Auto-scale-in Wait until a Web_Container machine is automatically terminated (scaling in back to 2 machines). This might take a few minutes
  21. 21. Step 3 – Recap <ul><li>Increase load by starting additional web pages  Web server scales out </li></ul><ul><li>Decrease load by closing the additional pages  Web server scales in </li></ul>
  22. 22. <ul><li>STEP 4 – </li></ul><ul><li>AUTOMATIC FAILOVER AND </li></ul><ul><li>AUTO-RECOVERY </li></ul>
  23. 23. Automatic Failover of Data Grid Stock updates are replicated to backup Partition 1 Active Partition 2 Backup Partition 2 Active Partition 1 Backup Write Data Replication
  24. 24. Automatic Failover of Data Grid When a machine fails, backup becomes primary Partition 1 Active Partition 2 Active Partition 1 Backup Partition 2 Active Write Data
  25. 25. Automatic Recovery of Data Grid A new machine is started, backups are deployed Partition 2 Backup Partition 1 Backup Partition 1 Active Partition 2 Active Write Data Replication
  26. 26. Automatic Recovery of Data Grid Number of active instances is re-balanced Replication Partition 1 Active Partition 2 Backup Partition 2 Active Partition 1 Backup Write Data
  27. 27. Start the Monitoring Web Dashboard <ul><li>Click Monitor to start the web dashboard </li></ul><ul><li>(works best with Firefox / Chrome) </li></ul><ul><li>Click Login (anonymous login) </li></ul>
  28. 28. The Processor Space (Web Dashboard) <ul><li>Expand ProcessorPU </li></ul><ul><li>tree node. </li></ul><ul><li>Note each partition </li></ul><ul><li>Has a primary (green) </li></ul><ul><li>and a backup (blue) </li></ul><ul><li>instance. </li></ul>
  29. 29. Shut Down Machine <ul><li>Switch back to the main screen, </li></ul><ul><li>and click the Shutdown button of one </li></ul><ul><li>Web_Container machine: </li></ul>
  30. 30. Failover (Web Dashboard) <ul><li>Switch back to the Web Dashboard. </li></ul><ul><li>Note how Backup (blue) becomes Active (green) </li></ul>
  31. 31. Experience Machine Failover <ul><li>Wait until a new machine is started and the Processor space rebalances. </li></ul>
  32. 32. Step 4 – Recap <ul><li>Machine failure  New machine starts automatically A backup space instance takes over </li></ul><ul><li>Machine started  </li></ul><ul><li>New backup space started </li></ul><ul><li>Rebalancing of active instances. </li></ul>
  33. 33. What This Demo Illustrated <ul><li>Automatic scaling of the web application based on load </li></ul><ul><li>Automatic recovery from machine failures </li></ul>