• No results found

Ultra-fast In-Memory Database Applications

N/A
N/A
Protected

Academic year: 2022

Share "Ultra-fast In-Memory Database Applications"

Copied!
63
0
0

Loading.... (view fulltext now)

Full text

(1)

Ultra-fast In-Memory

Database Applications

(2)

Saxony JUG !

Book your microservice framework online training course at Fast Lane for free of charge $0.00 and save $1,899. Check out the schedule, choose any course you like and enroll for

free by using our booking code …

(3)

YEDlyExn

www.microservices.education

Book Any Course for Free !

(4)

Disclaimer

The following is intended to outline our general product direction. It‘s intended for

informational 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 MicroStream‘s products remains at the sole

discretion of MicroStream.

(5)

Markus Kett

About us

Florian Habermann

(6)
(7)
(8)
(9)

Maven Download

(10)

MicroStream now Part of Helidon

Helidon is a fast framework for developing modern cloud-native

microservices with Java. Helidon is mainly developed by Oracle.

(11)

Our Values

(12)

MicroStream History

In Productive Use

2015 MicroStream 5

as Open Source 07 / 2021

Development started 2013

Integration with Project Helidon 09 / 2021

MicroStream for Android

12 / 2019

Product Launch 10 / 2019

Company founded 2019

2013 2014 2015 2016 2017 2018

2019 2020 2021

(13)

Traditional Java Persistence

(14)

Traditional Java Persistence

RDBMS Local Cache

Java VM

OR-Mapping / Data Conversion

App / Microservice

In-Memory DB / Grid Distributed Cache Event Streaming (Kafka)

NoSQL

Key-Value Column JSON

Key-Value Column JSON Graph

Tables Object Graph (RAM)

Objects

Challenge: Storing Objects into

Tables / JSON / Key Value Stores / Graphs

Data Conversion Through Every Single Read & Write !

▪ Requires lots of CPU power

▪ Reduces your performance

▪ Expensive latencies

▪ Complex architecture

▪ Expensive development process

▪ Inefficient concept requires expensive cluster infrastructure

▪ Increase your costs of infrastructure

Millisecond

Query Time

(15)

Traditional Java Persistence

Challenge: Storing Objects into

Tables / JSON / Key Value Stores / Graphs

Data Conversion Through Every Single Read & Write !

In-Memory DB / Grid Distributed Cache Event Streaming (Kafka)

NoSQL

▪ Requires lots of CPU power

▪ Reduces your performance

▪ Expensive latencies

▪ Complex architecture

▪ Expensive development process

▪ Inefficient concept requires expensive cluster infrastructure

▪ Increase your costs of infrastructure

Key-Value Column JSON

Key-Value Column JSON Graph

Tables

RDBMS

Objects

Millisecond

Query Time

(16)

High Development Effort

2 data models (Java classes + DB data model)

Data type mapping

Complex ORM frameworks

Additional caching Layers (local Cache, distributed cache, IMDG)

Complex architecture

Strong limitations (data model design)

Mixing different paradigm, reduntantly and competing concepts

Heavyweight dependencies

Effortful testing and deployment process

(17)

There are various solutions, but they are only a more or less elegant way around the problem. No matter which solution you choose - as long as the systems are different, every developer will

sooner or later get to the point where his solution no longer meets one or more of the following

points: Maintainability, performance, intelligibility.

The Problem of Incompatible Data Structures is Well Known as Impedance Mismatch

https://en.wikipedia.org/wiki/Object%E2%80%93relational_impedance_mismatch

(18)

MicroStream Java-Native Persistence

(19)

MicroStream Persistence

Java VM

MicroStream

App / Microservice

Object Graph (RAM)

Plain File Storage Binaries RDBMS Binaries

Objects Objects Objects

Objects

Streaming Objects Directly Into any Database

Conversion Eliminated !

▪ Simple architecture

▪ Faster time to market

▪ Saves lots of vCPU power

▪ Minimizes latencies

▪ In-memory queries executed in microseconds

▪ Saves up to 92% costs of infrastructure

NoSQL In-Memory DB In-Memory Data Grid Distributed Cache Event Streaming Binaries

1000x faster Queries

Microsecond

Query Time

(20)

www.microstream.one

Accelerating Queries up to 1000x

0.19 ms

Hibernate EHCache Oracle

439.05

Milliseconds JPA – Hibernate

MicroStream -

Oracle

0.19

Milliseconds MicroStream

2260x

Factor

439.05 ms

2.28

Queries / Second

190.11

Queries / Second

83x

Queries / Second

(21)

- 87 .5 %

Only 1 Node !

Today with MicroStream:

Costs of Infrastructure annually

Save up to 90% Cloud Costs

Conventional Cluster for Running a globally App

NoSQL

RDBMS

Traditional Persistence Is

Inefficient. Numerous of Nodes

are Required.

(22)

Simplifies Your Development Process

1 data structure (Java object graph)

1 data model, your object model, POJOs only

Freely design of your Java object-model

No mappings, no impedance mismatch

No ORM framework

Query language: Java Streams API, GraphQL

No local cache needed

Core Java only

(23)

MicroStream Components

MicroStream Persistence for Android

File System Garbage Collector File System Abstraction

Database Connectors Backup

MicroStream Serialization

MicroStream Persistence for the JVM

Legacy Type Mapping REST Interface

MicroStream Storage Browser

(24)

Supported Storages

(25)

Runs Wherever Java Runs

(26)

Use any JVM Technology

(27)

How Does MicroStream Work ?

