SlideShare une entreprise Scribd logo
1  sur  24
Télécharger pour lire hors ligne
Going	
  by	
  TACC:	
  
Beyond	
  Key-­‐Value	
  to	
  Fault-­‐Tolerant	
  
 Stores	
  with	
  Easily	
  Customizable	
  
               Semantics	
  

                  Henk	
  Goosen,	
  CEO	
  
               goosen@optumsoft.com	
  
Key-­‐value	
  stores	
  rule	
  the	
  Web	
  


  Many	
  applications	
  only	
  need	
  primary	
  key	
  data	
  access	
  
  Examples:	
  catalogs,	
  shopping	
  carts,	
  web	
  session	
  state	
  
  No	
  need	
  for	
  the	
  complexity,	
  performance	
  overhead,	
  
  and	
  lack	
  of	
  scalability	
  of	
  a	
  full	
  database	
  
  Hence:	
  Key-­‐value	
  stores	
  are	
  everywhere	
  
     Dynamo,	
  CouchDB,	
  Cassandra,	
  Project	
  Voldemort,	
  Riak,	
  
     Redis,	
  memcached,	
  MongoDB,	
  …	
  

                    Improving key-value stores is important
                             OptumSoft, Inc. Proprietary and                     2	
  
                             Confidential
Key-­‐value	
  stores	
  in	
  practice	
  


  Developing	
  a	
  key-­‐value	
  store	
  from	
  scratch	
  using	
  
  conventional	
  languages	
  is	
  expensive:	
  
     scalability,	
  performance,	
  and	
  fault	
  tolerance	
  
  Conventional	
  solution:	
  use	
  existing	
  key-­‐value	
  store	
  
     Layer	
  on	
  get()	
  and	
  put()	
  semantics	
  
  Mismatches	
  between	
  application	
  requirements	
  and	
  
  library:	
  either	
  accept	
  or	
  extensively	
  modify	
  library	
  code	
  	
  
                            Applications are more complex,
                            performance suffers
                                 OptumSoft, Inc. Proprietary and                           3	
  
                                 Confidential
TACC	
  provides	
  a	
  different	
  model	
  

    Use	
  a	
  very	
  high-­‐level	
  language	
  to	
  specify	
  the	
  key-­‐value	
  
    store	
  
    Then	
  customize	
  the	
  store,	
  applying	
  application-­‐specific	
  
    semantics	
  
    Benefits:	
  
       Simplifies	
  the	
  application	
  business	
  logic	
  
       Improves	
  the	
  performance	
  of	
  both	
  store	
  and	
  application	
  

                                                 TACC model is better!

                                   OptumSoft, Inc. Proprietary and                            4	
  
                                   Confidential
TACC	
  is	
  an	
  object-­‐oriented,	
  
    strongly	
  typed	
  language	
  

  User-­‐defined	
  type:	
  a	
  list	
  of	
  attributes	
  (nouns)	
  
  Read	
  or	
  write	
  attributes	
  (there	
  are	
  no	
  methods/verbs)	
  
  Logic	
  primarily	
  implemented	
  via	
  constraints	
  
     imperative	
  code	
  is	
  also	
  supported	
  
  Compact	
  code	
  
     First	
  class	
  high	
  level	
  data	
  types	
  (eg,	
  queues,	
  hash	
  tables)	
  
     Several	
  design	
  patterns	
  directly	
  supported	
  in	
  language	
  
     (eg	
  observer	
  pattern)	
  
    Compact code  fewer bugs, quicker to market
                                                                                                  5	
  
TACC:	
  efficient	
  development	
  of	
  
     distributed	
  systems	
  

   Reduce	
  development	
  time	
  by	
  a	
  factor	
  of	
  2x	
  to	
  3x	
  
   Reduce	
  lines	
  of	
  code	
  by	
  10x	
  or	
  more	
  
   Eliminate	
  most	
  synchronization	
  and	
  concurrency	
  bugs	
  
   High,	
  predictable	
  performance	
  using	
  optimized	
  code	
  
   generation	
  
   Fault-­‐Tolerance	
  built	
  into	
  the	
  model,	
  and	
  easy	
  to	
  
   implement	
  
                        TACC is a general purpose language,
                        focused on distributed systems
                                                                                    6	
  
Stateful	
  remote	
  proxy	
  objects	
  

                  LR	
  1
                        	
            LR	
  2	
  
 Agents         1
                	
                                     Proxy:	
  local	
  copy	
  of	
  data	
  
                                         1
                                         	
  
                                                       Writes	
  are	
  asynchronously	
  
object added                                           copied	
  to	
  SysDB	
  
to collection
                                                       SysDB	
  changes	
  are	
  copied	
  
                                                       to	
  “interested”	
  agents	
  
                                                       R/W	
  access	
  is	
  local,	
  fast	
  
 SysDB                         1
                               	
  
                                                       No	
  remote	
  access	
  
 collection
                                                       exceptions	
  
                                                    Simple semantics, and fast
                                      OptumSoft, Inc. Proprietary and                        7	
  
                                      Confidential
SysDB:	
  a	
  hierarchical	
  in-­‐memory	
  
            object	
  database	
  
  Stores	
  state	
  (ideally	
  no	
  logic)	
  
     Minimizes	
  risk	
  of	
  program	
  
     logic	
  bugs,	
  hence	
  reliable	
  
                                                        Agents
  Concise	
  specification	
  of	
  user-­‐
  defined	
  types	
  
  TACC	
  compiler	
  automatically	
  
  generates	
  all	
  required	
  code	
  
  for	
  remote	
  access	
  
                                                             SysDB
  Agents	
  receive	
  automatic	
  
  notification	
  when	
  values	
  
  change	
  
                                        OptumSoft, Inc. Proprietary and   8	
  
                                        Confidential
