Franciscans Charism Presented by Leonel Aruajo, OFM and Joseph Koh, OFM Kairos 2005
Coherence Overview - OFM Canberra July 2014
-
Upload
joelith -
Category
Technology
-
view
199 -
download
0
description
Transcript of Coherence Overview - OFM Canberra July 2014
Copyright © 2014, Oracle and/or its affiliates. All rights reserved. |
Oracle Coherence Overview
Damien McAullayOracle Fusion MiddlewareJuly 2014
Copyright © 2014, Oracle and/or its affiliates. All rights reserved. | 2
Coherence: Core Enterprise Challenges
Scaling applications to support growth
Offloading and protection of shared services
Delivery of information in real time
BatchProcessing
App
App
CoherenceIn-Memory Data Grid
AppApp App
Middleware
Copyright © 2014, Oracle and/or its affiliates. All rights reserved. | 3
Modern Best Practice Caching ArchitecturePioneered By Coherence
First Generation Cache Solutions
Difficult to scale, complex to synchronize, limited capacity
Modern Best Practice Cache Solutions
Easy to Scale, Clustered, Synchronized, Advanced Capabilities
Copyright © 2014, Oracle and/or its affiliates. All rights reserved. | 4
Application Server with Coherence
• Offload session and application data management from the app server tier
• Scale tiers independently
• Coherence*Web• Decouple session management from web
container
• Handle more users without adding more application servers
• Restart/maintain applications/containers without losing sessions
• Handle very large sessions efficiently
Scale Session, Cache and Data Grid as Independent Architectural Tier
Copyright © 2014, Oracle and/or its affiliates. All rights reserved. | 5
Partitioned, Fault Tolerant, Self-Healing Cache
Coherence Clustered Caching Explained
• Cluster of nodes holding % of primary data locally
• Back-up of primary data is distributed across all other nodes
• Logical view of all data from any node
• All nodes verify health of each other
• In the event a node is unhealthy, other nodes diagnose state
• Unhealthy node isolated from cluster
• Remaining nodes redistribute primary and back-up responsibilities to healthy nodes
?
Copyright © 2014, Oracle and/or its affiliates. All rights reserved. | 6
In-Memory Data Grid
Data
Partitioned Caching
• Data load balanced across data grid.• Data/processing scales linearly. • Ownership responsibilities
partitioned.• Access/update latency are constant.• Best for large sets of frequently
updated data.
Unlimited Data and Processing CapacityApplications
Process Process Process Process
Virtual Load Balancing
Coherence Cluster
Copyright © 2014, Oracle and/or its affiliates. All rights reserved. | 7
In-Memory Data Grid
Data
Partitioned Fault Tolerance
• Backups stored on separate machine.• Even distribution of backup
responsibilities.• Configurable number of backup
copies.• Once-and-only-once processing
guarantees.
Automatic fault tolerance managementApplications
Process Process Process Process
Virtual Load Balancing
Fault Tolerance Management
Coherence Cluster
Copyright © 2014, Oracle and/or its affiliates. All rights reserved. | 8
In-Memory Data Grid
Replicated Caching
• Entire data set is replicated.• Data is stored as native Java object• Data access is immediate.• Updates are replicated across grid.• Best for small sets of static data.
Rapid Access to Reference Data
Process Process Process Process
Replication
Data
Applications
Coherence Cluster
Copyright © 2014, Oracle and/or its affiliates. All rights reserved. | 9
In-Memory Data Grid
Data
Near Caching
• Recently used data is stored locally.• Repeated access local and immediate.• Automatically populated upon data
access.• Automatic invalidation of updated
data.• Scale tiers independently.
Rapid Data Access From Clients
Process Process Process Process
Virtual Load Balancing
Coherence Cluster
Application Application Application
Copyright © 2014, Oracle and/or its affiliates. All rights reserved. | 10
Clients, Proxies, and POF
• Java, .NET, C++, and REST Clients• Client types
– Coherence*Extend (external to cluster)– Compute Clients (Java cluster members)– REST Clients
• Portable Object Format (POF)– Highly compressed object format
• Stores data more efficiently on data grid• Optimizes network usage
– Quick indexing to access individual fields
Optimized Native and REST SupportREST Client
PO
F
Cache
Java Client
Cac
he
Ser
ver
Tie
r
Coherence Extend
.NET Client
C++ Client
Java Client
Pro
xy T
ier
POF Objects
PO
F
Coherence Cluster
Copyright © 2014, Oracle and/or its affiliates. All rights reserved. |
Coherence Caching Patterns
• Cache Aside - Developer manages cache– Check the cache before reading from data source
– Put data into cache after reading from data source
– Evict or update cache when updating data source
• Read Through/Write Through– All data reads/writes occur through cache– Cache miss causes load from data source– Cache updates written synchronously to data source
• Write Behind– All data writes occur through cache– Updates to cache written asynchronously to the data source
DAO Cache
DAO Cache
Cache
DAO
Copyright © 2014, Oracle and/or its affiliates. All rights reserved. | 12
Parallel Processing
• Send processing to where the data lives.
• Processing in parallel across grid.– Query the Data Grid– Continuous Query Cache– Parallel Processing on the Data Grid– Map/Reduce Aggregation
• Once-and-only-once guarantees.• Processing scales with the grid.
Querying, Processing, Aggregating in the Data Grid
In-Memory Data Grid
Process Process Process Process
Coherence Cluster
Application
ProcessingUnit
Copyright © 2014, Oracle and/or its affiliates. All rights reserved. | 13
Event Notifications
• Grid based event notification– Java Bean Model, key and filter based
events
• Compliments scalable grid processing– Real-time data
• “Live Objects”– Objects can respond to own state
changes– State always recoverable
Support for Event Based Applications
In-Memory Data Grid
Process Process Process Process
Coherence Cluster
Application Application Application
Copyright © 2014, Oracle and/or its affiliates. All rights reserved. | 14
Memcached Adaptor• Migrate from Memcached• Use popular Memcached Clients• Leverage Coherence benefits and
features– Scalability, availability, and reliability– Data source integration including
HotCache– Security
• SASL PLAIN authentication mechanism using Coherence JAAS Identity Asserter
• Integrates with the Coherence Proxy Security framework for custom authorization.
Memcached… Client
Cache
Memcached Acceptor
MemcachedRuby Client
POF Serializer
Cac
he
Ser
ver
Pro
xy S
erve
r
MemcachedJava Client
MemcachedPHP Client
Copyright © 2014, Oracle and/or its affiliates. All rights reserved. | 15
JCache (JSR-107) SupportThe Standard API for Caching on the Java EE Platform
• JSR-107– Oracle Co-Spec Lead– Unanimously passed in 2014
• Full Support in Coherence– Multiple Cache Topology support– Interoperability with all Coherence clients– Leverage Coherence features and benefits
• Server-side processing• HotCache, Multi-Datacenter, etc.
Application
javax.cache.* API (JSR-107 JCache)
Co
he
ren
ce
Ca
che
Coherence Cluster
Coherence JSR-107 Adapter
Coherence API (NamedCache)
Copyright © 2014, Oracle and/or its affiliates. All rights reserved. | 16
REST Security and Usability Improvements
• Secure SSL communications– HTTP basic authentication, client-side
certificates– Fine-grained authorization
• Query Enhancements– “named queries”– Limit query results– Keyset Retrieval
• Pluggable Query Engines
Improved Client Integration
In-Memory Data Grid
Proxy Tier
Data Tier
Copyright © 2014, Oracle and/or its affiliates. All rights reserved. | 17
• Detect and reflect database changes in cache in real time
• Leverage existing technologies– GoldenGate, TopLink Grid
• Broaden applicability/usability of Coherence
• No code change
Coherence GoldenGate HotCacheReal Time Database Updates for Your Apps
AppApp App
Coherence
BatchProcess
GoldenGate HotCache
Copyright © 2014, Oracle and/or its affiliates. All rights reserved. | 18
Coherence Availability Options
• Synchronous and asynchronous backups
• Asynchronous backups can improve throughput 40-50%
• Tradeoff of availability and consistency against performance
Asynchronous Backup
Primary BackupClient
1
2 2
3
Asynchronous Backup
Primary BackupClient
1
3
2
4
Synchronous Backup
Copyright © 2014, Oracle and/or its affiliates. All rights reserved. | 19
Coherence Availability Options
• Multi-Level Backup• Guaranteed backup in case of
simultaneous multi-machine failure• Availability and consistency traded off
against performance
Multiple Backups
PrimaryClient Backup
Backup
Backup
Pre-12.1.2
PrimaryClient Backup Backup Backup
12.1.2
Copyright © 2014, Oracle and/or its affiliates. All rights reserved. | 20
Coherence Availability Options
• Node safe• Machine safe• Rack safe• Site safe
Node, Machine, Site and Rack SafetyRack 2
Machine 5
P4’
P5
Machine 8
P2’
P8
Machine 7
P1’
P7
Machine 6
P3’
P6
MANSite 1P1
P2’
Site 2P2
P1’
Rack 1Machine 1
P8’
P1
Machine 4
P5’
P4
Machine 3
P6’
P3
Machine 2
P7’
P2
Copyright © 2014, Oracle and/or its affiliates. All rights reserved. | 21
Managed Coherence Servers
• Combined WebLogic and Coherence Infrastructure– WebLogic Management Framework– No Extra License Cost for Coherence Users– Configuration Wizard, WebLogic admin
console, WLST, Node Manager
• Introduces the Grid Archive (GAR)– Package and Deploy
• Coherence “standalone” includes support for GARs
Administrative and Operational Efficiency WebLogic Console
Enterprise Manager
WebLogic Scripting
Coherence
Coherence
Coherence
Coherence
Configure Deploy Start/Stop Monitor
WebLogic WebLogic
WebLogic Management Framework for Coherence
Copyright © 2014, Oracle and/or its affiliates. All rights reserved. |
Enterprise Manager 12c for Coherence
CoherenceJVM Diagnostics
Monitoring Across Coherence Data Grids
SLAs for CompositeJava/Cache Applications
Coherence Configuration Management
Provisioning Coherence
DiagnosticsImages to MOS
Copyright © 2014, Oracle and/or its affiliates. All rights reserved. | 23
• Controlled at business services level
• Fine grained control for composite services
• Only cache subset of final result of composite service
• Requires no code change• Service results cached using
xquery applied to requests• Supports expiration policies
Service Result Caching improves response time, offloads servicesOracle Service Bus Checkbox Integration
Copyright © 2014, Oracle and/or its affiliates. All rights reserved. |
Join the Coherence Community
Visit us at: coherence.oracle.com
Oracle CoherenceUsers
/OracleCoherence@OracleCoherence blogs.oracle.com/OracleCoherence
/OracleCoherence
Copyright © 2014, Oracle and/or its affiliates. All rights reserved. | 25