SlideShare a Scribd company logo
1 of 31
Download to read offline
Powering Your Application with XAP
(Using payment processing as an example)
โ€œDonโ€™t call me cacheโ€
Dotan Horovits
Director, Customer Services
Senior solutions architect
About me
Dotan Horovits
Director, Customer Services
Senior system and solutions architect
technology evangelist with interest in many things
โ€ข distributed high-performance systems
โ€ข big data solutions
โ€ข cloud technologies
โ€ข And of course: agile software methodologies
โ€ข And much moreโ€ฆ
dotan@gigaspaces.com
horovits.wordpress.com
@horovits
Short Intro to Caching Evolution
Cache
In process caching
of Key->Value data
structure
Distribute Cache
Partitioned cache
nodes
IMDG
Partitioned system
of record
In Memory
Application Platform
Collocated IMDG and
Processing
Cache
Cache is good for repetitive data reads
But it is limited in capacity
It also doesnโ€™t handle write-heavy scenarios
Short Intro to Caching Evolution
Cache
In process caching
of Key->Value data
structure
Distribute Cache
Partitioned cache
nodes
IMDG
Partitioned system
of record
In Memory
Application Platform
Collocated IMDG and
Processing
Distribute Cache
Allows you to distribute your cache over numerous machines so you get
Increased Capacity
But it doesnโ€™t support write heavy scenarios
Itโ€™s also Limited to query by Id
What about the rest of your app? - Business logic & messaging??
Short Intro to Caching Evolution
Cache
In process caching
of Key->Value data
structure
Distribute Cache
Partitioned cache
nodes
IMDG
Partitioned system
of record
In Memory
Application Platform
Collocated IMDG and
Processing
IMDG solves these problems!
You get increased capacity
IMDG is also a System of Record with:
Query APIs
Optimized data access
Data integrity
It solves your write scalability problem
.
Short Intro to Caching Evolution
Cache
In process caching
of Key->Value data
structure
Distribute Cache
Partitioned cache
nodes
IMDG
Partitioned system
of record
In Memory
Application Platform
Collocated IMDG and
Processing
In Memory Application Platform
XAP for end to end scaling
Its an IMDG that hosts your Business
logic & has messaging services!
It Provides Parallel processing of data
You get linear scalability
You get high availability
How does XAP work?
Hereโ€™s What a Payment Authorization Process Looks Like
Payment
Authorization
Request
Basic Validation User Profile Check
Merchant
Profile Check
Payment
Authorization
Approved
Write the Payment Object to XAP
Cash Register
Application Payment
User payment Cluster
@SpaceId()
public Long getId() {
return id;
}
@SpaceRouting
public Long getUserId() {
return userId;
}
}
@SpaceIndex
public Long getCardId() {
return cardId;
}
}
The primary key of this object in the grid
The grid will use this attribute to route
the object to a particular partition
Payment object
A secondary index for query optimization
Write the Payment Object to XAP
Cash Register
Application
User payment Cluster
Payment
@SpaceId
public Long getId() {
return id;
}
@SpaceRouting
public Long getUserId() {
return userId;
}
@SpaceIndex
public Long getCardId() {
return cardId;
}
The primary key of this object in the grid
The grid will use this attribute to route
the object to a particular partition
Payment object
A Secondary index for query optimization
Write the Payment Object to XAP
Cash Register
Application
User payment Cluster
Payment
Index
@SpaceId
public Long getId() {
return id;
}
@SpaceRouting
public Long getUserId() {
return userId;
}
@SpaceIndex
public Long getCardId() {
return cardId;
}
The primary key of this object in the grid
The grid will use this attribute to route
the object to a particular partition
Payment object
A Secondary index for query optimization
Let's Talk About Data Model for a Second
User Id (Routing)| User Name|โ€ฆ
Card Id| Card Data | UserID (Routing)โ€ฆ
Transaction ID | CardId | User ID (Routing)โ€ฆ
1 ๏ƒ  *
1 ๏ƒ  *
Data Model
Let's Get Back to the Process
Payment Validation
@EventTemplate
public SQLQuery<Payment> getNewPayment()
{
SQLQuery<Payment> query = new SQLQuery<Payment>(Payment.class," paymentStatus = ? ");
query.setParameter(1, Payment.PaymentStatus.New);
return query;
}
Queue
Payment
Validator
Payment Validation
@SpaceDataEvent
public Payment validatePayment(Payment payment)
{
โ€ฆ
}
private boolean basicPaymentValidation(Payment payment, User user, Card card)
{
โ€ฆ
}
Queue
Payment
Class PaymentAuthorization{
Status status;
Boolean userCheck;
Boolean vendorCheck;
}
Validator
Payment Authorization
Basic Validation
if (basicPaymentValidation(payment,user,card)) {
gigaSpace.write(userPaymentMsg);
gigaSpace.write(vendorPaymentMsg);
gigaSpace.write(paymentAuthorization);
payment.setPaymentStatus(Payment.PaymentStatus.Processing);
} else {
payment.setPaymentStatus(Payment.PaymentStatus.SuspectedFraud);
}
Class PaymentAuthorization {
Status status;
Boolean userCheck;
Boolean vendorCheck;
}
User
Validation
Vendor
Validation
Payment
Authorization
Queue
Queue
Queue Validator
User Validation
Class PaymentAuthorization{
Enum Status
Boolean userCheck
Boolean vendorCheck
}
Read
Message
Process
Queue
UserCreditCardPayment
Querying
@SpaceDataEvent
public void validateUser(UserPaymentMsg event) {
โ€ฆ
space.readMultiple(new Card(userId))
space.readMultiple(new Payment(userId))
if (valid()) {
IdQuery<PaymentAutjorzation> idQuery = new
IdQuery<PaymentAuthorization>(PaymentAuthoirzation.class, paymentId);
space.change(idQuery, new ChangeSet().set(โ€œuserCheck", true));
} else { ... }
}
User Validation
Read
Message
Process
Queue
UserCreditCardPayment
Class PaymentAuthorization {
Status status;
Boolean userCheck;
Boolean vendorCheck;
}
Querying
@SpaceDataEvent
public void validateUser(UserPaymentMsg event) {
โ€ฆ
space.readMultiple(new Card(userId))
space.readMultiple(new Payment(userId))
if (valid()) {
IdQuery<PaymentAutjorzation> idQuery = new
IdQuery<PaymentAuthorization>(PaymentAuthoirzation.class, paymentId);
space.change(idQuery, new ChangeSet().set(โ€œuserCheck", true));
} else { ... }
}
User Validation
Read
Message
Process
Queue
UserCreditCardPayment
@SpaceDataEvent
public void validateUser(UserPaymentMsg event) {
โ€ฆ
space.readMultiple(new Card(userId))
space.readMultiple(new Payment(userId))
if (valid()) {
IdQuery<PaymentAutjorzation> idQuery = new
IdQuery<PaymentAuthorization>(PaymentAuthorization.class, paymentId);
space.change(idQuery, new ChangeSet().set(โ€œuserCheck", true));
} else { ... }
}
Class PaymentAuthorization {
Status status;
Boolean userCheck;
Boolean vendorCheck;
}
Querying
Vendor Validation
@SpaceDataEvent
public void validateVendor(VendorPaymentMsg vendorPaymentMsg) {
AsyncFuture<Boolean> future = vendorGigaSpace.execute(
new VendorValidationTask(vendorPaymentMsg),
vendorPaymentMsg.getMerchant());
IdQuery<PaymentAuthorization> idQuery = new
IdQuery<PaymentAuthorization>(PaymentAuthorization.class,
vendorPaymentMsg.getPaymentId());
if (future.get()) gigaSpace.change(idQuery, new ChangeSet().
set("vendorCheck", true));
else gigaSpace.change(idQuery, new ChangeSet().
set("vendorCheckโ€, false));
}
Read
Message
Process
Queue
Task
class PaymentAuthoirzation {
Status status;
Boolean userCheck;
Boolean vendorCheck;
}
Vendor Validation
@SpaceDataEvent
public void processVendorPaymentValidation() {
AsyncFuture<Boolean> result= space.execute(
new DistributedTask(new VendorValidationTask(Payment)))
if (result.get()) {
IdQuery<PaymentAutjorzation> idQuery = new
IdQuery<PaymentAuthorization>(PaymentAuthorization.class,
paymentId);
space.change(idQuery, new ChangeSet().set(โ€œvendorCheckโ€, true));
} else { ... }
}
Payment Cluster
Task
Vendor Cluster
Class PaymentAuthorization {
Status status;
Boolean userCheck;
Boolean vendorCheck;
}
Vendor Validation
public void validateVendor(VendorPaymentMsg vendorPaymentMsg,
GigaSpace gigaSpace) {
AsyncFuture<Boolean> future = vendorGigaSpace.execute(new
VendorValidationTask(vendorPaymentMsg),
vendorPaymentMsg.getMerchant());
IdQuery<PaymentAuthorization> idQuery = new
IdQuery<PaymentAuthorization>(PaymentAuthorization.class,
vendorPaymentMsg.getPaymentId());
if (future.get()) gigaSpace.change(idQuery, new
ChangeSet().set("vendorCheck", true));
else gigaSpace.change(idQuery, new ChangeSet().set("vendorCheck", false));
}
Payment Cluster Vendor Cluster
Task
Class PaymentAuthorization {
Status status;
Boolean userCheck;
Boolean vendorCheck;
}
Vendor Validation
Payment Cluster Vendor Cluster
Task
public void validateVendor(VendorPaymentMsg vendorPaymentMsg,
GigaSpace gigaSpace) {
AsyncFuture<Boolean> future = vendorGigaSpace.execute(new
VendorValidationTask(vendorPaymentMsg),
vendorPaymentMsg.getMerchant());
IdQuery<PaymentAuthorization> idQuery = new
IdQuery<PaymentAuthorization>(PaymentAuthorization.class,
vendorPaymentMsg.getPaymentId());
if (future.get()) gigaSpace.change(idQuery, new
ChangeSet().set("vendorCheck", true));
else gigaSpace.change(idQuery, new ChangeSet().set("vendorCheck", false));
}
Class PaymentAuthorization {
Status status;
Boolean userCheck;
Boolean vendorCheck;
}
Vendor Validation Check
@Override
public Boolean execute() throws Exception {
return validatePayment(vendorPaymentMsg);
}
Task
DealsMerchant
Class PaymentAuthorization {
Status status;
Boolean userCheck;
Boolean vendorCheck;
}
Querying
Vendor Validation Check
Task
DealsMerchant
@Override
public Boolean execute() throws Exception {
return validatePayment(vendorPaymentMsg);
}
Class PaymentAuthorization {
Status status;
Boolean userCheck;
Boolean vendorCheck;
}
Querying
Vendor Validation
Payment Cluster Vendor Cluster
Callback Task
public void validateVendor(VendorPaymentMsg vendorPaymentMsg,
GigaSpace gigaSpace) {
AsyncFuture<Boolean> future = vendorGigaSpace.execute(new
VendorValidationTask(vendorPaymentMsg),
vendorPaymentMsg.getMerchant());
IdQuery<PaymentAuthorization> idQuery = new
IdQuery<PaymentAuthorization>(PaymentAuthorization.class,
vendorPaymentMsg.getPaymentId());
if (future.get()) gigaSpace.change(idQuery, new
ChangeSet().set("vendorCheck", true));
else gigaSpace.change(idQuery, new ChangeSet().set("vendorCheck", false));
}
Class PaymentAuthorization {
Status status;
Boolean userCheck;
Boolean vendorCheck;
}
Yey! Payment Has Been Authorized
@EventTemplate
public PaymentAuthorization getNewPayment() {
return new PaymentAuthorization(null, true, true, PaymentAuthorizationStatus.New);
}
Queue
Payment
Authorization
Yey! Payment Has Been Authorized
@SpaceDataEvent
public void completePaymentValidation(PaymentAuthorization paymentAuthorization) {
Payment payment = gigaSpace.readById(Payment.class,paymentAuthorization.getPaymentId());
payment.setPaymentStatus(Payment.PaymentStatus.Closed);
gigaSpace.write(payment);
paymentAuthorization.setPaymentAuthorizationStatus(
PaymentAuthorization.PaymentAuthorizationStatus.Done);
}
Queue
Payment
Authorization
Whatโ€™s next?
โ€ข Multi-site deployment?
โ€ข Persistence to DB for auditing?
โ€ข Using Scala? .NET? scripts?
โ€ข Schema evolution?
โ€ข Running our clusters on the cloud?
โ€ข Etc.
Q&A
Source code (Java) publically available on GitHub:
https://github.com/Gigaspaces/fraud-detection-example
Thank you!
Dotan Horovits
dotan@gigaspaces.com
horovits.wordpress.com
@horovits

More Related Content

Viewers also liked

ASAS 2013 - There's no architecture, only business
ASAS 2013 - There's no architecture, only businessASAS 2013 - There's no architecture, only business
ASAS 2013 - There's no architecture, only business
Avisi B.V.
ย 
ASAS 2013 - Architecture for dynamic mobile forms at MoreApps
ASAS 2013 - Architecture for dynamic mobile forms at MoreApps ASAS 2013 - Architecture for dynamic mobile forms at MoreApps
ASAS 2013 - Architecture for dynamic mobile forms at MoreApps
Avisi B.V.
ย 
20100918 android cache
20100918 android cache20100918 android cache
20100918 android cache
rroijnoigntroie
ย 
ASAS 2013- Building a culture of lean innovation
ASAS 2013- Building a culture of lean innovationASAS 2013- Building a culture of lean innovation
ASAS 2013- Building a culture of lean innovation
Avisi B.V.
ย 
ASAS 2013 - Agility and the essence of software architecture
ASAS 2013 - Agility and the essence of software architectureASAS 2013 - Agility and the essence of software architecture
ASAS 2013 - Agility and the essence of software architecture
Avisi B.V.
ย 
ASAS 2013 - Space-based architecture: Linear scalability? High throughput? Lo...
ASAS 2013 - Space-based architecture: Linear scalability? High throughput? Lo...ASAS 2013 - Space-based architecture: Linear scalability? High throughput? Lo...
ASAS 2013 - Space-based architecture: Linear scalability? High throughput? Lo...
Avisi B.V.
ย 

Viewers also liked (19)

ASAS 2015 Darren Harris
ASAS 2015 Darren HarrisASAS 2015 Darren Harris
ASAS 2015 Darren Harris
ย 
ASAS 2013 - There's no architecture, only business
ASAS 2013 - There's no architecture, only businessASAS 2013 - There's no architecture, only business
ASAS 2013 - There's no architecture, only business
ย 
ASAS 2013 - Architecture for dynamic mobile forms at MoreApps
ASAS 2013 - Architecture for dynamic mobile forms at MoreApps ASAS 2013 - Architecture for dynamic mobile forms at MoreApps
ASAS 2013 - Architecture for dynamic mobile forms at MoreApps
ย 
20100918 android cache
20100918 android cache20100918 android cache
20100918 android cache
ย 
What's new in Android M
What's new in Android MWhat's new in Android M
What's new in Android M
ย 
ASAS 2013- Building a culture of lean innovation
ASAS 2013- Building a culture of lean innovationASAS 2013- Building a culture of lean innovation
ASAS 2013- Building a culture of lean innovation
ย 
ASAS 2013 - Agility and the essence of software architecture
ASAS 2013 - Agility and the essence of software architectureASAS 2013 - Agility and the essence of software architecture
ASAS 2013 - Agility and the essence of software architecture
ย 
Android Data Binding
Android Data BindingAndroid Data Binding
Android Data Binding
ย 
Advance Java-Network Programming
Advance Java-Network ProgrammingAdvance Java-Network Programming
Advance Java-Network Programming
ย 
ASAS 2013 - Space-based architecture: Linear scalability? High throughput? Lo...
ASAS 2013 - Space-based architecture: Linear scalability? High throughput? Lo...ASAS 2013 - Space-based architecture: Linear scalability? High throughput? Lo...
ASAS 2013 - Space-based architecture: Linear scalability? High throughput? Lo...
ย 
REST
RESTREST
REST
ย 
Gradle Introduction
Gradle IntroductionGradle Introduction
Gradle Introduction
ย 
Kotlin ะดะปั Android
Kotlin ะดะปั AndroidKotlin ะดะปั Android
Kotlin ะดะปั Android
ย 
Wrapper class
Wrapper classWrapper class
Wrapper class
ย 
Effective Java
Effective JavaEffective Java
Effective Java
ย 
ASAS 2014 - Sander Hoogendoorn
ASAS 2014 - Sander HoogendoornASAS 2014 - Sander Hoogendoorn
ASAS 2014 - Sander Hoogendoorn
ย 
JPA Best Practices
JPA Best PracticesJPA Best Practices
JPA Best Practices
ย 
Dagger 2
Dagger 2Dagger 2
Dagger 2
ย 
JSON and REST
JSON and RESTJSON and REST
JSON and REST
ย 

Similar to Dont call me cache java version

Jasigsakai12 columbia-customizes-cas
Jasigsakai12 columbia-customizes-casJasigsakai12 columbia-customizes-cas
Jasigsakai12 columbia-customizes-cas
ellentuck
ย 
Evolving your Data Access with MongoDB Stitch
Evolving your Data Access with MongoDB StitchEvolving your Data Access with MongoDB Stitch
Evolving your Data Access with MongoDB Stitch
MongoDB
ย 

Similar to Dont call me cache java version (20)

[WSO2Con Asia 2018] Patterns for Building Streaming Apps
[WSO2Con Asia 2018] Patterns for Building Streaming Apps[WSO2Con Asia 2018] Patterns for Building Streaming Apps
[WSO2Con Asia 2018] Patterns for Building Streaming Apps
ย 
CDI @javaonehyderabad
CDI @javaonehyderabadCDI @javaonehyderabad
CDI @javaonehyderabad
ย 
Domain-Driven Design with SeedStack
Domain-Driven Design with SeedStackDomain-Driven Design with SeedStack
Domain-Driven Design with SeedStack
ย 
Dependency injection - the right way
Dependency injection - the right wayDependency injection - the right way
Dependency injection - the right way
ย 
Siddhi - cloud-native stream processor
Siddhi - cloud-native stream processorSiddhi - cloud-native stream processor
Siddhi - cloud-native stream processor
ย 
MongoDB.local Sydney: Evolving your Data Access with MongoDB Stitch
MongoDB.local Sydney: Evolving your Data Access with MongoDB StitchMongoDB.local Sydney: Evolving your Data Access with MongoDB Stitch
MongoDB.local Sydney: Evolving your Data Access with MongoDB Stitch
ย 
Java/Scala Lab: ะ‘ะพั€ะธั ะขั€ะพั„ะธะผะพะฒ - ะžะฑะถะธะณะฐัŽั‰ะฐั Big Data.
Java/Scala Lab: ะ‘ะพั€ะธั ะขั€ะพั„ะธะผะพะฒ - ะžะฑะถะธะณะฐัŽั‰ะฐั Big Data.Java/Scala Lab: ะ‘ะพั€ะธั ะขั€ะพั„ะธะผะพะฒ - ะžะฑะถะธะณะฐัŽั‰ะฐั Big Data.
Java/Scala Lab: ะ‘ะพั€ะธั ะขั€ะพั„ะธะผะพะฒ - ะžะฑะถะธะณะฐัŽั‰ะฐั Big Data.
ย 
[WSO2Con EU 2017] Streaming Analytics Patterns for Your Digital Enterprise
[WSO2Con EU 2017] Streaming Analytics Patterns for Your Digital Enterprise[WSO2Con EU 2017] Streaming Analytics Patterns for Your Digital Enterprise
[WSO2Con EU 2017] Streaming Analytics Patterns for Your Digital Enterprise
ย 
Domain Driven Design 101
Domain Driven Design 101Domain Driven Design 101
Domain Driven Design 101
ย 
LJC Conference 2014 Cassandra for Java Developers
LJC Conference 2014 Cassandra for Java DevelopersLJC Conference 2014 Cassandra for Java Developers
LJC Conference 2014 Cassandra for Java Developers
ย 
HTML5 Gaming Payment Platforms
HTML5 Gaming Payment PlatformsHTML5 Gaming Payment Platforms
HTML5 Gaming Payment Platforms
ย 
Dublin Ireland Spark Meetup October 15, 2015
Dublin Ireland Spark Meetup October 15, 2015Dublin Ireland Spark Meetup October 15, 2015
Dublin Ireland Spark Meetup October 15, 2015
ย 
Jasigsakai12 columbia-customizes-cas
Jasigsakai12 columbia-customizes-casJasigsakai12 columbia-customizes-cas
Jasigsakai12 columbia-customizes-cas
ย 
MongoDB.local Atlanta: Introduction to Serverless MongoDB
MongoDB.local Atlanta: Introduction to Serverless MongoDBMongoDB.local Atlanta: Introduction to Serverless MongoDB
MongoDB.local Atlanta: Introduction to Serverless MongoDB
ย 
Evolving your Data Access with MongoDB Stitch
Evolving your Data Access with MongoDB StitchEvolving your Data Access with MongoDB Stitch
Evolving your Data Access with MongoDB Stitch
ย 
GraphQL Summit 2019 - Configuration Driven Data as a Service Gateway with Gra...
GraphQL Summit 2019 - Configuration Driven Data as a Service Gateway with Gra...GraphQL Summit 2019 - Configuration Driven Data as a Service Gateway with Gra...
GraphQL Summit 2019 - Configuration Driven Data as a Service Gateway with Gra...
ย 
2012 SVCodeCamp: In App Payments with HTML5
2012 SVCodeCamp: In App Payments with HTML52012 SVCodeCamp: In App Payments with HTML5
2012 SVCodeCamp: In App Payments with HTML5
ย 
Introduction to Domain driven design (LaravelBA #5)
Introduction to Domain driven design (LaravelBA #5)Introduction to Domain driven design (LaravelBA #5)
Introduction to Domain driven design (LaravelBA #5)
ย 
Building the an End-to-End ASP.NET MVC 4, Entity Framework, HTML5, jQuery app...
Building the an End-to-End ASP.NET MVC 4, Entity Framework, HTML5, jQuery app...Building the an End-to-End ASP.NET MVC 4, Entity Framework, HTML5, jQuery app...
Building the an End-to-End ASP.NET MVC 4, Entity Framework, HTML5, jQuery app...
ย 
Relevance trilogy may dream be with you! (dec17)
Relevance trilogy  may dream be with you! (dec17)Relevance trilogy  may dream be with you! (dec17)
Relevance trilogy may dream be with you! (dec17)
ย 

More from Avisi B.V.

Scaling Your Team and Technology: The Agile Way - Erik Duindam
Scaling Your Team and Technology: The Agile Way - Erik DuindamScaling Your Team and Technology: The Agile Way - Erik Duindam
Scaling Your Team and Technology: The Agile Way - Erik Duindam
Avisi B.V.
ย 
Bigger product is better - Viktor Grgric
Bigger product is better  - Viktor GrgricBigger product is better  - Viktor Grgric
Bigger product is better - Viktor Grgric
Avisi B.V.
ย 
Product development insights - Robin van Breukelen
Product development insights - Robin van BreukelenProduct development insights - Robin van Breukelen
Product development insights - Robin van Breukelen
Avisi B.V.
ย 
Software design patterns and lessons learned from nature - Jaromil
Software design patterns and lessons learned from nature - JaromilSoftware design patterns and lessons learned from nature - Jaromil
Software design patterns and lessons learned from nature - Jaromil
Avisi B.V.
ย 
Content must be creative - Jon Westenberg
Content must be creative - Jon WestenbergContent must be creative - Jon Westenberg
Content must be creative - Jon Westenberg
Avisi B.V.
ย 
Does your design smell - Tushar Sharma
Does your design smell  - Tushar SharmaDoes your design smell  - Tushar Sharma
Does your design smell - Tushar Sharma
Avisi B.V.
ย 
How to become a Product Samurai - Chris Lukassen
How to become a Product Samurai - Chris LukassenHow to become a Product Samurai - Chris Lukassen
How to become a Product Samurai - Chris Lukassen
Avisi B.V.
ย 
Keynote ASAS 2015 Ted Neward
Keynote ASAS 2015 Ted NewardKeynote ASAS 2015 Ted Neward
Keynote ASAS 2015 Ted Neward
Avisi B.V.
ย 

More from Avisi B.V. (20)

Scaling Your Team and Technology: The Agile Way - Erik Duindam
Scaling Your Team and Technology: The Agile Way - Erik DuindamScaling Your Team and Technology: The Agile Way - Erik Duindam
Scaling Your Team and Technology: The Agile Way - Erik Duindam
ย 
Bigger product is better - Viktor Grgric
Bigger product is better  - Viktor GrgricBigger product is better  - Viktor Grgric
Bigger product is better - Viktor Grgric
ย 
Product development insights - Robin van Breukelen
Product development insights - Robin van BreukelenProduct development insights - Robin van Breukelen
Product development insights - Robin van Breukelen
ย 
Software design patterns and lessons learned from nature - Jaromil
Software design patterns and lessons learned from nature - JaromilSoftware design patterns and lessons learned from nature - Jaromil
Software design patterns and lessons learned from nature - Jaromil
ย 
Content must be creative - Jon Westenberg
Content must be creative - Jon WestenbergContent must be creative - Jon Westenberg
Content must be creative - Jon Westenberg
ย 
Does your design smell - Tushar Sharma
Does your design smell  - Tushar SharmaDoes your design smell  - Tushar Sharma
Does your design smell - Tushar Sharma
ย 
How to become a Product Samurai - Chris Lukassen
How to become a Product Samurai - Chris LukassenHow to become a Product Samurai - Chris Lukassen
How to become a Product Samurai - Chris Lukassen
ย 
ASAS 2015 Gert Florijn & Eelco Rommes
ASAS 2015 Gert Florijn & Eelco RommesASAS 2015 Gert Florijn & Eelco Rommes
ASAS 2015 Gert Florijn & Eelco Rommes
ย 
ASAS 2015 - Benito de Miranda
ASAS 2015 - Benito de MirandaASAS 2015 - Benito de Miranda
ASAS 2015 - Benito de Miranda
ย 
ASAS 2015 Stanimira Jelezova
ASAS 2015 Stanimira JelezovaASAS 2015 Stanimira Jelezova
ASAS 2015 Stanimira Jelezova
ย 
ASAS 2015 Regina Chien
ASAS 2015 Regina ChienASAS 2015 Regina Chien
ASAS 2015 Regina Chien
ย 
ASAS 2015 Henk Kolk
ASAS 2015 Henk KolkASAS 2015 Henk Kolk
ASAS 2015 Henk Kolk
ย 
ASAS 2015 Chris Lukassen
ASAS 2015 Chris LukassenASAS 2015 Chris Lukassen
ASAS 2015 Chris Lukassen
ย 
ASAS 2015 Chris Lukassen
ASAS 2015 Chris LukassenASAS 2015 Chris Lukassen
ASAS 2015 Chris Lukassen
ย 
Keynote ASAS 2015 Ted Neward
Keynote ASAS 2015 Ted NewardKeynote ASAS 2015 Ted Neward
Keynote ASAS 2015 Ted Neward
ย 
ASAS 2015 Robin van Breukelen
ASAS 2015 Robin van BreukelenASAS 2015 Robin van Breukelen
ASAS 2015 Robin van Breukelen
ย 
ASAS 2015 - Kasia Mrowca
ASAS 2015 - Kasia MrowcaASAS 2015 - Kasia Mrowca
ASAS 2015 - Kasia Mrowca
ย 
ASAS 2015 - Norberto Leite
ASAS 2015 - Norberto LeiteASAS 2015 - Norberto Leite
ASAS 2015 - Norberto Leite
ย 
ASAS 2015 - Maarten van den Heuvel
ASAS 2015 - Maarten van den HeuvelASAS 2015 - Maarten van den Heuvel
ASAS 2015 - Maarten van den Heuvel
ย 
Keynote ASAS 2015 - Viktor Grgic
Keynote ASAS 2015 - Viktor Grgic  Keynote ASAS 2015 - Viktor Grgic
Keynote ASAS 2015 - Viktor Grgic
ย 

Recently uploaded

VIP Independent Call Girls in Andheri ๐ŸŒน 9920725232 ( Call Me ) Mumbai Escorts...
VIP Independent Call Girls in Andheri ๐ŸŒน 9920725232 ( Call Me ) Mumbai Escorts...VIP Independent Call Girls in Andheri ๐ŸŒน 9920725232 ( Call Me ) Mumbai Escorts...
VIP Independent Call Girls in Andheri ๐ŸŒน 9920725232 ( Call Me ) Mumbai Escorts...
dipikadinghjn ( Why You Choose Us? ) Escorts
ย 
VIP Call Girl Service Andheri West โšก 9920725232 What It Takes To Be The Best ...
VIP Call Girl Service Andheri West โšก 9920725232 What It Takes To Be The Best ...VIP Call Girl Service Andheri West โšก 9920725232 What It Takes To Be The Best ...
VIP Call Girl Service Andheri West โšก 9920725232 What It Takes To Be The Best ...
dipikadinghjn ( Why You Choose Us? ) Escorts
ย 
VIP Independent Call Girls in Mira Bhayandar ๐ŸŒน 9920725232 ( Call Me ) Mumbai ...
VIP Independent Call Girls in Mira Bhayandar ๐ŸŒน 9920725232 ( Call Me ) Mumbai ...VIP Independent Call Girls in Mira Bhayandar ๐ŸŒน 9920725232 ( Call Me ) Mumbai ...
VIP Independent Call Girls in Mira Bhayandar ๐ŸŒน 9920725232 ( Call Me ) Mumbai ...
dipikadinghjn ( Why You Choose Us? ) Escorts
ย 
From Luxury Escort Service Kamathipura : 9352852248 Make on-demand Arrangemen...
From Luxury Escort Service Kamathipura : 9352852248 Make on-demand Arrangemen...From Luxury Escort Service Kamathipura : 9352852248 Make on-demand Arrangemen...
From Luxury Escort Service Kamathipura : 9352852248 Make on-demand Arrangemen...
From Luxury Escort : 9352852248 Make on-demand Arrangements Near yOU
ย 
VIP Independent Call Girls in Mumbai ๐ŸŒน 9920725232 ( Call Me ) Mumbai Escorts ...
VIP Independent Call Girls in Mumbai ๐ŸŒน 9920725232 ( Call Me ) Mumbai Escorts ...VIP Independent Call Girls in Mumbai ๐ŸŒน 9920725232 ( Call Me ) Mumbai Escorts ...
VIP Independent Call Girls in Mumbai ๐ŸŒน 9920725232 ( Call Me ) Mumbai Escorts ...
dipikadinghjn ( Why You Choose Us? ) Escorts
ย 
Call Girls in New Ashok Nagar, (delhi) call me [9953056974] escort service 24X7
Call Girls in New Ashok Nagar, (delhi) call me [9953056974] escort service 24X7Call Girls in New Ashok Nagar, (delhi) call me [9953056974] escort service 24X7
Call Girls in New Ashok Nagar, (delhi) call me [9953056974] escort service 24X7
9953056974 Low Rate Call Girls In Saket, Delhi NCR
ย 
VIP Call Girl in Mira Road ๐Ÿ’ง 9920725232 ( Call Me ) Get A New Crush Everyday ...
VIP Call Girl in Mira Road ๐Ÿ’ง 9920725232 ( Call Me ) Get A New Crush Everyday ...VIP Call Girl in Mira Road ๐Ÿ’ง 9920725232 ( Call Me ) Get A New Crush Everyday ...
VIP Call Girl in Mira Road ๐Ÿ’ง 9920725232 ( Call Me ) Get A New Crush Everyday ...
dipikadinghjn ( Why You Choose Us? ) Escorts
ย 

Recently uploaded (20)

The Economic History of the U.S. Lecture 19.pdf
The Economic History of the U.S. Lecture 19.pdfThe Economic History of the U.S. Lecture 19.pdf
The Economic History of the U.S. Lecture 19.pdf
ย 
VIP Independent Call Girls in Andheri ๐ŸŒน 9920725232 ( Call Me ) Mumbai Escorts...
VIP Independent Call Girls in Andheri ๐ŸŒน 9920725232 ( Call Me ) Mumbai Escorts...VIP Independent Call Girls in Andheri ๐ŸŒน 9920725232 ( Call Me ) Mumbai Escorts...
VIP Independent Call Girls in Andheri ๐ŸŒน 9920725232 ( Call Me ) Mumbai Escorts...
ย 
TEST BANK For Corporate Finance, 13th Edition By Stephen Ross, Randolph Weste...
TEST BANK For Corporate Finance, 13th Edition By Stephen Ross, Randolph Weste...TEST BANK For Corporate Finance, 13th Edition By Stephen Ross, Randolph Weste...
TEST BANK For Corporate Finance, 13th Edition By Stephen Ross, Randolph Weste...
ย 
The Economic History of the U.S. Lecture 17.pdf
The Economic History of the U.S. Lecture 17.pdfThe Economic History of the U.S. Lecture 17.pdf
The Economic History of the U.S. Lecture 17.pdf
ย 
VIP Call Girl Service Andheri West โšก 9920725232 What It Takes To Be The Best ...
VIP Call Girl Service Andheri West โšก 9920725232 What It Takes To Be The Best ...VIP Call Girl Service Andheri West โšก 9920725232 What It Takes To Be The Best ...
VIP Call Girl Service Andheri West โšก 9920725232 What It Takes To Be The Best ...
ย 
The Economic History of the U.S. Lecture 21.pdf
The Economic History of the U.S. Lecture 21.pdfThe Economic History of the U.S. Lecture 21.pdf
The Economic History of the U.S. Lecture 21.pdf
ย 
The Economic History of the U.S. Lecture 18.pdf
The Economic History of the U.S. Lecture 18.pdfThe Economic History of the U.S. Lecture 18.pdf
The Economic History of the U.S. Lecture 18.pdf
ย 
VIP Independent Call Girls in Mira Bhayandar ๐ŸŒน 9920725232 ( Call Me ) Mumbai ...
VIP Independent Call Girls in Mira Bhayandar ๐ŸŒน 9920725232 ( Call Me ) Mumbai ...VIP Independent Call Girls in Mira Bhayandar ๐ŸŒน 9920725232 ( Call Me ) Mumbai ...
VIP Independent Call Girls in Mira Bhayandar ๐ŸŒน 9920725232 ( Call Me ) Mumbai ...
ย 
From Luxury Escort Service Kamathipura : 9352852248 Make on-demand Arrangemen...
From Luxury Escort Service Kamathipura : 9352852248 Make on-demand Arrangemen...From Luxury Escort Service Kamathipura : 9352852248 Make on-demand Arrangemen...
From Luxury Escort Service Kamathipura : 9352852248 Make on-demand Arrangemen...
ย 
Mira Road Memorable Call Grls Number-9833754194-Bhayandar Speciallty Call Gir...
Mira Road Memorable Call Grls Number-9833754194-Bhayandar Speciallty Call Gir...Mira Road Memorable Call Grls Number-9833754194-Bhayandar Speciallty Call Gir...
Mira Road Memorable Call Grls Number-9833754194-Bhayandar Speciallty Call Gir...
ย 
The Economic History of the U.S. Lecture 20.pdf
The Economic History of the U.S. Lecture 20.pdfThe Economic History of the U.S. Lecture 20.pdf
The Economic History of the U.S. Lecture 20.pdf
ย 
The Economic History of the U.S. Lecture 26.pdf
The Economic History of the U.S. Lecture 26.pdfThe Economic History of the U.S. Lecture 26.pdf
The Economic History of the U.S. Lecture 26.pdf
ย 
VIP Independent Call Girls in Mumbai ๐ŸŒน 9920725232 ( Call Me ) Mumbai Escorts ...
VIP Independent Call Girls in Mumbai ๐ŸŒน 9920725232 ( Call Me ) Mumbai Escorts ...VIP Independent Call Girls in Mumbai ๐ŸŒน 9920725232 ( Call Me ) Mumbai Escorts ...
VIP Independent Call Girls in Mumbai ๐ŸŒน 9920725232 ( Call Me ) Mumbai Escorts ...
ย 
Indore Real Estate Market Trends Report.pdf
Indore Real Estate Market Trends Report.pdfIndore Real Estate Market Trends Report.pdf
Indore Real Estate Market Trends Report.pdf
ย 
Mira Road Awesome 100% Independent Call Girls NUmber-9833754194-Dahisar Inter...
Mira Road Awesome 100% Independent Call Girls NUmber-9833754194-Dahisar Inter...Mira Road Awesome 100% Independent Call Girls NUmber-9833754194-Dahisar Inter...
Mira Road Awesome 100% Independent Call Girls NUmber-9833754194-Dahisar Inter...
ย 
05_Annelore Lenoir_Docbyte_MeetupDora&Cybersecurity.pptx
05_Annelore Lenoir_Docbyte_MeetupDora&Cybersecurity.pptx05_Annelore Lenoir_Docbyte_MeetupDora&Cybersecurity.pptx
05_Annelore Lenoir_Docbyte_MeetupDora&Cybersecurity.pptx
ย 
Call Girls in New Ashok Nagar, (delhi) call me [9953056974] escort service 24X7
Call Girls in New Ashok Nagar, (delhi) call me [9953056974] escort service 24X7Call Girls in New Ashok Nagar, (delhi) call me [9953056974] escort service 24X7
Call Girls in New Ashok Nagar, (delhi) call me [9953056974] escort service 24X7
ย 
Top Rated Pune Call Girls Viman Nagar โŸŸ 6297143586 โŸŸ Call Me For Genuine Sex...
Top Rated  Pune Call Girls Viman Nagar โŸŸ 6297143586 โŸŸ Call Me For Genuine Sex...Top Rated  Pune Call Girls Viman Nagar โŸŸ 6297143586 โŸŸ Call Me For Genuine Sex...
Top Rated Pune Call Girls Viman Nagar โŸŸ 6297143586 โŸŸ Call Me For Genuine Sex...
ย 
VIP Call Girl in Mira Road ๐Ÿ’ง 9920725232 ( Call Me ) Get A New Crush Everyday ...
VIP Call Girl in Mira Road ๐Ÿ’ง 9920725232 ( Call Me ) Get A New Crush Everyday ...VIP Call Girl in Mira Road ๐Ÿ’ง 9920725232 ( Call Me ) Get A New Crush Everyday ...
VIP Call Girl in Mira Road ๐Ÿ’ง 9920725232 ( Call Me ) Get A New Crush Everyday ...
ย 
03_Emmanuel Ndiaye_Degroof Petercam.pptx
03_Emmanuel Ndiaye_Degroof Petercam.pptx03_Emmanuel Ndiaye_Degroof Petercam.pptx
03_Emmanuel Ndiaye_Degroof Petercam.pptx
ย 

Dont call me cache java version

  • 1. Powering Your Application with XAP (Using payment processing as an example) โ€œDonโ€™t call me cacheโ€ Dotan Horovits Director, Customer Services Senior solutions architect
  • 2. About me Dotan Horovits Director, Customer Services Senior system and solutions architect technology evangelist with interest in many things โ€ข distributed high-performance systems โ€ข big data solutions โ€ข cloud technologies โ€ข And of course: agile software methodologies โ€ข And much moreโ€ฆ dotan@gigaspaces.com horovits.wordpress.com @horovits
  • 3. Short Intro to Caching Evolution Cache In process caching of Key->Value data structure Distribute Cache Partitioned cache nodes IMDG Partitioned system of record In Memory Application Platform Collocated IMDG and Processing Cache Cache is good for repetitive data reads But it is limited in capacity It also doesnโ€™t handle write-heavy scenarios
  • 4. Short Intro to Caching Evolution Cache In process caching of Key->Value data structure Distribute Cache Partitioned cache nodes IMDG Partitioned system of record In Memory Application Platform Collocated IMDG and Processing Distribute Cache Allows you to distribute your cache over numerous machines so you get Increased Capacity But it doesnโ€™t support write heavy scenarios Itโ€™s also Limited to query by Id What about the rest of your app? - Business logic & messaging??
  • 5. Short Intro to Caching Evolution Cache In process caching of Key->Value data structure Distribute Cache Partitioned cache nodes IMDG Partitioned system of record In Memory Application Platform Collocated IMDG and Processing IMDG solves these problems! You get increased capacity IMDG is also a System of Record with: Query APIs Optimized data access Data integrity It solves your write scalability problem .
  • 6. Short Intro to Caching Evolution Cache In process caching of Key->Value data structure Distribute Cache Partitioned cache nodes IMDG Partitioned system of record In Memory Application Platform Collocated IMDG and Processing In Memory Application Platform XAP for end to end scaling Its an IMDG that hosts your Business logic & has messaging services! It Provides Parallel processing of data You get linear scalability You get high availability How does XAP work?
  • 7. Hereโ€™s What a Payment Authorization Process Looks Like Payment Authorization Request Basic Validation User Profile Check Merchant Profile Check Payment Authorization Approved
  • 8. Write the Payment Object to XAP Cash Register Application Payment User payment Cluster @SpaceId() public Long getId() { return id; } @SpaceRouting public Long getUserId() { return userId; } } @SpaceIndex public Long getCardId() { return cardId; } } The primary key of this object in the grid The grid will use this attribute to route the object to a particular partition Payment object A secondary index for query optimization
  • 9. Write the Payment Object to XAP Cash Register Application User payment Cluster Payment @SpaceId public Long getId() { return id; } @SpaceRouting public Long getUserId() { return userId; } @SpaceIndex public Long getCardId() { return cardId; } The primary key of this object in the grid The grid will use this attribute to route the object to a particular partition Payment object A Secondary index for query optimization
  • 10. Write the Payment Object to XAP Cash Register Application User payment Cluster Payment Index @SpaceId public Long getId() { return id; } @SpaceRouting public Long getUserId() { return userId; } @SpaceIndex public Long getCardId() { return cardId; } The primary key of this object in the grid The grid will use this attribute to route the object to a particular partition Payment object A Secondary index for query optimization
  • 11. Let's Talk About Data Model for a Second
  • 12. User Id (Routing)| User Name|โ€ฆ Card Id| Card Data | UserID (Routing)โ€ฆ Transaction ID | CardId | User ID (Routing)โ€ฆ 1 ๏ƒ  * 1 ๏ƒ  * Data Model
  • 13. Let's Get Back to the Process
  • 14. Payment Validation @EventTemplate public SQLQuery<Payment> getNewPayment() { SQLQuery<Payment> query = new SQLQuery<Payment>(Payment.class," paymentStatus = ? "); query.setParameter(1, Payment.PaymentStatus.New); return query; } Queue Payment Validator
  • 15. Payment Validation @SpaceDataEvent public Payment validatePayment(Payment payment) { โ€ฆ } private boolean basicPaymentValidation(Payment payment, User user, Card card) { โ€ฆ } Queue Payment Class PaymentAuthorization{ Status status; Boolean userCheck; Boolean vendorCheck; } Validator Payment Authorization
  • 16. Basic Validation if (basicPaymentValidation(payment,user,card)) { gigaSpace.write(userPaymentMsg); gigaSpace.write(vendorPaymentMsg); gigaSpace.write(paymentAuthorization); payment.setPaymentStatus(Payment.PaymentStatus.Processing); } else { payment.setPaymentStatus(Payment.PaymentStatus.SuspectedFraud); } Class PaymentAuthorization { Status status; Boolean userCheck; Boolean vendorCheck; } User Validation Vendor Validation Payment Authorization Queue Queue Queue Validator
  • 17. User Validation Class PaymentAuthorization{ Enum Status Boolean userCheck Boolean vendorCheck } Read Message Process Queue UserCreditCardPayment Querying @SpaceDataEvent public void validateUser(UserPaymentMsg event) { โ€ฆ space.readMultiple(new Card(userId)) space.readMultiple(new Payment(userId)) if (valid()) { IdQuery<PaymentAutjorzation> idQuery = new IdQuery<PaymentAuthorization>(PaymentAuthoirzation.class, paymentId); space.change(idQuery, new ChangeSet().set(โ€œuserCheck", true)); } else { ... } }
  • 18. User Validation Read Message Process Queue UserCreditCardPayment Class PaymentAuthorization { Status status; Boolean userCheck; Boolean vendorCheck; } Querying @SpaceDataEvent public void validateUser(UserPaymentMsg event) { โ€ฆ space.readMultiple(new Card(userId)) space.readMultiple(new Payment(userId)) if (valid()) { IdQuery<PaymentAutjorzation> idQuery = new IdQuery<PaymentAuthorization>(PaymentAuthoirzation.class, paymentId); space.change(idQuery, new ChangeSet().set(โ€œuserCheck", true)); } else { ... } }
  • 19. User Validation Read Message Process Queue UserCreditCardPayment @SpaceDataEvent public void validateUser(UserPaymentMsg event) { โ€ฆ space.readMultiple(new Card(userId)) space.readMultiple(new Payment(userId)) if (valid()) { IdQuery<PaymentAutjorzation> idQuery = new IdQuery<PaymentAuthorization>(PaymentAuthorization.class, paymentId); space.change(idQuery, new ChangeSet().set(โ€œuserCheck", true)); } else { ... } } Class PaymentAuthorization { Status status; Boolean userCheck; Boolean vendorCheck; } Querying
  • 20. Vendor Validation @SpaceDataEvent public void validateVendor(VendorPaymentMsg vendorPaymentMsg) { AsyncFuture<Boolean> future = vendorGigaSpace.execute( new VendorValidationTask(vendorPaymentMsg), vendorPaymentMsg.getMerchant()); IdQuery<PaymentAuthorization> idQuery = new IdQuery<PaymentAuthorization>(PaymentAuthorization.class, vendorPaymentMsg.getPaymentId()); if (future.get()) gigaSpace.change(idQuery, new ChangeSet(). set("vendorCheck", true)); else gigaSpace.change(idQuery, new ChangeSet(). set("vendorCheckโ€, false)); } Read Message Process Queue Task class PaymentAuthoirzation { Status status; Boolean userCheck; Boolean vendorCheck; }
  • 21. Vendor Validation @SpaceDataEvent public void processVendorPaymentValidation() { AsyncFuture<Boolean> result= space.execute( new DistributedTask(new VendorValidationTask(Payment))) if (result.get()) { IdQuery<PaymentAutjorzation> idQuery = new IdQuery<PaymentAuthorization>(PaymentAuthorization.class, paymentId); space.change(idQuery, new ChangeSet().set(โ€œvendorCheckโ€, true)); } else { ... } } Payment Cluster Task Vendor Cluster Class PaymentAuthorization { Status status; Boolean userCheck; Boolean vendorCheck; }
  • 22. Vendor Validation public void validateVendor(VendorPaymentMsg vendorPaymentMsg, GigaSpace gigaSpace) { AsyncFuture<Boolean> future = vendorGigaSpace.execute(new VendorValidationTask(vendorPaymentMsg), vendorPaymentMsg.getMerchant()); IdQuery<PaymentAuthorization> idQuery = new IdQuery<PaymentAuthorization>(PaymentAuthorization.class, vendorPaymentMsg.getPaymentId()); if (future.get()) gigaSpace.change(idQuery, new ChangeSet().set("vendorCheck", true)); else gigaSpace.change(idQuery, new ChangeSet().set("vendorCheck", false)); } Payment Cluster Vendor Cluster Task Class PaymentAuthorization { Status status; Boolean userCheck; Boolean vendorCheck; }
  • 23. Vendor Validation Payment Cluster Vendor Cluster Task public void validateVendor(VendorPaymentMsg vendorPaymentMsg, GigaSpace gigaSpace) { AsyncFuture<Boolean> future = vendorGigaSpace.execute(new VendorValidationTask(vendorPaymentMsg), vendorPaymentMsg.getMerchant()); IdQuery<PaymentAuthorization> idQuery = new IdQuery<PaymentAuthorization>(PaymentAuthorization.class, vendorPaymentMsg.getPaymentId()); if (future.get()) gigaSpace.change(idQuery, new ChangeSet().set("vendorCheck", true)); else gigaSpace.change(idQuery, new ChangeSet().set("vendorCheck", false)); } Class PaymentAuthorization { Status status; Boolean userCheck; Boolean vendorCheck; }
  • 24. Vendor Validation Check @Override public Boolean execute() throws Exception { return validatePayment(vendorPaymentMsg); } Task DealsMerchant Class PaymentAuthorization { Status status; Boolean userCheck; Boolean vendorCheck; } Querying
  • 25. Vendor Validation Check Task DealsMerchant @Override public Boolean execute() throws Exception { return validatePayment(vendorPaymentMsg); } Class PaymentAuthorization { Status status; Boolean userCheck; Boolean vendorCheck; } Querying
  • 26. Vendor Validation Payment Cluster Vendor Cluster Callback Task public void validateVendor(VendorPaymentMsg vendorPaymentMsg, GigaSpace gigaSpace) { AsyncFuture<Boolean> future = vendorGigaSpace.execute(new VendorValidationTask(vendorPaymentMsg), vendorPaymentMsg.getMerchant()); IdQuery<PaymentAuthorization> idQuery = new IdQuery<PaymentAuthorization>(PaymentAuthorization.class, vendorPaymentMsg.getPaymentId()); if (future.get()) gigaSpace.change(idQuery, new ChangeSet().set("vendorCheck", true)); else gigaSpace.change(idQuery, new ChangeSet().set("vendorCheck", false)); } Class PaymentAuthorization { Status status; Boolean userCheck; Boolean vendorCheck; }
  • 27. Yey! Payment Has Been Authorized @EventTemplate public PaymentAuthorization getNewPayment() { return new PaymentAuthorization(null, true, true, PaymentAuthorizationStatus.New); } Queue Payment Authorization
  • 28. Yey! Payment Has Been Authorized @SpaceDataEvent public void completePaymentValidation(PaymentAuthorization paymentAuthorization) { Payment payment = gigaSpace.readById(Payment.class,paymentAuthorization.getPaymentId()); payment.setPaymentStatus(Payment.PaymentStatus.Closed); gigaSpace.write(payment); paymentAuthorization.setPaymentAuthorizationStatus( PaymentAuthorization.PaymentAuthorizationStatus.Done); } Queue Payment Authorization
  • 29. Whatโ€™s next? โ€ข Multi-site deployment? โ€ข Persistence to DB for auditing? โ€ข Using Scala? .NET? scripts? โ€ข Schema evolution? โ€ข Running our clusters on the cloud? โ€ข Etc.
  • 30. Q&A Source code (Java) publically available on GitHub: https://github.com/Gigaspaces/fraud-detection-example