Distributed,	
  hierarchical	
  name	
  
              space	
  

  SysDB	
  defines	
  and	
  exports	
  an	
  hierarchical	
  name	
  space	
  
  (similar	
  to	
  a	
  distributed	
  file	
  system)	
  
  Remote	
  agents	
  can	
  “mount”	
  remote	
  directories	
  into	
  a	
  
  local	
  namespace	
  
  Each	
  object	
  is	
  instantiated	
  into	
  a	
  directory,	
  state	
  is	
  
  made	
  available	
  remotely	
  via	
  proxy	
  objects	
  
  Updates	
  	
  propagate	
  asynchronously,	
  notifications	
  are	
  
  delivered	
  on	
  changes	
  
                       Simple, powerful, proven way to
                       provide large, structured name space
                               OptumSoft, Inc. Proprietary and                         9	
  
                               Confidential
Fault-­‐tolerance	
  is	
  built	
  in	
  

  When	
  an	
  agent	
  restarts,	
  it	
  
  recovers	
  its	
  state	
  from	
  
  SysDB	
  
                                                       A1	
         A2	
     A3	
          A4	
  
  Agents	
  implement	
  
  invariants,	
  therefore	
  can	
  
  be	
  restarted	
  at	
  any	
  time,	
  
  on	
  any	
  server	
  
  Any	
  number	
  of	
  backup	
                               SP	
              SB	
  
  SysDBs	
  are	
  supported	
  

                                               Fast	
  recovery	
  for	
  high	
  availability	
  

                                                                                                    10	
  
Example:	
  Location	
  Service	
  as	
  
 customized	
  key-­‐value	
  store	
  

  Application	
  needs	
  to	
  track	
  real-­‐time	
  location	
  of	
  user	
  
  User	
  allowed	
  in	
  only	
  one	
  location	
  at	
  a	
  time	
  
  Three	
  operations:	
  
     ENTER	
  <user	
  id>	
  <session	
  id>	
  <location	
  id>	
  
     LEAVE	
  <user	
  id>	
  
     QUERY	
  <user	
  id>	
  
  Throughput	
  >	
  10,000	
  requests/sec,	
  latency	
  <	
  1	
  ms	
  

                       High throughput, low latency required
                                 OptumSoft, Inc. Proprietary and                     11
                                                                                      	
  
                                 Confidential
Location	
  Service	
  Overview	
  
          Load	
  
         balancer	
  
           Get	
  
GS	
  
         location	
     LR	
  
                                               HTTP	
  access	
  to	
  service	
  
GS	
  
                                               Application	
  (GS)	
  contacts	
  
         Leave	
                               any	
  LR	
  server	
  via	
  load	
  
                        LR	
                   balancer	
  
GS	
  
                                               LR	
  servers	
  replicated	
  for	
  
GS	
  
                        LR	
                   scalability	
  and	
  for	
  fault	
  
          Enter	
                              tolerance	
  
GS	
  

                        LR	
     Challenge: ensure responses from
GS	
       Enter	
               multiple LR servers are handled
                                 correctly
                                 OptumSoft, Inc. Proprietary and                        12	
  
                                 Confidential
Key-­‐value	
  store	
  tracks	
  location	
  
          for	
  each	
  user	
  
              Load	
                                                                Key-­‐value	
  
             balancer	
                                                               store	
  
    GS	
  
                              LR	
                                                                    Shard	
  
    GS	
                                                                                               A-­‐J	
  

                              LR	
   Smith,1
                                           	
  
    GS	
                                                  Has	
  to	
  be	
  	
  
                 Enter	
                                   atomic	
                                   Shard	
  
                Smith,1	
                                                                              K-­‐R	
  
    GS	
                                           get(),	
  
                              LR	
  
                                                   put()	
  
    GS	
  
                                                                                                      Shard	
  
              Enter	
  	
     LR	
   Smith,2	
              get(),	
                   Smith	
         S-­‐Z	
  
    GS	
     Smith,2	
                                      put()	
  

                                        OptumSoft, Inc. Proprietary and                                            13	
  
                                        Confidential
TACC	
  allows	
  easy	
  customization	
  
 of	
  key-­‐value	
  update	
  semantics	
  

   Each	
  partition	
  stores	
  a	
  unique	
  subset	
  of	
  the	
  user	
  state	
  
   We	
  directly	
  implement	
  ENTER,	
  LEAVE,	
  and	
  QUERY	
  
   semantics,	
  using	
  a	
  TACC	
  Constrainer	
  
   No	
  locking	
  or	
  inter-­‐agent	
  synchronization	
  required	
  
   Requests	
  and	
  responses	
  sent	
  asynchronously	
  
   High	
  performance:	
  there	
  is	
  no	
  waiting	
  or	
  blocking	
  
Specializing the key-value store semantics
simplifies the application and improves performance
                                  OptumSoft, Inc. Proprietary and                           14	
  
                                  Confidential
Single-­‐writer	
  collections:	
  no	
  need	
  
              for	
  synchronization	
  
         R
         S	
      R
LR	
  
         R        S	
  
         S	
      R            Shard	
         R       Request	
  Collection	
  
                                A-­‐J	
  
                  S	
                                  Response	
  Collection	
  
                                               S	
  
         R        R
         S	
      S	
  
LR	
  
         R
         S	
                          R
                                      S	
  
         R                            R                Shard	
  
         S	
                          S	
               K-­‐R	
  
LR	
  
         R                            R
         S	
                          S	
  

                          OptumSoft, Inc. Proprietary and                           15	
  
                          Confidential
The	
  Serializer	
  Constrainer	
  

                                        Logic	
  

            Notify	
                                                                                     Update user
                                                    Write result                                         status



        Request	
  Collection	
                         Response	
  Collection	
  
A	
            Enter	
  U1,	
  R5	
                 A	
               OK	
               Status	
  Collection	
  

K	
            Enter	
  U1,	
  R5	
                  K	
      NOT	
  ALLOWED	
             U1
                                                                                            	
          R5	
  

D	
            Enter	
  U8,	
  R9	
                 D	
               OK	
                 U8	
         R9	
  



                                                                                          Really simple!
                                                             OptumSoft, Inc. Proprietary and                        16	
  
                                                             Confidential
