Ce diaporama a bien été signalé.
Nous utilisons votre profil LinkedIn et vos données d’activité pour vous proposer des publicités personnalisées et pertinentes. Vous pouvez changer vos préférences de publicités à tout moment.

Building a Serverless State Service for the Cloud

274 vues

Publié le

While application architectures are evolving to become stateless, application state and state management are naturally emerging as a service in themselves. This session outlines the development, operation, and maintenance of an application state service for the cloud with Java 9, using a serverless strategy. The presentation investigates some of the challenges of designing an infinite-capacity, infinite-processing platform capable of reliably running everything from the smallest application to a globally distributed enterprise-class infrastructure for the mobile and IoT domains.

Publié dans : Logiciels
  • Soyez le premier à commenter

  • Soyez le premier à aimer ceci

Building a Serverless State Service for the Cloud

  1. 1. Copyright © 2017, Oracle and/or its affiliates. All rights reserved. | Building a Serverless State Service for the Cloud Copyright © 2017, Oracle and/or its affiliates. All rights reserved. | Building Agile and Resilient Schema Transf. using Kafka and ESB's Ed Burns Oracle Developer Experience November, 2017 @edburns
  2. 2. Copyright © 2017, Oracle and/or its affiliates. All rights reserved. | Speaker Qualifications – Ed Burns • 25 years software development experience • Java EE Spec Lead for JSF and Servlet • Frequent conference speaker and workshop leader • State Service contributor • Author of four IT books for McGraw-Hill
  3. 3. Copyright © 2017, Oracle and/or its affiliates. All rights reserved. | Safe Harbor Statement The following is intended to outline our general product direction. It is intended for information purposes only, and may not be incorporated into any contract. It is not a commitment to deliver any material, code, or functionality, and should not be relied upon in making purchasing decisions. The development, release, and timing of any features or functionality described for Oracle’s products remains at the sole discretion of Oracle. 4 E
  4. 4. Copyright © 2017, Oracle and/or its affiliates. All rights reserved. | 5 Stateless == Useless E
  5. 5. Copyright © 2017, Oracle and/or its affiliates. All rights reserved. | What can you do without state? • result = (input) -> convert(input); • Make it the callers problem: – hotPotato = (input) -> convert(input); doSomethingWith(hotPotato); • Externalize the state – Consistency – Performance 6 H
  6. 6. Copyright © 2017, Oracle and/or its affiliates. All rights reserved. | State and Serverless 7 Somebody Else’s Problem
  7. 7. Copyright © 2017, Oracle and/or its affiliates. All rights reserved. | State and Serverless 8 Somebody Else’s Problem
  8. 8. Copyright © 2017, Oracle and/or its affiliates. All rights reserved. | • We’ve been trying to reduce “boiler-plate” since we invented boilers. 9 State and Serverless The Relentless Drive To Allow Developers to Focus on “Business Logic”
  9. 9. Copyright © 2017, Oracle and/or its affiliates. All rights reserved. | • The very idea of separating – Core language – Runtime libraries 10 State and Serverless The Relentless Drive To Allow Developers to Focus on “Business Logic”
  10. 10. Copyright © 2017, Oracle and/or its affiliates. All rights reserved. | • Dependency Injection – Spring 1.0 2002 – JSF 1.0 2004 • @Inject 2009 • Containerization 2014 • Containerization and Cloud 2015 11 State and Serverless The Logical Extension of Dependency Injection
  11. 11. Copyright © 2017, Oracle and/or its affiliates. All rights reserved. | Convinced you need state?? OK – now where does it go? 12 E
  12. 12. Copyright © 2017, Oracle and/or its affiliates. All rights reserved. | What do you need from a store of state? • Durability • Reliability/HA • Scalability • Throughput • In-Place Processing • Querying/Aggregations • Events • Access with programming language of choice 13 H
  13. 13. Copyright © 2017, Oracle and/or its affiliates. All rights reserved. | What do you need from a store of state? • On-demand provisioning/elasticity • ”Serverless” operating paradigm • Managed by vendor • Pay as you go/utility computing pricing • Smooth on-ramp – Local development – Cloud development 14 H …in the cloud?
  14. 14. Copyright © 2017, Oracle and/or its affiliates. All rights reserved. | What do you want from a store of state? • Native language support • What’s wrong with Map, Dictionary, Hash Container, Associative Array? • It has everything; rows (entries), columns (inferred by fields) • And its key-centric: I think I can scale this puppy… • …but its stuck on the heap! 15 H
  15. 15. Copyright © 2017, Oracle and/or its affiliates. All rights reserved. | Map: if you can dream it, you can do it… • HashMap: – Hashing semantics, in-process, not thread-safe • Collections.synchronizedMap(map): – Hashing semantics, in-process, thread-safe, coarse contention • ConcurrentHashMap – Hashing semantics, in-process, thread-safe granular contention 16 H
  16. 16. Copyright © 2017, Oracle and/or its affiliates. All rights reserved. | Map: if you can dream it, you can do it… • CloudMap: – Hashing semantics, highly distributed, multi process & thread! – Map-based API that we plan to produce as one of the State Service APIs 17 Introducing CloudMap H
  17. 17. Copyright © 2017, Oracle and/or its affiliates. All rights reserved. | Map: what you give us for free… • Key-centric; get(k), put(k, v), remove(k) … • HashMap: table[hash(key) % table.length] = new Entry(key, value) • ConcurrentHashMap: lock(table[hash(key) % table.length]) && assign • DistributedHashMap : hash(key) -> partition/bucket -> member – Common approach: consistent hashing (hash(key) -> member) 18 LOCALREMOTE H
  18. 18. Copyright © 2017, Oracle and/or its affiliates. All rights reserved. | Serverless State Service CloudMap == DistributedMap++ 19 BARE METAL CLOUD COHERENCE E
  19. 19. Copyright © 2017, Oracle and/or its affiliates. All rights reserved. | Serverless State Service CloudMap == DistributedMap++ 20 BARE METAL CLOUD COHERENCE E
  20. 20. Copyright © 2017, Oracle and/or its affiliates. All rights reserved. | One State Service – Many Languages 21
  21. 21. Copyright © 2017, Oracle and/or its affiliates. All rights reserved. | 22 CloudMap H
  22. 22. Copyright © 2017, Oracle and/or its affiliates. All rights reserved. | CloudMap == DistributedMap++ • Distributed persistence (patented) – Shared storage is not required…and discouraged – Supports snapshots and ‘archiving’ distributed state 23 H
  23. 23. Copyright © 2017, Oracle and/or its affiliates. All rights reserved. | Vista Demo Serverless Function as a Service for any language, best of class for Java Microservices A collection of services, frameworks and libraries for the modern cloud developer; based on Cloud Native Compute Foundation fn State State A scalable, resilient state store based on common data structures E 24
  24. 24. Copyright © 2017, Oracle and/or its affiliates. All rights reserved. |Copyright © 2017, Oracle and/or its affiliates. All rights reserved. 25 The Containerization Journey Phase I Developer Focus Phase II DevOps Focus Phase III Business Focus Container Adoption Application Deployment Business Integration Speed Efficiency Agility Docker Kubernetes Biz+Ops Developer adoption Dev/Test apps Simple orchestration Individual developers DevOps deployment Production apps Advanced orchestration Teams & lines of business Broad integration Business apps Self management & ML Enterprises Focus Applications Automation Community
  25. 25. Copyright © 2017, Oracle and/or its affiliates. All rights reserved. |Copyright © 2017, Oracle and/or its affiliates. All rights reserved. Oracle Container Native Strategy • Deliver a container native suite that is open, integrated, enterprise-grade – CI/CD, Orchestration/Scheduling, Management/Operations, Analytics/Introspection – With a cloud neutral application development platform for microservices and serverless • That is community driven, cloud neutral and open source – Deep investment in open source communities and foundations (Kubernetes, Docker, CNCF) via engineering resources, code contributions & sponsorship – To avoid cloud lock-in • Differentiated on quality of service and operational excellence – Full, transparent management – Deployed to Oracle Cloud Infrastructure – Enterprise grade security, HA and governance
  26. 26. Copyright © 2017, Oracle and/or its affiliates. All rights reserved. |Copyright © 2017, Oracle and/or its affiliates. All rights reserved. Oracle Container Microservices Oracle Container Functions Oracle Container Engine Oracle Container Registry Container Native Application Development Capabilities Build, Deploy, Operate Container Native Applications 27 Continuous Integration and Delivery Pipeline Docker Compliant Container Image Registry Fully Managed Standard Kubernetes Service Open Source Serverless Functions Framework Open Source Microservices Framework Oracle Container Pipelines
  27. 27. Copyright © 2017, Oracle and/or its affiliates. All rights reserved. |Copyright © 2017, Oracle and/or its affiliates. All rights reserved. Git Build Push to Registry PushTest Deploy to Kubernetes Container Pipelines CI/CD Service Container Registry Private Registry Service Container Engine Fully-Managed Kubernetes Service Managed HA Control Plane Bare Metal and VM Shapes Orchestrate Your App Kubernetes Dashboard Full REST API kubectl CLI Team Access Container Microservices Microservice Management Service Container Functions Functions as a Service Service Mesh Service Broker API Catalog Monitoring & Diagnostics Fn Server Fn FDK Fn Flow Oracle Container Native Application Development Platform
  28. 28. Copyright © 2017, Oracle and/or its affiliates. All rights reserved. |Copyright © 2017, Oracle and/or its affiliates. All rights reserved. KubeCon + CloudNativeCon 2017 Announcements 29 • Fn Installer for Kubernetes (open sourced) – A set of Helm charts that install and run Fn on any K8s deployment • Including Oracle’s managed K8s service Oracle Container Engine (OCE) – Fn: open source serverless project announced in October at Oracle OpenWorld. – Open on open, integrated, and enterprise-grade • Global Multi-Cluster Management (open sourced) – Distributed cluster management features for Kubernetes federation – Addresses operational challenges of running planet scale apps cross data center, multi-cloud, or hybrid cloud • Multi-cluster lifecycle management, capacity management (on-demand, auto-scale), and supply-demand management – Open sourced, integrated on top of Kubernetes, enterprise operations ready
  29. 29. Copyright © 2017, Oracle and/or its affiliates. All rights reserved. | Vista License Plate Demo 30 Java Functions Scraper Detect Plates Alert Alert Manager Detect Duplicates Draw Progress Publish E
  30. 30. Copyright © 2017, Oracle and/or its affiliates. All rights reserved. | Vista License Plate Demo 31 Helping Services and Code Scraper Detect Plates Alert Alert Manager Detect Duplicates Draw Progress Publish E
  31. 31. Copyright © 2017, Oracle and/or its affiliates. All rights reserved. | Vista License Plate Demo 32 State Service Interactions Scraper Detect Plates Alert Alert Manager Detect Duplicates Draw Progress Publish E
  32. 32. Copyright © 2017, Oracle and/or its affiliates. All rights reserved. | Fn Flow is the Secret Sauce in This Whole Story 33 Warsaw’s Own, and Code Europe Alumni Tomasz Nurkiewicz
  33. 33. Copyright © 2017, Oracle and/or its affiliates. All rights reserved. | • That YouTube video http://bit.ly/TomaszJava 34 Thomasz Nurkiewicz, CompletableFuture and RxJava
  34. 34. Copyright © 2017, Oracle and/or its affiliates. All rights reserved. | Serverless State Service • Infinitely scalable • Resilient • Continuously available • A ubiquitously understood programming model • Data local processing • Pay-as-you-go Coming to a cloud near you… 35 H
  35. 35. Copyright © 2017, Oracle and/or its affiliates. All rights reserved. | Safe Harbor Statement The preceding is intended to outline our general product direction. It is intended for information purposes only, and may not be incorporated into any contract. It is not a commitment to deliver any material, code, or functionality, and should not be relied upon in making purchasing decisions. The development, release, and timing of any features or functionality described for Oracle’s products remains at the sole discretion of Oracle. 36
  36. 36. Copyright © 2017, Oracle and/or its affiliates. All rights reserved. | 37

×