Ogf2008 Grid Data Caching

677 views

Published on

Increasing computation throughput for data intensive grid applications using Grid data caching.

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

  • Be the first to like this

No Downloads
Views
Total views
677
On SlideShare
0
From Embeds
0
Number of Embeds
18
Actions
Shares
0
Downloads
28
Comments
0
Likes
0
Embeds 0
No embeds

No notes for slide
  • Ogf2008 Grid Data Caching

    1. 1. Increasing computation throughput with Grid Data Caching Jags Ramnarayan Chief Architect GemStone Systems [email_address]
    2. 2. Background on GemStone Systems <ul><li>Known for its Object Database technology since 1982 </li></ul><ul><li>Now specializes in memory-oriented distributed data management </li></ul><ul><ul><li>12 pending patents </li></ul></ul><ul><li>Over 200 installed customers in global 2000 </li></ul><ul><li>Grid focus driven by: </li></ul><ul><ul><li>Very high performance with predictable throughput, latency and availability </li></ul></ul><ul><ul><ul><li>Capital markets – risk analytics, pricing, etc </li></ul></ul></ul><ul><ul><ul><li>Large e-commerce portals – real time fraud </li></ul></ul></ul><ul><ul><ul><li>Federal intelligence </li></ul></ul></ul>
    3. 3. Batch to real-time - long jobs to short tasks
    4. 4. Increasing focus on DATA management <ul><li>Workloads where </li></ul><ul><ul><li>task duration is getting shorter </li></ul></ul><ul><ul><li>latency of data access is important </li></ul></ul><ul><ul><li>consistency in data is crucial </li></ul></ul><ul><ul><li>high availability is not enough; it has to be continuously available </li></ul></ul><ul><ul><li>common data across thousands of parallel activities </li></ul></ul>
    5. 5. Accessing data in Grid today <ul><li>Direct access to enterprise database or </li></ul><ul><li>Federated data access layer </li></ul><ul><ul><ul><li>Exposed to the weakest link problem </li></ul></ul></ul><ul><ul><ul><ul><li>only as fast as the slowest data source </li></ul></ul></ul></ul><ul><ul><ul><ul><li>only as available as the weakest link </li></ul></ul></ul></ul><ul><ul><ul><ul><li>can only scale as well as the weakest link </li></ul></ul></ul></ul><ul><li>Distributed/parallel file systems </li></ul><ul><ul><ul><li>What if too many tasks go after the same data? </li></ul></ul></ul><ul><ul><ul><li>Disk access speed is still 1000X slower than memory </li></ul></ul></ul><ul><ul><ul><li>Data consistency challenges </li></ul></ul></ul>Might be controversial here 
    6. 6. Impact to Grid SLA
    7. 7. Introducing memory oriented data fabric <ul><li>Pool memory (and disk) across cluster/Grid </li></ul><ul><ul><li>Managed as a single unit </li></ul></ul><ul><ul><li>Replicate data for high concurrent load, HA </li></ul></ul><ul><ul><li>Distribute (partition) data for high data volume, scale </li></ul></ul><ul><ul><li>Gracefully expand capacity to meet scalability/Perf goals </li></ul></ul>Distributed Data Space Data warehouses Rational databases Distributed Applications
    8. 8. How does it work? When data is stored, it is transparently replicated and/or partitioned; Redundant storage can be in memory and/or on disk— ensures continuous availability Machine nodes can be added dynamically to expand storage capacity or to handle increased client load Shared Nothing disk persistence - Each cache instance can optionally persist to disk Synchronous read through, write through or Asynchronous write-behind to other data sources and sinks
    9. 9. Predictably scale with partitioning Distributed Apps By keeping data spread across many nodes in memory, we can exploit the CPU and network capacity on each node simultaneously to provide linear scalability A1 B1 C1 D1 E1 F1 G1 H1 I1 Local Cache Partitioning Meta Data Single Hop <ul><li>Parallel loading by many Grid nodes </li></ul><ul><ul><li>only limited by CPU and network backbone </li></ul></ul><ul><li>With partitioning meta data on each compute node, access to any single piece of data is a single hop </li></ul><ul><li>As changes are redundantly and synchronously managed, availability and consistency is preserved </li></ul><ul><li>Dynamically detect load changes and add or remove nodes for data </li></ul><ul><ul><li>Automatic data re-partitioning will condition the load </li></ul></ul>
    10. 10. Collocate data for near infinite scale Distributed Apps A1 B1 C1 D1 E1 F1 G1 H1 I1 Local Cache Partitioning Meta Data Single Hop <ul><li>Different Partitioning policies </li></ul><ul><li>Hash partitioning </li></ul><ul><ul><li>Suitable for key based access </li></ul></ul><ul><ul><li>Uniform random hashing </li></ul></ul><ul><li>Dramatically scale by keeping all related data together </li></ul><ul><li>Application managed - associations </li></ul><ul><ul><li>Orders hash partitioned but associated line items are collocated </li></ul></ul><ul><li>Application managed </li></ul><ul><ul><li>Grouped on data object field(s) </li></ul></ul><ul><ul><li>Customize what is collocated </li></ul></ul><ul><ul><li>Example: ‘Manage all Sept trades in one data partition’ </li></ul></ul>
    11. 11. Move business logic to data f 1 , f 2 , … f n FIFO Queue Data fabric Resources Exec functions Sept Trades Submit (f1) -> AggregateHighValueTrades(<input data>, “ where trades.month=‘Sept ’) Function (f1) Function (f2) <ul><ul><li>Principle: Move task to computational resource with most of the relevant data before considering other nodes where data transfer becomes necessary </li></ul></ul><ul><ul><li>Fabric function execution service </li></ul></ul><ul><ul><li>Data dependency hints </li></ul></ul><ul><ul><ul><li>Routing key, collection of keys, “where clause(s)” </li></ul></ul></ul><ul><ul><li>Serial or parallel execution </li></ul></ul><ul><ul><ul><li>“ Map Reduce” </li></ul></ul></ul>
    12. 12. Parallel queries <ul><li>Query execution for Hash policy </li></ul><ul><ul><li>Parallelize query to each relevant node </li></ul></ul><ul><ul><li>Each node executes query in parallel using local indexes on data subset </li></ul></ul><ul><ul><li>Query result is streamed to coordinating node </li></ul></ul><ul><ul><li>Individual results are unioned for final result set </li></ul></ul><ul><ul><li>This “scatter-gather” algorithm can waste CPU cycles </li></ul></ul><ul><li>Partition the data on the common filter </li></ul><ul><ul><li>For instance, most queries are filtered on a Trade symbol </li></ul></ul><ul><ul><li>Query predicate can be analyzed to prune partitions </li></ul></ul>1. select * from Trades where trade.month = August 2. Parallel query execution 3. Parallel streaming of results 4. Results returned
    13. 13. Key lessons <ul><li>Apps should think about capitalizing memory across Grid (it is abundant) </li></ul><ul><li>Keep IO cycles to minimum through main memory caching of operational data sets </li></ul><ul><ul><li>Scavange Grid memory and avoid data source access </li></ul></ul><ul><li>Achieve near infinite scale for your Grid apps by horizontally partitioning your data and behavior </li></ul><ul><ul><li>Read “Pat helland’s – Life beyond Distributed transactions” ( http://www-db.cs.wisc.edu/cidr/cidr2007/papers/cidr07p15.pdf ) </li></ul></ul><ul><li>Get more info on the GemFire data fabric </li></ul><ul><ul><li>http:// www.gemstone.com/gemfire </li></ul></ul>

    ×