Details	
  of	
  Constrainer	
  
            implementation	
  

  Code	
  for	
  the	
  Serializer	
  constrainer	
  defines	
  three	
  
  collections:	
  	
  
     Input	
  collection:	
  requests	
  
     Output	
  collections:	
  responses	
  and	
  user	
  status	
  
  A	
  dependency	
  constraint	
  causes	
  imperative	
  code	
  to	
  be	
  
  executed	
  when	
  a	
  new	
  request	
  arrives	
  from	
  LR	
  server	
  
  	
  The	
  imperative	
  code	
  in	
  the	
  constrainer	
  implements	
  
  the	
  application	
  specific	
  semantics	
  
This code is a minor tweak on put() implementation
                               OptumSoft, Inc. Proprietary and                     17	
  
                               Confidential
Constraints,	
  strong	
  typing	
  
improves	
  event	
  handling	
  code	
  	
  

  Constraint	
  handling	
  code	
  automatically	
  inserted	
  by	
  
  compiler	
  
  No	
  need	
  to	
  manually	
  maintain	
  invariants	
  in	
  many	
  call	
  sites	
  
  User-­‐defined	
  types	
  organize	
  constraint	
  handling	
  code	
  and	
  
  protect	
  against	
  mistakes	
  
  TACC	
  coroutine	
  further	
  simplifies	
  event	
  handling	
  

          TACC changes event-handling spaghetti into
          well-structured, type-safe code
                                OptumSoft, Inc. Proprietary and                        18	
  
                                Confidential
Instrumentation	
  and	
  
              Measurements	
  

  Stress	
  Agent	
  and	
  SysDB	
  instrumented	
  to	
  collect	
  
  timestamps	
  (stored	
  in	
  memory,	
  I/O	
  after	
  test)	
  
  tcpdump	
  run	
  on	
  Stress	
  Agent	
  and	
  SysDB	
  servers	
  
  Correlate	
  timestamps	
  with	
  tcpdump	
  




                              OptumSoft, Inc. Proprietary and              19	
  
                              Confidential
Low	
  latency	
  pitfalls	
  to	
  avoid	
  


  Network	
  and	
  TCP	
  behavior	
  
     Many	
  TCP	
  settings	
  have	
  a	
  dramatic	
  and	
  non-­‐linear	
  
     performance	
  impact	
  
  Memory	
  management	
  
     Memory	
  allocation/deallocation	
  
     Avoid	
  garbage	
  collection	
  



                                             “The devil is in the details”
                                 OptumSoft, Inc. Proprietary and                   20	
  
                                 Confidential
Zero-­‐load	
  Latency	
  (μs)	
  

End-­‐to-­‐end	
       Time	
     Latency	
  
Request	
              0	
  
created	
  1	
  
Request	
              48	
       48	
                SysDB	
                       Time	
     Latency	
  
packet	
  2	
                                         Receive	
  request	
  3	
     0.0	
  
Response	
             248	
      200	
               Notification	
  4	
            42.3	
     42.3	
  
packet	
  7	
  
                                                      Response	
                    75.1	
     32.8	
  
Notification	
  8	
     288	
      40	
                enqueued	
  5	
  
                                                      Response	
  packet	
  6	
   108.5	
      33.4	
  

                                            Latencies are low and predictable
                                            OptumSoft, Inc. Proprietary and                               21
                                                                                                           	
  
                                            Confidential
Latency,	
  throughput	
  vs	
  SysDBs	
  




High scalability under               Latency converges to
strict latency bound                 zero-load latency
                     OptumSoft, Inc. Proprietary and   22	
  
                     Confidential
Summary	
  


  Tacc	
  enables	
  developers	
  to	
  efficiently	
  create	
  
  predictably	
  high	
  performance,	
  scalable,	
  fault-­‐tolerant	
  
  distributed	
  applications	
  
  Eliminates	
  synchronization	
  and	
  locking	
  bugs	
  
  Fewer	
  lines	
  of	
  code	
  
     Faster	
  to	
  develop,	
  shorter	
  time	
  to	
  market	
  
     Easier	
  to	
  maintain	
  
     Fewer	
  bugs	
  


                                                                             23
Contact	
  me	
  for	
  more	
  information	
  about	
  TACC	
  and	
  
                           OptumSoft!	
  


goosen@optumsoft.com	
  




                         OptumSoft, Inc. Proprietary and                   24	
  
                         Confidential

Contenu connexe

Tendances

Denial of Service in Software Defined Netoworks
Denial of Service in Software Defined NetoworksDenial of Service in Software Defined Netoworks
Denial of Service in Software Defined Netoworks
Mohammad Faraji
 
Network Virtualization in Windows Server 2012
Network Virtualization in Windows Server 2012Network Virtualization in Windows Server 2012
Network Virtualization in Windows Server 2012
Lai Yoong Seng
 
Choosing Your Windows Azure Platform Strategy
Choosing Your Windows Azure Platform StrategyChoosing Your Windows Azure Platform Strategy
Choosing Your Windows Azure Platform Strategy
drmarcustillett
 
Scalable Architecture on Amazon AWS Cloud - Indicthreads cloud computing conf...
Scalable Architecture on Amazon AWS Cloud - Indicthreads cloud computing conf...Scalable Architecture on Amazon AWS Cloud - Indicthreads cloud computing conf...
Scalable Architecture on Amazon AWS Cloud - Indicthreads cloud computing conf...
IndicThreads
 

Tendances (20)

"Right Availability in RAC environment"
"Right Availability in RAC environment""Right Availability in RAC environment"
"Right Availability in RAC environment"
 
Equalizer on demand
Equalizer on demandEqualizer on demand
Equalizer on demand
 
Implement Checkpointing for Android
Implement Checkpointing for AndroidImplement Checkpointing for Android
Implement Checkpointing for Android
 