(28)

Data Model: Just POJOs

(29)

Freely Design Your Object Model

Use any Java type

Use collections

Use object references

Use circle references

Use any object from 3rd party libraries

(30)

Persisting Objects

(31)

Append-only Log

Any Storage Java VM

MicroStream Application

Object Graph (RAM)

(32)

MicroStream Channels

Any Storage

Multithreaded IO Ops

Java VM MicroStream Application

Object Graph (RAM)

4 Cores – 4 Channels

64 Cores – 64 Channels

(33)

Storage Garbage Collector

Any Storage Any Storage

Java VM MicroStream Application

Object Graph (RAM)

(34)

Load any Object-References Dynamically Into RAM

(35)

Queries

1000x faster Queries

Microsecond

Query Time

(36)

MicroStream Features

(37)
(38)

Use Powerful Features From the Java Ecosystem

(39)

Rules & Challenges

(40)

Your Object Graph in RAM is Your Database

Java VM JPA Application

Object Graph (RAM)

Java VM MicroStream Application

Object Graph (RAM)

Traditional Database Server Paradigm Java In-Memory Data Processing Paradigm

Database Server

▪ DBMS

▪ Database

▪ Queries

▪ Persistent Data

Any Storage

▪ Persistent Data

▪ Database (In-Memory)

▪ Queries

Your Database is here, Queries are executed here

Your Database is here,

Queries are executed here

(41)

All In-Memory or Lazy-Loading ?

Storage 1 GB

Java VM MicroStream Application

32 GB RAM

Storage 1000 GB

Java VM MicroStream Application

4 GB RAM

Enough RAM available: Data Storage is bigger than RAM:

Load your entire DB into RAM

Pure in-memory computing

No latencies

Super fast

Lower startup time

Preload most important data only (eager loading)

Use lazy-loading to load data on demand only

Clear lazy references which are not used anymore

Faster startup time

(42)

MicroStream Architecture Rules

1 Node

1 Storage 1 Node

n Storages

n Nodes 1 Storage

Concurrency

Issues on Writes !

(43)

Memory Management

Memory is fully managed by the JVM

Use lazy references if possible

Clear your lazy references which are not used anymore

In case of garbage collector issues, try OpenJ9 or Azul JVM

(44)

Challenges with MicroStream

Built for Java developers

Paradigm shift in database programming

No SQL support

MicroStream is a storage engine, but not a DBMS

Your application must cover DBMS tasks

You must care vor validation

You have to care for concurrency

Not suited for DBAs

(45)

Beyond Persistence …

(46)

MicroStream Serialization

(47)

Java Serialization is the biggest security issue in Java.

50% of all vulnerabilities are linked to serialization.

Mark Reinhold

(48)

Java Serialization was a Horrible Mistake.

Mark Reinhold

Chief Architect of the Java Platform

(49)
(50)

Java VM Java Serialization Malware

Serializable Objects

Sender

Receiver

Java VM

Java Serialization – Deserialization Application / Microservice

Serializable Objects

Java Serialization

(51)

Roadmap

(52)

Distributed Systems with

MicroStream Cluster

(53)

Object Graph Replication

Object Graph

Object Graph

Object Graph

(54)

MicroStream Cluster

(55)

MicroStream Cluster

(56)

MicroStream Cloud

MicroStream Single Storage & MicroStream Cluster

as a Service

(57)

MicroStream Cloud

MicroStream Remote Storage

Gateway

MicroStream Cloud

Platform as a Service

Public / Hybrid Cloud

Storage Customer App

MicroStream Single Storage

as a Service

(58)

MicroStream Cloud

Public / Hybrid Cloud

MicroStream Cloud

Platform as a Service

Container Platform

Storage

MicroStream Cluster

as a Service

(59)

Benefits

Simple setup

Simpler cost control

No cloud know-how required

Fewer DevOp resources required

High-availability

Auto-scale

Fully-managed services

Enterprise-grade security

Production support by MicroStream

(60)

Java VM MicroStream Serialization Application / Microservice

Object Graph (RAM)

Sender

Receiver

Java VM

MicroStream Serialization – Deserialization

Application / Microservice

Object Graph (RAM)

MicroStream Serialization

(61)

Get Started …

(62)

www.youtube.com/c/MicroStream/videos

(63)

Get Started with MicroStream

Learn: www.microstream.one

GitHub: https://github.com/microstream-one/microstream

Doc: https://manual.docs.microstream.one/data-store/getting-started

Videos on YouTube: https://www.youtube.com/c/MicroStream/videos

Free courses at Fast Lane: https://www.microservices.education

References

Related documents

comprehension, namely the retrieval of lexical information from the mental lexicon and the subsequent unification of semantic and syntactic information yield distinct patterns of

The ultimate goal is to explore the meanings, complementation patterns and frequency of distribution of the evidential uses of the top object-oriented perception verbs look and

The International Court of Justice distinguished the concept of state responsibility to prevent genocide from the crime of complicity in genocide established by Article III of

The principle and commitment of ASEAN member countries in defending their citizens' human rights is questionable, if viewed on the principle of non-interverence

Where recklessness marks the boundary of criminal liability for such offences, a belief-centred view of recklessness, which would not enquire into the reasonableness of

Findings focus on gender specific experiences of policing in the city, citizen complaints about the Milwaukee Police Department, and participant driven ideas to reinstate

• Current link schema for MediaWiki install:.

Mason does not dispute that its breach allegations relate to DAZ’s services and deliverables and it does not dispute that these allegations concern DAZ’s