![Page 1: In-Memory Grid Computing und Java EE - JUG Saxony...Coherence Cool Vendor 1.0 2011 Tangosol founded to pioneer distributed caching Award Oracle acquires Tangosol Coherence 3.7.1.1](https://reader036.vdocuments.net/reader036/viewer/2022071500/611f46609a00545ba368f5ac/html5/thumbnails/1.jpg)
Copyright © 2014 Oracle and/or its affiliates. All rights reserved. |
In-Memory Grid Computing und Java EE
Michael Bräuer Oracle Deutschland B.V. & Co. KG
![Page 2: In-Memory Grid Computing und Java EE - JUG Saxony...Coherence Cool Vendor 1.0 2011 Tangosol founded to pioneer distributed caching Award Oracle acquires Tangosol Coherence 3.7.1.1](https://reader036.vdocuments.net/reader036/viewer/2022071500/611f46609a00545ba368f5ac/html5/thumbnails/2.jpg)
Copyright © 2014 Oracle and/or its affiliates. All rights reserved. |
Java Application Server Plattform Community Eine Community von ORACLE für Kunden, Partner und Interessierte
Code Camps
Registrierung: https://www.xing.com/net/oraclejavaappserver Blog: http://fmwtech.wordpress.com Ansprechpartner: [email protected] [email protected]
Wissensaustausch
Community Treffen
Vorträge
GlassFish Server
WebLogic Server
JSRs
Demos
Java EE
Administration
Serverseitige Entwicklung
![Page 3: In-Memory Grid Computing und Java EE - JUG Saxony...Coherence Cool Vendor 1.0 2011 Tangosol founded to pioneer distributed caching Award Oracle acquires Tangosol Coherence 3.7.1.1](https://reader036.vdocuments.net/reader036/viewer/2022071500/611f46609a00545ba368f5ac/html5/thumbnails/3.jpg)
Copyright © 2014 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.
3
![Page 4: In-Memory Grid Computing und Java EE - JUG Saxony...Coherence Cool Vendor 1.0 2011 Tangosol founded to pioneer distributed caching Award Oracle acquires Tangosol Coherence 3.7.1.1](https://reader036.vdocuments.net/reader036/viewer/2022071500/611f46609a00545ba368f5ac/html5/thumbnails/4.jpg)
Copyright © 2014 Oracle and/or its affiliates. All rights reserved. |
Agenda
• Status Quo: Zustand in verteilten Java EE Umgebungen
• In-Memory Grid Computing und Java EE mit Oracle Coherence
4
![Page 5: In-Memory Grid Computing und Java EE - JUG Saxony...Coherence Cool Vendor 1.0 2011 Tangosol founded to pioneer distributed caching Award Oracle acquires Tangosol Coherence 3.7.1.1](https://reader036.vdocuments.net/reader036/viewer/2022071500/611f46609a00545ba368f5ac/html5/thumbnails/5.jpg)
Copyright © 2014 Oracle and/or its affiliates. All rights reserved. |
Serverseitiger Zustand in modernen Java EE Anwendungen
• Beispiel Drawingboard (https://github.com/doschkinow/hol-sse-websocket):
– Client: HTML5 (angular.js)
– Server: JAX-RS 2.0 (JSR- 339) und SSE, Websockets 1.0 (JSR-356), u.a.
5
DataProvider (Map mit Drawings)
JAX
-RS,
SS
E (J
erse
y)
WS
End
po
int
WebLogic
![Page 6: In-Memory Grid Computing und Java EE - JUG Saxony...Coherence Cool Vendor 1.0 2011 Tangosol founded to pioneer distributed caching Award Oracle acquires Tangosol Coherence 3.7.1.1](https://reader036.vdocuments.net/reader036/viewer/2022071500/611f46609a00545ba368f5ac/html5/thumbnails/6.jpg)
Copyright © 2014 Oracle and/or its affiliates. All rights reserved. |
Zustand, der in verschiedenen JVMs gebraucht wird
6
?
![Page 7: In-Memory Grid Computing und Java EE - JUG Saxony...Coherence Cool Vendor 1.0 2011 Tangosol founded to pioneer distributed caching Award Oracle acquires Tangosol Coherence 3.7.1.1](https://reader036.vdocuments.net/reader036/viewer/2022071500/611f46609a00545ba368f5ac/html5/thumbnails/7.jpg)
Copyright © 2014 Oracle and/or its affiliates. All rights reserved. |
Eine erste Idee ...
7
Objekte?
Antwortzeit
Durchsatz ?
![Page 8: In-Memory Grid Computing und Java EE - JUG Saxony...Coherence Cool Vendor 1.0 2011 Tangosol founded to pioneer distributed caching Award Oracle acquires Tangosol Coherence 3.7.1.1](https://reader036.vdocuments.net/reader036/viewer/2022071500/611f46609a00545ba368f5ac/html5/thumbnails/8.jpg)
Copyright © 2014 Oracle and/or its affiliates. All rights reserved. |
8
Java EE Cached Data ??? Shared State ???
Conversational State ???
![Page 9: In-Memory Grid Computing und Java EE - JUG Saxony...Coherence Cool Vendor 1.0 2011 Tangosol founded to pioneer distributed caching Award Oracle acquires Tangosol Coherence 3.7.1.1](https://reader036.vdocuments.net/reader036/viewer/2022071500/611f46609a00545ba368f5ac/html5/thumbnails/9.jpg)
Copyright © 2014 Oracle and/or its affiliates. All rights reserved. |
Java EE 7 Fokus
9
![Page 10: In-Memory Grid Computing und Java EE - JUG Saxony...Coherence Cool Vendor 1.0 2011 Tangosol founded to pioneer distributed caching Award Oracle acquires Tangosol Coherence 3.7.1.1](https://reader036.vdocuments.net/reader036/viewer/2022071500/611f46609a00545ba368f5ac/html5/thumbnails/10.jpg)
Copyright © 2014 Oracle and/or its affiliates. All rights reserved. |
Java EE 7 JSRs – Prefinal
10
![Page 11: In-Memory Grid Computing und Java EE - JUG Saxony...Coherence Cool Vendor 1.0 2011 Tangosol founded to pioneer distributed caching Award Oracle acquires Tangosol Coherence 3.7.1.1](https://reader036.vdocuments.net/reader036/viewer/2022071500/611f46609a00545ba368f5ac/html5/thumbnails/11.jpg)
Copyright © 2014 Oracle and/or its affiliates. All rights reserved. |
Java EE 7 JSRs – Final
11
![Page 12: In-Memory Grid Computing und Java EE - JUG Saxony...Coherence Cool Vendor 1.0 2011 Tangosol founded to pioneer distributed caching Award Oracle acquires Tangosol Coherence 3.7.1.1](https://reader036.vdocuments.net/reader036/viewer/2022071500/611f46609a00545ba368f5ac/html5/thumbnails/12.jpg)
Copyright © 2014 Oracle and/or its affiliates. All rights reserved. |
Status Quo: Zustand in der Java EE Welt
• JSR für Caching innerhalb von Java EE?
– Frühjahr 2014 • Finalisierung JSR-107: Caching in Java SE
• Keine Aussagen über Zusammenarbeit mit Java EE Java EE 8 (?)
• JSR für Java Grid Computing (was passiert in JSR-347: „Data Grids for the Java Plattform“)?
12
![Page 13: In-Memory Grid Computing und Java EE - JUG Saxony...Coherence Cool Vendor 1.0 2011 Tangosol founded to pioneer distributed caching Award Oracle acquires Tangosol Coherence 3.7.1.1](https://reader036.vdocuments.net/reader036/viewer/2022071500/611f46609a00545ba368f5ac/html5/thumbnails/13.jpg)
Copyright © 2014 Oracle and/or its affiliates. All rights reserved. |
Verteilter Zugriff? Kapazität? Objekte? Skalierbarkeit? Verfügbarkeit? Latenz ?
![Page 14: In-Memory Grid Computing und Java EE - JUG Saxony...Coherence Cool Vendor 1.0 2011 Tangosol founded to pioneer distributed caching Award Oracle acquires Tangosol Coherence 3.7.1.1](https://reader036.vdocuments.net/reader036/viewer/2022071500/611f46609a00545ba368f5ac/html5/thumbnails/14.jpg)
Copyright © 2014 Oracle and/or its affiliates. All rights reserved. |
![Page 15: In-Memory Grid Computing und Java EE - JUG Saxony...Coherence Cool Vendor 1.0 2011 Tangosol founded to pioneer distributed caching Award Oracle acquires Tangosol Coherence 3.7.1.1](https://reader036.vdocuments.net/reader036/viewer/2022071500/611f46609a00545ba368f5ac/html5/thumbnails/15.jpg)
Copyright © 2014 Oracle and/or its affiliates. All rights reserved. |
In-Memory Data Grid*
• In-Memory basiertes Management System für verteilt genutzte Objekte mit
– geringen Antwortzeiten
– hohem Duchsatz
– vorhersehbarer Skalierbarkeit
– Fehlertoleranz: Verfügbarkeit und Zuverlässigkeit.
17
* angelehnt an http://www.jroller.com/cpurdy/entry/defining_a_data_grid
![Page 16: In-Memory Grid Computing und Java EE - JUG Saxony...Coherence Cool Vendor 1.0 2011 Tangosol founded to pioneer distributed caching Award Oracle acquires Tangosol Coherence 3.7.1.1](https://reader036.vdocuments.net/reader036/viewer/2022071500/611f46609a00545ba368f5ac/html5/thumbnails/16.jpg)
Copyright © 2014 Oracle and/or its affiliates. All rights reserved. |
Anforderungen/Herausforderungen
• Hohe Kapazitäten: TBs
– In-Memory: On-Heap
– alternative Medien: SSDs, Flash
– Schnelles Netzwerk (!!)
• Verteiltes Rechnen: Datenmanagement und parallele, auch asynchrone Verarbeitung, z.B. mittels EntryProzessor, Filter, Aggregationen
• Integration in Java SE und Java EE Umgebungen
• Vielseitiger Clientzugriff: Java, C++, .Net, REST, memcached
• Wie serialisieren?
18
![Page 17: In-Memory Grid Computing und Java EE - JUG Saxony...Coherence Cool Vendor 1.0 2011 Tangosol founded to pioneer distributed caching Award Oracle acquires Tangosol Coherence 3.7.1.1](https://reader036.vdocuments.net/reader036/viewer/2022071500/611f46609a00545ba368f5ac/html5/thumbnails/17.jpg)
Copyright © 2014 Oracle and/or its affiliates. All rights reserved. |
Anforderungen/Herausforderungen
• Integration mit persistenten Systemen (Vermeidung Stale Cache Problem)
• Einfache Konfiguration, Administration und Monitoring vieler JVMs
19
![Page 18: In-Memory Grid Computing und Java EE - JUG Saxony...Coherence Cool Vendor 1.0 2011 Tangosol founded to pioneer distributed caching Award Oracle acquires Tangosol Coherence 3.7.1.1](https://reader036.vdocuments.net/reader036/viewer/2022071500/611f46609a00545ba368f5ac/html5/thumbnails/18.jpg)
Copyright © 2014 Oracle and/or its affiliates. All rights reserved. |
Pionier im Bereich Java In-Memory Data Grid Computing
20
2001 ….. 2008 2009 2000 2007 2010
Coherence 1.0
2011
Tangosol founded to
pioneer distributed
caching
Cool Vendor Award
Oracle acquires Tangosol
Coherence 3.7.1.1
Coherence 3.6
Coherence 3.5
Coherence 3.7
Increasing market share and feature capabilities for In Memory Data Grid. Market widened All Categories – Financial Services, E-Commerce, Travel, Insurance, Retail,
Manufacturing, Telco …
Deep adoption in Fusion Middleware, Oracle Horizontal and Vertical and Business Applications and Exalogic
2012 2013 2014
Coherence 12.1.2
Coherence 12.1.3
![Page 19: In-Memory Grid Computing und Java EE - JUG Saxony...Coherence Cool Vendor 1.0 2011 Tangosol founded to pioneer distributed caching Award Oracle acquires Tangosol Coherence 3.7.1.1](https://reader036.vdocuments.net/reader036/viewer/2022071500/611f46609a00545ba368f5ac/html5/thumbnails/19.jpg)
Copyright © 2014 Oracle and/or its affiliates. All rights reserved. |
Coherence in a Nutshell
• Coherence-Knoten:
– Java Knoten:(Non-)Storage Knoten und optional Proxy-Knoten: XML-Konfigurationen und Bibliotheken im Klassenpfad
– C++, .NET, REST, memcached Zugriff mittels Proxy-Knoten.
• Storageknoten können Daten aufnehmen/verwalten, spezielle Serialisierungsmechanismen sind möglich (POF), Evolvable
• Sehr effiziente Protokolle für Clusterkommunikation (TCMP)
• APIs: – Coherence spezifische APIs: NamedCache API (= Map<K,V> ähnliche Datenstruktur)
– JCache API (JSR-107)
21
![Page 20: In-Memory Grid Computing und Java EE - JUG Saxony...Coherence Cool Vendor 1.0 2011 Tangosol founded to pioneer distributed caching Award Oracle acquires Tangosol Coherence 3.7.1.1](https://reader036.vdocuments.net/reader036/viewer/2022071500/611f46609a00545ba368f5ac/html5/thumbnails/20.jpg)
Copyright © 2014 Oracle and/or its affiliates. All rights reserved. |
Administration vieler JVMs?
Coherence in a Nutshell
• Alle IDEs
• Builds mit Maven
• Konfiguration over Default
– XML
– Java System Properties
• Management mit JMX – JVisualVM Plug-In
– Oracle Enterprise Manager Cloud Control und 3rd Party
22
Coherence Management Pack for OEM • Complete management and
monitoring solution • Store historical results • Java diagnostics tooling
JVisualVM Plugin • Available now for 3.x on
Coherence Community Website
• Lightweight plugin to JVM
Fusion Middleware Control • OOTB administration and
monitoring for all FMW • Dev/QA point-in-time insight
into cluster
![Page 21: In-Memory Grid Computing und Java EE - JUG Saxony...Coherence Cool Vendor 1.0 2011 Tangosol founded to pioneer distributed caching Award Oracle acquires Tangosol Coherence 3.7.1.1](https://reader036.vdocuments.net/reader036/viewer/2022071500/611f46609a00545ba368f5ac/html5/thumbnails/21.jpg)
Copyright © 2014 Oracle and/or its affiliates. All rights reserved. |
Coherence in a Nutshell
24
![Page 22: In-Memory Grid Computing und Java EE - JUG Saxony...Coherence Cool Vendor 1.0 2011 Tangosol founded to pioneer distributed caching Award Oracle acquires Tangosol Coherence 3.7.1.1](https://reader036.vdocuments.net/reader036/viewer/2022071500/611f46609a00545ba368f5ac/html5/thumbnails/22.jpg)
Copyright © 2014 Oracle and/or its affiliates. All rights reserved. |
Coherence in a Nutshell
25
![Page 23: In-Memory Grid Computing und Java EE - JUG Saxony...Coherence Cool Vendor 1.0 2011 Tangosol founded to pioneer distributed caching Award Oracle acquires Tangosol Coherence 3.7.1.1](https://reader036.vdocuments.net/reader036/viewer/2022071500/611f46609a00545ba368f5ac/html5/thumbnails/23.jpg)
Copyright © 2014 Oracle and/or its affiliates. All rights reserved. |
Coherence in a Nutshell
27
Parallele Verarbeitung: Filter mit Indizes, Aggregationen
![Page 24: In-Memory Grid Computing und Java EE - JUG Saxony...Coherence Cool Vendor 1.0 2011 Tangosol founded to pioneer distributed caching Award Oracle acquires Tangosol Coherence 3.7.1.1](https://reader036.vdocuments.net/reader036/viewer/2022071500/611f46609a00545ba368f5ac/html5/thumbnails/24.jpg)
Copyright © 2014 Oracle and/or its affiliates. All rights reserved. |
Coherence in a Nutshell
28
Parallele Verabeitung: synchrone und asynchrone Entryprozessoren Bringe Code zu Verabeitungsknoten und nicht Daten in den Client
![Page 25: In-Memory Grid Computing und Java EE - JUG Saxony...Coherence Cool Vendor 1.0 2011 Tangosol founded to pioneer distributed caching Award Oracle acquires Tangosol Coherence 3.7.1.1](https://reader036.vdocuments.net/reader036/viewer/2022071500/611f46609a00545ba368f5ac/html5/thumbnails/25.jpg)
Copyright © 2014 Oracle and/or its affiliates. All rights reserved. |
Coherence in a Nutshell
29
Map Events: entryInserted, entryUpdated, entryDeleted Live Events: Partitioned Cache Events, Partitioned Service Events, Lifecycle Events, …
![Page 26: In-Memory Grid Computing und Java EE - JUG Saxony...Coherence Cool Vendor 1.0 2011 Tangosol founded to pioneer distributed caching Award Oracle acquires Tangosol Coherence 3.7.1.1](https://reader036.vdocuments.net/reader036/viewer/2022071500/611f46609a00545ba368f5ac/html5/thumbnails/26.jpg)
Copyright © 2014 Oracle and/or its affiliates. All rights reserved. |
Coherence in a Nutshell
30
Cache Aside Write-Through
Write-Behind
Coherence GoldenGate HotCache Cache Storage
(Oracle DB)
Veränderungen
Veränderungen (z.B. Batch)
CacheStore
![Page 27: In-Memory Grid Computing und Java EE - JUG Saxony...Coherence Cool Vendor 1.0 2011 Tangosol founded to pioneer distributed caching Award Oracle acquires Tangosol Coherence 3.7.1.1](https://reader036.vdocuments.net/reader036/viewer/2022071500/611f46609a00545ba368f5ac/html5/thumbnails/27.jpg)
Copyright © 2014 Oracle and/or its affiliates. All rights reserved. |
Java EE UND In-Memory Grid
WebLogic Nodes
Capacity
Managed Server
MyApplication
Managed Server
MyApplication
Capacity Capacity
Managed Server
MyApplication
Capacity Capacity
Coherence Storage Nodes (Coherence Managed Server)
![Page 28: In-Memory Grid Computing und Java EE - JUG Saxony...Coherence Cool Vendor 1.0 2011 Tangosol founded to pioneer distributed caching Award Oracle acquires Tangosol Coherence 3.7.1.1](https://reader036.vdocuments.net/reader036/viewer/2022071500/611f46609a00545ba368f5ac/html5/thumbnails/28.jpg)
Copyright © 2014 Oracle and/or its affiliates. All rights reserved. |
Skalierbare Architektur: Eventbasiert
32
https://github.com/doschkinow/hol-sse-websocket, solutions/exercise9
Co
he
ren
ce C
lust
er
![Page 29: In-Memory Grid Computing und Java EE - JUG Saxony...Coherence Cool Vendor 1.0 2011 Tangosol founded to pioneer distributed caching Award Oracle acquires Tangosol Coherence 3.7.1.1](https://reader036.vdocuments.net/reader036/viewer/2022071500/611f46609a00545ba368f5ac/html5/thumbnails/29.jpg)
Copyright © 2014 Oracle and/or its affiliates. All rights reserved. |
Einige kritische Erfolgsfaktoren - Betriebssicht
• Netzwerkkonfiguration und -planung
– Bandbreite und Latenz: Coherence Netzwerk Tools kommen mit!
– Konfiguration Netzwerkkarten (Linkaggregation unter Solaris (aktiv-aktiv vs. aktiv-passiv), z.B. IP Multipathing, DataLink Multipathing, etc. bei Solaris)
– Konfiguration Switches
– Rebalancing im Ausfall!
• Sorgfältige Kapazitätsplanung:
– Anzahl der Knoten/JVMs: Kapazität, Planung für Fehlertoleranz
– HW Planung: JVM Knoten per Rechenknoten (RAM, Prozessorkerne)
– http://www.oracle.com/technetwork/middleware/coherence/planning-coherence-deployment-1985929.pdf
33
![Page 30: In-Memory Grid Computing und Java EE - JUG Saxony...Coherence Cool Vendor 1.0 2011 Tangosol founded to pioneer distributed caching Award Oracle acquires Tangosol Coherence 3.7.1.1](https://reader036.vdocuments.net/reader036/viewer/2022071500/611f46609a00545ba368f5ac/html5/thumbnails/30.jpg)
Copyright © 2014 Oracle and/or its affiliates. All rights reserved. |
Einige kritische Erfolgsfaktoren - Entwicklersicht
• Entscheide, was lokal oder verteilt benötigt wird
• Vermeide Standardserialisierungmechanismus: implementiere POF (Portable Object Format) mit 98:2 Regel
• Bringe Code zu den Daten, nicht Daten zum Code
• Denke über Parallelisierung nach
• Überdenke Dein Objektmodell
• Suche Einfachheit und Eleganz: kein „Overengineering“ von Anforderungen:
– Bitte keine RDBMS nachimplementieren!
34
![Page 31: In-Memory Grid Computing und Java EE - JUG Saxony...Coherence Cool Vendor 1.0 2011 Tangosol founded to pioneer distributed caching Award Oracle acquires Tangosol Coherence 3.7.1.1](https://reader036.vdocuments.net/reader036/viewer/2022071500/611f46609a00545ba368f5ac/html5/thumbnails/31.jpg)
Copyright © 2014 Oracle and/or its affiliates. All rights reserved. |
Hilfsmittel, Testen & Co
35
![Page 32: In-Memory Grid Computing und Java EE - JUG Saxony...Coherence Cool Vendor 1.0 2011 Tangosol founded to pioneer distributed caching Award Oracle acquires Tangosol Coherence 3.7.1.1](https://reader036.vdocuments.net/reader036/viewer/2022071500/611f46609a00545ba368f5ac/html5/thumbnails/32.jpg)
Copyright © 2014 Oracle and/or its affiliates. All rights reserved. |
Demos
36
![Page 33: In-Memory Grid Computing und Java EE - JUG Saxony...Coherence Cool Vendor 1.0 2011 Tangosol founded to pioneer distributed caching Award Oracle acquires Tangosol Coherence 3.7.1.1](https://reader036.vdocuments.net/reader036/viewer/2022071500/611f46609a00545ba368f5ac/html5/thumbnails/33.jpg)
Copyright © 2014 Oracle and/or its affiliates. All rights reserved. |
Zusammenfassung
Aber auch mit , , ... . Try it.
37
Cached Data ! Shared State !
Conversational State !
![Page 34: In-Memory Grid Computing und Java EE - JUG Saxony...Coherence Cool Vendor 1.0 2011 Tangosol founded to pioneer distributed caching Award Oracle acquires Tangosol Coherence 3.7.1.1](https://reader036.vdocuments.net/reader036/viewer/2022071500/611f46609a00545ba368f5ac/html5/thumbnails/34.jpg)
Copyright © 2014 Oracle and/or its affiliates. All rights reserved. |
Zusammenfassung
38
http://www.infoq.com/presentations/League-of-Legends http://qconsf.com/sf2010/dl/qcon-sanfran-2010/slides/RandyStafford_and_ScottDelap_LeagueOfLegendsScalingToMillionsOfNinjasYordlesAndWizards.pdf http://www.oracle.com/technetwork/middleware/coherence/coherence-case-studies-091909.html
![Page 35: In-Memory Grid Computing und Java EE - JUG Saxony...Coherence Cool Vendor 1.0 2011 Tangosol founded to pioneer distributed caching Award Oracle acquires Tangosol Coherence 3.7.1.1](https://reader036.vdocuments.net/reader036/viewer/2022071500/611f46609a00545ba368f5ac/html5/thumbnails/35.jpg)
Copyright © 2014 Oracle and/or its affiliates. All rights reserved. |
Join the Coherence Community
coherence.oracle.com
Oracle Coherence
Users
/OracleCoherence @OracleCoherence blogs.oracle.com/
OracleCoherence
/OracleCoherence
![Page 36: In-Memory Grid Computing und Java EE - JUG Saxony...Coherence Cool Vendor 1.0 2011 Tangosol founded to pioneer distributed caching Award Oracle acquires Tangosol Coherence 3.7.1.1](https://reader036.vdocuments.net/reader036/viewer/2022071500/611f46609a00545ba368f5ac/html5/thumbnails/36.jpg)
Copyright © 2014 Oracle and/or its affiliates. All rights reserved. |