Denial of Service in Software Defined Netoworks
Denial of Service in Software Defined NetoworksDenial of Service in Software Defined Netoworks
Denial of Service in Software Defined Netoworks
 
Network Virtualization in Windows Server 2012
Network Virtualization in Windows Server 2012Network Virtualization in Windows Server 2012
Network Virtualization in Windows Server 2012
 
Azure Cloud Patterns
Azure Cloud PatternsAzure Cloud Patterns
Azure Cloud Patterns
 
[NetPonto] Arquitectura dos Serviços da plataforma Windows Azure
[NetPonto] Arquitectura dos Serviços da plataforma Windows Azure[NetPonto] Arquitectura dos Serviços da plataforma Windows Azure
[NetPonto] Arquitectura dos Serviços da plataforma Windows Azure
 
Arquitectura dos Serviços da plataforma Windows Azure
Arquitectura dos Serviços da plataforma Windows AzureArquitectura dos Serviços da plataforma Windows Azure
Arquitectura dos Serviços da plataforma Windows Azure
 
#lspe: Dynamic Scaling
#lspe: Dynamic Scaling #lspe: Dynamic Scaling
#lspe: Dynamic Scaling
 
Runner sv q307
Runner sv q307Runner sv q307
Runner sv q307
 
Lync 2010 High Availability
Lync 2010 High AvailabilityLync 2010 High Availability
Lync 2010 High Availability
 
Choosing Your Windows Azure Platform Strategy
Choosing Your Windows Azure Platform StrategyChoosing Your Windows Azure Platform Strategy
Choosing Your Windows Azure Platform Strategy
 
Connected Applications using WF and WCF
Connected Applications using WF and WCFConnected Applications using WF and WCF
Connected Applications using WF and WCF
 
Scalable Architecture on Amazon AWS Cloud - Indicthreads cloud computing conf...
Scalable Architecture on Amazon AWS Cloud - Indicthreads cloud computing conf...Scalable Architecture on Amazon AWS Cloud - Indicthreads cloud computing conf...
Scalable Architecture on Amazon AWS Cloud - Indicthreads cloud computing conf...
 
User Group Bi
User Group BiUser Group Bi
User Group Bi
 
Lync Server 2010: High Availability [I3004]
Lync Server 2010: High Availability [I3004] Lync Server 2010: High Availability [I3004]
Lync Server 2010: High Availability [I3004]
 
Seattle Scalability - GigaSpaces / Cassandra
Seattle Scalability - GigaSpaces / CassandraSeattle Scalability - GigaSpaces / Cassandra
Seattle Scalability - GigaSpaces / Cassandra
 
Sql Server 2012 HA and DR -- SQL Saturday Richmond
Sql Server 2012 HA and DR -- SQL Saturday RichmondSql Server 2012 HA and DR -- SQL Saturday Richmond
Sql Server 2012 HA and DR -- SQL Saturday Richmond
 
Brief about Windows Azure Platform
Brief about Windows Azure Platform Brief about Windows Azure Platform
Brief about Windows Azure Platform
 
Innovations in Grid Computing with Oracle Coherence
Innovations in Grid Computing with Oracle CoherenceInnovations in Grid Computing with Oracle Coherence
Innovations in Grid Computing with Oracle Coherence
 

Similaire à SDEC2011 Going by TACC

The SPOSAD Architectural Style for Multi-tenant Software Applications
The SPOSAD Architectural Style for Multi-tenant Software ApplicationsThe SPOSAD Architectural Style for Multi-tenant Software Applications
The SPOSAD Architectural Style for Multi-tenant Software Applications
Heiko Koziolek
 
AWS Summit 2011: Architecting in the cloud
AWS Summit 2011: Architecting in the cloudAWS Summit 2011: Architecting in the cloud
AWS Summit 2011: Architecting in the cloud
Amazon Web Services
 
Fra enkel J2SE til Grid computing med GigaSpaces XAP
Fra enkel J2SE til Grid computing med GigaSpaces XAPFra enkel J2SE til Grid computing med GigaSpaces XAP
Fra enkel J2SE til Grid computing med GigaSpaces XAP
mudnaes
 
Migrating Hundreds of Legacy Applications to Kubernetes - The Good, the Bad, ...
Migrating Hundreds of Legacy Applications to Kubernetes - The Good, the Bad, ...Migrating Hundreds of Legacy Applications to Kubernetes - The Good, the Bad, ...
Migrating Hundreds of Legacy Applications to Kubernetes - The Good, the Bad, ...
QAware GmbH
 

Similaire à SDEC2011 Going by TACC (20)

Cloudian_Cassandra Summit 2012
Cloudian_Cassandra Summit 2012Cloudian_Cassandra Summit 2012
Cloudian_Cassandra Summit 2012
 
CloudStack Best Practice in PPTV
CloudStack Best Practice in PPTVCloudStack Best Practice in PPTV
CloudStack Best Practice in PPTV
 
Amazon Kinesis
Amazon KinesisAmazon Kinesis
Amazon Kinesis
 
Azure and cloud design patterns
Azure and cloud design patternsAzure and cloud design patterns
Azure and cloud design patterns
 
StreamBase - Embedded Erjang - Erlang User Group London - 20th April 2011
StreamBase - Embedded Erjang - Erlang User Group London - 20th April 2011StreamBase - Embedded Erjang - Erlang User Group London - 20th April 2011
StreamBase - Embedded Erjang - Erlang User Group London - 20th April 2011
 
The SPOSAD Architectural Style for Multi-tenant Software Applications
The SPOSAD Architectural Style for Multi-tenant Software ApplicationsThe SPOSAD Architectural Style for Multi-tenant Software Applications
The SPOSAD Architectural Style for Multi-tenant Software Applications
 
AWS Summit 2011: Architecting in the cloud
AWS Summit 2011: Architecting in the cloudAWS Summit 2011: Architecting in the cloud
AWS Summit 2011: Architecting in the cloud
 
Understanding Database Options
Understanding Database OptionsUnderstanding Database Options
Understanding Database Options
 
Fra enkel J2SE til Grid computing med GigaSpaces XAP
Fra enkel J2SE til Grid computing med GigaSpaces XAPFra enkel J2SE til Grid computing med GigaSpaces XAP
Fra enkel J2SE til Grid computing med GigaSpaces XAP
 
Complex Er[jl]ang Processing with StreamBase
Complex Er[jl]ang Processing with StreamBaseComplex Er[jl]ang Processing with StreamBase
Complex Er[jl]ang Processing with StreamBase
 
The Good, the Bad and the Ugly of Migrating Hundreds of Legacy Applications ...
 The Good, the Bad and the Ugly of Migrating Hundreds of Legacy Applications ... The Good, the Bad and the Ugly of Migrating Hundreds of Legacy Applications ...
The Good, the Bad and the Ugly of Migrating Hundreds of Legacy Applications ...
 
Migrating Hundreds of Legacy Applications to Kubernetes - The Good, the Bad, ...
Migrating Hundreds of Legacy Applications to Kubernetes - The Good, the Bad, ...Migrating Hundreds of Legacy Applications to Kubernetes - The Good, the Bad, ...
Migrating Hundreds of Legacy Applications to Kubernetes - The Good, the Bad, ...
 
Times Ten in-memory database when time counts - Laszlo Ludas
Times Ten in-memory database when time counts - Laszlo LudasTimes Ten in-memory database when time counts - Laszlo Ludas
Times Ten in-memory database when time counts - Laszlo Ludas
 
게임을 위한 Cloud Native on AWS (김일호 솔루션즈 아키텍트, AWS) :: Gaming on AWS 2018
게임을 위한 Cloud Native on AWS (김일호 솔루션즈 아키텍트, AWS) :: Gaming on AWS 2018게임을 위한 Cloud Native on AWS (김일호 솔루션즈 아키텍트, AWS) :: Gaming on AWS 2018
게임을 위한 Cloud Native on AWS (김일호 솔루션즈 아키텍트, AWS) :: Gaming on AWS 2018
 
SQL and NoSQL in SQL Server
SQL and NoSQL in SQL ServerSQL and NoSQL in SQL Server
SQL and NoSQL in SQL Server
 
Towards an Architectural Style for Multi-tenant Software Applications
Towards an Architectural Style for Multi-tenant Software ApplicationsTowards an Architectural Style for Multi-tenant Software Applications
Towards an Architectural Style for Multi-tenant Software Applications
 
High Performance Databases
High Performance DatabasesHigh Performance Databases
High Performance Databases
 
A Big Data Lake Based on Spark for BBVA Bank-(Oscar Mendez, STRATIO)
A Big Data Lake Based on Spark for BBVA Bank-(Oscar Mendez, STRATIO)A Big Data Lake Based on Spark for BBVA Bank-(Oscar Mendez, STRATIO)
A Big Data Lake Based on Spark for BBVA Bank-(Oscar Mendez, STRATIO)
 
Software Architecture Definition for On-demand Cloud Provisioning
Software Architecture Definition for On-demand Cloud ProvisioningSoftware Architecture Definition for On-demand Cloud Provisioning
Software Architecture Definition for On-demand Cloud Provisioning
 
SSD Performance Benchmarking
SSD Performance BenchmarkingSSD Performance Benchmarking
SSD Performance Benchmarking
 

Plus de Korea Sdec

SDEC2011 Big engineer vs small entreprenuer
SDEC2011 Big engineer vs small entreprenuerSDEC2011 Big engineer vs small entreprenuer
SDEC2011 Big engineer vs small entreprenuer
Korea Sdec
 
SDEC2011 Introducing Hadoop
SDEC2011 Introducing HadoopSDEC2011 Introducing Hadoop
SDEC2011 Introducing Hadoop
Korea Sdec
 
Sdec2011 shashank-introducing hadoop
Sdec2011 shashank-introducing hadoopSdec2011 shashank-introducing hadoop
Sdec2011 shashank-introducing hadoop
Korea Sdec
 
SDEC2011 NoSQL Data modelling
SDEC2011 NoSQL Data modellingSDEC2011 NoSQL Data modelling
SDEC2011 NoSQL Data modelling
Korea Sdec
 
SDEC2011 Essentials of Pig
SDEC2011 Essentials of PigSDEC2011 Essentials of Pig
SDEC2011 Essentials of Pig
Korea Sdec
 
SDEC2011 Essentials of Mahout
SDEC2011 Essentials of MahoutSDEC2011 Essentials of Mahout
SDEC2011 Essentials of Mahout
Korea Sdec
 
SDEC2011 Essentials of Hive
SDEC2011 Essentials of HiveSDEC2011 Essentials of Hive
SDEC2011 Essentials of Hive
Korea Sdec
 
SDEC2011 NoSQL concepts and models
SDEC2011 NoSQL concepts and modelsSDEC2011 NoSQL concepts and models
SDEC2011 NoSQL concepts and models
Korea Sdec
 
Sdec2011 Introducing Hadoop
Sdec2011 Introducing HadoopSdec2011 Introducing Hadoop
Sdec2011 Introducing Hadoop
Korea Sdec
 
SDEC2011 Replacing legacy Telco DB/DW to Hadoop and Hive
SDEC2011 Replacing legacy Telco DB/DW to Hadoop and HiveSDEC2011 Replacing legacy Telco DB/DW to Hadoop and Hive
SDEC2011 Replacing legacy Telco DB/DW to Hadoop and Hive
Korea Sdec
 

Plus de Korea Sdec (16)

SDEC2011 Big engineer vs small entreprenuer
SDEC2011 Big engineer vs small entreprenuerSDEC2011 Big engineer vs small entreprenuer
SDEC2011 Big engineer vs small entreprenuer
 
SDEC2011 Implementing me2day friend suggestion
SDEC2011 Implementing me2day friend suggestionSDEC2011 Implementing me2day friend suggestion
SDEC2011 Implementing me2day friend suggestion
 
SDEC2011 Introducing Hadoop
SDEC2011 Introducing HadoopSDEC2011 Introducing Hadoop
SDEC2011 Introducing Hadoop
 
Sdec2011 shashank-introducing hadoop
Sdec2011 shashank-introducing hadoopSdec2011 shashank-introducing hadoop
Sdec2011 shashank-introducing hadoop
 
SDEC2011 NoSQL Data modelling
SDEC2011 NoSQL Data modellingSDEC2011 NoSQL Data modelling
SDEC2011 NoSQL Data modelling
 
SDEC2011 Essentials of Pig
SDEC2011 Essentials of PigSDEC2011 Essentials of Pig
SDEC2011 Essentials of Pig
 
SDEC2011 Essentials of Mahout
SDEC2011 Essentials of MahoutSDEC2011 Essentials of Mahout
SDEC2011 Essentials of Mahout
 
SDEC2011 Essentials of Hive
SDEC2011 Essentials of HiveSDEC2011 Essentials of Hive
SDEC2011 Essentials of Hive
 
SDEC2011 NoSQL concepts and models
SDEC2011 NoSQL concepts and modelsSDEC2011 NoSQL concepts and models
SDEC2011 NoSQL concepts and models
 
Sdec2011 Introducing Hadoop
Sdec2011 Introducing HadoopSdec2011 Introducing Hadoop
Sdec2011 Introducing Hadoop
 
SDEC2011 Replacing legacy Telco DB/DW to Hadoop and Hive
SDEC2011 Replacing legacy Telco DB/DW to Hadoop and HiveSDEC2011 Replacing legacy Telco DB/DW to Hadoop and Hive
SDEC2011 Replacing legacy Telco DB/DW to Hadoop and Hive
 
SDEC2011 Rapidant
SDEC2011 RapidantSDEC2011 Rapidant
SDEC2011 Rapidant
 
SDEC2011 Mahout - the what, the how and the why
SDEC2011 Mahout - the what, the how and the whySDEC2011 Mahout - the what, the how and the why
SDEC2011 Mahout - the what, the how and the why
 
SDEC2011 Glory-FS development & Experiences
SDEC2011 Glory-FS development & ExperiencesSDEC2011 Glory-FS development & Experiences
SDEC2011 Glory-FS development & Experiences
 
SDEC2011 Using Couchbase for social game scaling and speed
SDEC2011 Using Couchbase for social game scaling and speedSDEC2011 Using Couchbase for social game scaling and speed
SDEC2011 Using Couchbase for social game scaling and speed
 
SDEC2011 Arcus NHN memcached cloud
SDEC2011 Arcus NHN memcached cloudSDEC2011 Arcus NHN memcached cloud
SDEC2011 Arcus NHN memcached cloud
 

Dernier

+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...
+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...
+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...
?#DUbAI#??##{{(☎️+971_581248768%)**%*]'#abortion pills for sale in dubai@
 

Dernier (20)

Repurposing LNG terminals for Hydrogen Ammonia: Feasibility and Cost Saving
Repurposing LNG terminals for Hydrogen Ammonia: Feasibility and Cost SavingRepurposing LNG terminals for Hydrogen Ammonia: Feasibility and Cost Saving
Repurposing LNG terminals for Hydrogen Ammonia: Feasibility and Cost Saving
 
Web Form Automation for Bonterra Impact Management (fka Social Solutions Apri...
Web Form Automation for Bonterra Impact Management (fka Social Solutions Apri...Web Form Automation for Bonterra Impact Management (fka Social Solutions Apri...
Web Form Automation for Bonterra Impact Management (fka Social Solutions Apri...
 
Boost Fertility New Invention Ups Success Rates.pdf
Boost Fertility New Invention Ups Success Rates.pdfBoost Fertility New Invention Ups Success Rates.pdf
Boost Fertility New Invention Ups Success Rates.pdf
 
Apidays New York 2024 - The Good, the Bad and the Governed by David O'Neill, ...
Apidays New York 2024 - The Good, the Bad and the Governed by David O'Neill, ...Apidays New York 2024 - The Good, the Bad and the Governed by David O'Neill, ...
Apidays New York 2024 - The Good, the Bad and the Governed by David O'Neill, ...
 
Automating Google Workspace (GWS) & more with Apps Script
Automating Google Workspace (GWS) & more with Apps ScriptAutomating Google Workspace (GWS) & more with Apps Script
Automating Google Workspace (GWS) & more with Apps Script
 
EMPOWERMENT TECHNOLOGY GRADE 11 QUARTER 2 REVIEWER
EMPOWERMENT TECHNOLOGY GRADE 11 QUARTER 2 REVIEWEREMPOWERMENT TECHNOLOGY GRADE 11 QUARTER 2 REVIEWER
EMPOWERMENT TECHNOLOGY GRADE 11 QUARTER 2 REVIEWER
 
Exploring the Future Potential of AI-Enabled Smartphone Processors
Exploring the Future Potential of AI-Enabled Smartphone ProcessorsExploring the Future Potential of AI-Enabled Smartphone Processors
Exploring the Future Potential of AI-Enabled Smartphone Processors
 
Apidays New York 2024 - The value of a flexible API Management solution for O...
Apidays New York 2024 - The value of a flexible API Management solution for O...Apidays New York 2024 - The value of a flexible API Management solution for O...
Apidays New York 2024 - The value of a flexible API Management solution for O...
 
+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...
+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...
+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...
 
Manulife - Insurer Transformation Award 2024
Manulife - Insurer Transformation Award 2024Manulife - Insurer Transformation Award 2024
Manulife - Insurer Transformation Award 2024
 
MS Copilot expands with MS Graph connectors
MS Copilot expands with MS Graph connectorsMS Copilot expands with MS Graph connectors
MS Copilot expands with MS Graph connectors
 
FWD Group - Insurer Innovation Award 2024
FWD Group - Insurer Innovation Award 2024FWD Group - Insurer Innovation Award 2024
FWD Group - Insurer Innovation Award 2024
 
MINDCTI Revenue Release Quarter One 2024
MINDCTI Revenue Release Quarter One 2024MINDCTI Revenue Release Quarter One 2024
MINDCTI Revenue Release Quarter One 2024
 
Powerful Google developer tools for immediate impact! (2023-24 C)
Powerful Google developer tools for immediate impact! (2023-24 C)Powerful Google developer tools for immediate impact! (2023-24 C)
Powerful Google developer tools for immediate impact! (2023-24 C)
 
DBX First Quarter 2024 Investor Presentation
DBX First Quarter 2024 Investor PresentationDBX First Quarter 2024 Investor Presentation
DBX First Quarter 2024 Investor Presentation
 
TrustArc Webinar - Stay Ahead of US State Data Privacy Law Developments
TrustArc Webinar - Stay Ahead of US State Data Privacy Law DevelopmentsTrustArc Webinar - Stay Ahead of US State Data Privacy Law Developments
TrustArc Webinar - Stay Ahead of US State Data Privacy Law Developments
 
Strategies for Landing an Oracle DBA Job as a Fresher
Strategies for Landing an Oracle DBA Job as a FresherStrategies for Landing an Oracle DBA Job as a Fresher
Strategies for Landing an Oracle DBA Job as a Fresher
 
Corporate and higher education May webinar.pptx
Corporate and higher education May webinar.pptxCorporate and higher education May webinar.pptx
Corporate and higher education May webinar.pptx
 
Real Time Object Detection Using Open CV
Real Time Object Detection Using Open CVReal Time Object Detection Using Open CV
Real Time Object Detection Using Open CV
 
TrustArc Webinar - Unlock the Power of AI-Driven Data Discovery
TrustArc Webinar - Unlock the Power of AI-Driven Data DiscoveryTrustArc Webinar - Unlock the Power of AI-Driven Data Discovery
TrustArc Webinar - Unlock the Power of AI-Driven Data Discovery
 

SDEC2011 Going by TACC

  • 1. Going  by  TACC:   Beyond  Key-­‐Value  to  Fault-­‐Tolerant   Stores  with  Easily  Customizable   Semantics   Henk  Goosen,  CEO   goosen@optumsoft.com  
  • 2. Key-­‐value  stores  rule  the  Web     Many  applications  only  need  primary  key  data  access     Examples:  catalogs,  shopping  carts,  web  session  state     No  need  for  the  complexity,  performance  overhead,   and  lack  of  scalability  of  a  full  database     Hence:  Key-­‐value  stores  are  everywhere     Dynamo,  CouchDB,  Cassandra,  Project  Voldemort,  Riak,   Redis,  memcached,  MongoDB,  …   Improving key-value stores is important OptumSoft, Inc. Proprietary and 2   Confidential
  • 3. Key-­‐value  stores  in  practice     Developing  a  key-­‐value  store  from  scratch  using   conventional  languages  is  expensive:     scalability,  performance,  and  fault  tolerance     Conventional  solution:  use  existing  key-­‐value  store     Layer  on  get()  and  put()  semantics     Mismatches  between  application  requirements  and   library:  either  accept  or  extensively  modify  library  code     Applications are more complex, performance suffers OptumSoft, Inc. Proprietary and 3   Confidential
  • 4. TACC  provides  a  different  model     Use  a  very  high-­‐level  language  to  specify  the  key-­‐value   store     Then  customize  the  store,  applying  application-­‐specific   semantics     Benefits:     Simplifies  the  application  business  logic     Improves  the  performance  of  both  store  and  application   TACC model is better! OptumSoft, Inc. Proprietary and 4   Confidential
  • 5. TACC  is  an  object-­‐oriented,   strongly  typed  language     User-­‐defined  type:  a  list  of  attributes  (nouns)     Read  or  write  attributes  (there  are  no  methods/verbs)     Logic  primarily  implemented  via  constraints     imperative  code  is  also  supported     Compact  code     First  class  high  level  data  types  (eg,  queues,  hash  tables)     Several  design  patterns  directly  supported  in  language   (eg  observer  pattern)   Compact code  fewer bugs, quicker to market 5  
  • 6. TACC:  efficient  development  of   distributed  systems     Reduce  development  time  by  a  factor  of  2x  to  3x     Reduce  lines  of  code  by  10x  or  more     Eliminate  most  synchronization  and  concurrency  bugs     High,  predictable  performance  using  optimized  code   generation     Fault-­‐Tolerance  built  into  the  model,  and  easy  to   implement   TACC is a general purpose language, focused on distributed systems 6  
  • 7. Stateful  remote  proxy  objects   LR  1   LR  2   Agents 1     Proxy:  local  copy  of  data   1     Writes  are  asynchronously   object added copied  to  SysDB   to collection   SysDB  changes  are  copied   to  “interested”  agents     R/W  access  is  local,  fast   SysDB 1     No  remote  access   collection exceptions   Simple semantics, and fast OptumSoft, Inc. Proprietary and 7   Confidential
  • 8. SysDB:  a  hierarchical  in-­‐memory   object  database     Stores  state  (ideally  no  logic)     Minimizes  risk  of  program   logic  bugs,  hence  reliable   Agents   Concise  specification  of  user-­‐ defined  types     TACC  compiler  automatically   generates  all  required  code   for  remote  access   SysDB   Agents  receive  automatic   notification  when  values   change   OptumSoft, Inc. Proprietary and 8   Confidential
  • 9. Distributed,  hierarchical  name   space     SysDB  defines  and  exports  an  hierarchical  name  space   (similar  to  a  distributed  file  system)     Remote  agents  can  “mount”  remote  directories  into  a   local  namespace     Each  object  is  instantiated  into  a  directory,  state  is   made  available  remotely  via  proxy  objects     Updates    propagate  asynchronously,  notifications  are   delivered  on  changes   Simple, powerful, proven way to provide large, structured name space OptumSoft, Inc. Proprietary and 9   Confidential
  • 10. Fault-­‐tolerance  is  built  in     When  an  agent  restarts,  it   recovers  its  state  from   SysDB   A1   A2   A3   A4     Agents  implement   invariants,  therefore  can   be  restarted  at  any  time,   on  any  server     Any  number  of  backup   SP   SB   SysDBs  are  supported   Fast  recovery  for  high  availability   10  
  • 11. Example:  Location  Service  as   customized  key-­‐value  store     Application  needs  to  track  real-­‐time  location  of  user     User  allowed  in  only  one  location  at  a  time     Three  operations:     ENTER  <user  id>  <session  id>  <location  id>     LEAVE  <user  id>     QUERY  <user  id>     Throughput  >  10,000  requests/sec,  latency  <  1  ms   High throughput, low latency required OptumSoft, Inc. Proprietary and 11   Confidential
  • 12. Location  Service  Overview   Load   balancer   Get   GS   location   LR     HTTP  access  to  service   GS     Application  (GS)  contacts   Leave   any  LR  server  via  load   LR   balancer   GS     LR  servers  replicated  for   GS   LR   scalability  and  for  fault   Enter   tolerance   GS   LR   Challenge: ensure responses from GS   Enter   multiple LR servers are handled correctly OptumSoft, Inc. Proprietary and 12   Confidential
  • 13. Key-­‐value  store  tracks  location   for  each  user   Load   Key-­‐value   balancer   store   GS   LR   Shard   GS   A-­‐J   LR   Smith,1   GS   Has  to  be     Enter   atomic   Shard   Smith,1   K-­‐R   GS   get(),   LR   put()   GS   Shard   Enter     LR   Smith,2   get(),   Smith   S-­‐Z   GS   Smith,2   put()   OptumSoft, Inc. Proprietary and 13   Confidential
  • 14. TACC  allows  easy  customization   of  key-­‐value  update  semantics     Each  partition  stores  a  unique  subset  of  the  user  state     We  directly  implement  ENTER,  LEAVE,  and  QUERY   semantics,  using  a  TACC  Constrainer     No  locking  or  inter-­‐agent  synchronization  required     Requests  and  responses  sent  asynchronously     High  performance:  there  is  no  waiting  or  blocking   Specializing the key-value store semantics simplifies the application and improves performance OptumSoft, Inc. Proprietary and 14   Confidential
  • 15. Single-­‐writer  collections:  no  need   for  synchronization   R S   R LR   R S   S   R Shard   R Request  Collection   A-­‐J   S   Response  Collection   S   R R S   S   LR   R S   R S   R R Shard   S   S   K-­‐R   LR   R R S   S   OptumSoft, Inc. Proprietary and 15   Confidential
  • 16. The  Serializer  Constrainer   Logic   Notify   Update user Write result status Request  Collection   Response  Collection   A   Enter  U1,  R5   A   OK   Status  Collection   K   Enter  U1,  R5   K   NOT  ALLOWED   U1   R5   D   Enter  U8,  R9   D   OK   U8   R9   Really simple! OptumSoft, Inc. Proprietary and 16   Confidential
  • 17. Details  of  Constrainer   implementation     Code  for  the  Serializer  constrainer  defines  three   collections:       Input  collection:  requests     Output  collections:  responses  and  user  status     A  dependency  constraint  causes  imperative  code  to  be   executed  when  a  new  request  arrives  from  LR  server      The  imperative  code  in  the  constrainer  implements   the  application  specific  semantics   This code is a minor tweak on put() implementation OptumSoft, Inc. Proprietary and 17   Confidential
  • 18. Constraints,  strong  typing   improves  event  handling  code       Constraint  handling  code  automatically  inserted  by   compiler     No  need  to  manually  maintain  invariants  in  many  call  sites     User-­‐defined  types  organize  constraint  handling  code  and   protect  against  mistakes     TACC  coroutine  further  simplifies  event  handling   TACC changes event-handling spaghetti into well-structured, type-safe code OptumSoft, Inc. Proprietary and 18   Confidential
  • 19. Instrumentation  and   Measurements     Stress  Agent  and  SysDB  instrumented  to  collect   timestamps  (stored  in  memory,  I/O  after  test)     tcpdump  run  on  Stress  Agent  and  SysDB  servers     Correlate  timestamps  with  tcpdump   OptumSoft, Inc. Proprietary and 19   Confidential
  • 20. Low  latency  pitfalls  to  avoid     Network  and  TCP  behavior     Many  TCP  settings  have  a  dramatic  and  non-­‐linear   performance  impact     Memory  management     Memory  allocation/deallocation     Avoid  garbage  collection   “The devil is in the details” OptumSoft, Inc. Proprietary and 20   Confidential
  • 21. Zero-­‐load  Latency  (μs)   End-­‐to-­‐end   Time   Latency   Request   0   created  1   Request   48   48   SysDB   Time   Latency   packet  2   Receive  request  3   0.0   Response   248   200   Notification  4   42.3   42.3   packet  7   Response   75.1   32.8   Notification  8   288   40   enqueued  5   Response  packet  6   108.5   33.4   Latencies are low and predictable OptumSoft, Inc. Proprietary and 21   Confidential
  • 22. Latency,  throughput  vs  SysDBs   High scalability under Latency converges to strict latency bound zero-load latency OptumSoft, Inc. Proprietary and 22   Confidential
  • 23. Summary     Tacc  enables  developers  to  efficiently  create   predictably  high  performance,  scalable,  fault-­‐tolerant   distributed  applications     Eliminates  synchronization  and  locking  bugs     Fewer  lines  of  code     Faster  to  develop,  shorter  time  to  market     Easier  to  maintain     Fewer  bugs   23
  • 24. Contact  me  for  more  information  about  TACC  and   OptumSoft!   goosen@optumsoft.com   OptumSoft, Inc. Proprietary and 24   Confidential