Java-Native Persistence

Create ultra-fast in-memory database apps & microservices with pure Java

MicroStream 2.0 final release is now available
Getting Started

What's the problem with data storage in Java?

Java does not provide a native method to store data. For storing and querying data we use external SQL/NoSQL DBMS.
The core problem is: all DBMS use totally different data structure than we use in Java.


Java

Java Object-Graph
In Java we use object-graphs
for almost everything


RDBMS

RDBMS
RDBMS store data in tables
connected by relations


NoSQL DBMS

NoSQL DBMS
NoSQL DBMS provide totally different data structure like key-value, document,

key-value-, document-, column-, graph- or object-store




Impedance Mismatch!
All database systems of today are incompatible to Java

This problem is well known for almost 40 years and leads to many fatal consequences:

  • 2 different data models needed
  • Need to adapt your Java classes effortly
  • Strongly limited, flat Java object model
  • High-complex mapping framework needed
  • OR-mapping leads to tremendous loss of performance
  • In most cases additional caching framework needed
  • High-complex architecture
  • Database query language & Java query API needed
  • Infamouse source of error
  • Need of experienced JPA/NoSQL specialists
  • High effort and costs for the entire database development process and maintenance

Why MicroStream?

MicroStream is the very first Native Data Store for Java

Java Object-Graph
Java
Java Object-Graph
⇔
Java Object-Graph
File-Storage
Java Object-Graph


MicroStream is a unique storage technology that stores Java object-graphs natively, which means similar as they are in the RAM, without expensive transformation to any incompatible data structure. That is the key difference to all database-systems and provides you fantastic benefits.

  • Feels like a native Java function for storing data
  • Only 1 data structure (object-graph), only 1 data model (Java classes)
  • No more impedance mismatch, no more mapping
  • No more loss of performance through mapping
  • Makes pure Java in-memory computing paradigm possible
  • Maxing out the ultra-fast in-memory computing power of the JVM
  • Simple architecture, super easy to use
  • Simplifies and accelerates your entire database development process

Getting Started


Markus Kett

CEO, MicroStream

In Java we use object-graphs for almost everything, of course for processing data also.
It's commonly known, that object-graphs are predestined for huge and complex data structure and
we can query them in-memory in only microseconds.
Why transforming this perfect structure to a totally alien structure to store data?
It's only because database-systems have always dictated the storage format and Java doesn't provide a native solution.

We believe from a Java-side perspective, the logical consequence and most efficient way is storing data exactly the same manner as the Java-VM does.
That's why MicroStream stores Java object-graphs natively, which means exactly 1:1 as the JVM holds it in the memory.
Thus, MicroStream feels like a native and simple to use Java data storage function, which eliminates lots of technical problems
in today's data processing, simplifies the entire database development process, reduces the costs and provides completely new possibilities.



Fantastic benefits


Ultra high-speed

  • No more loss of performance through mapping
  • Pure Java in-memory computing paradigm
  • Your object-graph is a in-memory database
  • Query executing time down to nanoseconds
  • JIT-compiler boost even for your database operations
  • No network bottleneck

Simplifies your entire
database development process

  • Feels like a native data store function for Java
  • 1 data structure - your Java object-graph
  • 1 data model - your Java classes
  • No more impedance mismatch, no more mapping
  • No more JPA, no more caching-framework
  • Simple architecture
  • 100% pure Java

Saving time,
resources & money

  • Super easy to use
  • Simple implementing
  • No JPA/NoSQL expert know-how needed
  • Faster results
  • Reduces your time to market and costs of
    development, testing and maintenance


Ultra high-speed

No more mapping

MicroStream stores your Java object-graph 1:1 as it is. No more loss of computing time through mapping objects to an incompatible database data-structure.


Pure Java in-memory computing

Your entire database is located in the memory within your business-logic-layer. No more database-server, no more storage-layer needed.


In-memory database

Your Java object-graph is your database, which is located in the RAM and fully managed by the Java-VM.


In-memory queries

Queries even on a huge object-graph located in the memory are commonly executed in microseconds. Up to 1,000 times faster than any conventional DBMS.


JIT-compiler boost

Frequently executed queries are fully automated optimized by the Java VM's JIT- compiler and can be accelerated up to nanoseconds.


No network bottleneck

Because your database is located in the RAM, there is no more bottleneck or latencies that brakes your database accesses.




Simplifies & accelerates
your entire development process

Only 1 data model

With MicroStream, your Java classes are your only one data model, nothing else. This simplifies the entire database development process significantly.


Use your classes as they are

MicroStream allows you to store any Java object without the need to adapt your Java classes. No superclasses, no interfaces, no annotations, no dependencies.


No more complex JPA

With MicroStream there is no more need to use complex ORM-frameworks like Hibernate and additional data-caching frameworks.


Design your data model freely

With MicroStream you can freely design Java your data model without the need to adapt your classes to an alien database data structure.


Easy to use

MicroStream is a tiny Java API. You can include it in any Java program via Maven. The engine feels like a native Java method for storing data.


No special requirements

The only requirement is Java 8. MicroStream has absolutely no dependencies on any third-party APIs.





What is a pure Java in-memory computing paradigm?

Simple architecture and paradigm. Ultra-fast. Pure Java approach. Get the maximum power out of the JVM


Java itself provides you almost everything you need to create incredible fast in-memory database applications.

The only thing missing so far was a native storage function to store data persistent on disk. With MicroStream, exactly this is now possible.

In-Memory Database: Your Java object-graph is your database
Database-Management-System: Your business logic is your DBMS
Processes: Java server only, no more DMBS-server needed
Architecture: 2-tier
Data model: Your Java classes only
Query language: Any suitable Java API, e.g. Java streams API
In-memory speed: Querying even huge object-graphs takes only microseconds
JIT compiler boost: Most frequent queries are accelerated up to nanoseconds
Data storage: MicroStream - Java-Native Persistence




Only 1 data structure - that's the key difference!

MicroStream is the only one data-storage that stores Java object-graphs natively

Relational Database Systems NoSQL Database Systems MicroStream
Native Java Data-Store
Java Object-Graph ⇔ Tables & Relations Java Object-Graph ⇔ Key-Value Java Object-Graph ⇔ Java Object-Graph
Processes:
Java + RDBMS server
Processes:
Java + NoSQL DBMS server
Processes:
Java only
Architecture:
3-tier
Architecture:
3-tier
Architecture:
2-tier
Data Structure:
Tables & Relations
Data Structure:
Key-Value / Document / Column / Graph
Data Structure:
Native Java object-graph
Compatible to Java object-graphs:
No - Impedance mismatch
Compatible to Java object-graphs:
No - Impedance mismatch
Compatible to Java object-graphs:
Yes
Needed data models:
Java classes + database data model
Needed data models:
Java classes + database data model
Needed data models:
Java classes only
Mapping needed:
Yes
Mapping needed:
Yes
Mapping needed:
No
Data model design:
Strongly adapted to DBMS
Data model design:
Strongly adapted to DBMS
Data model design:
Freely
Additional data-cache needed:
In many cases
Additional data-cache needed:
In many cases
Additional data-cache needed:
No
Query language:
SQL
Query language:
SQL / proprietary
Query language:
Java API
Complexity of development:
High
Complexity of development:
High
Complexity of development:
Low
Loss of performance through mapping:
Yes
Loss of performance through mapping:
Yes
Loss of performance through mapping:
No mapping



Only 1 data model: Your Java classes.
Use your classes as they are. No strings attached.

MicroStream allows you to store any plain Java object-graph.
You don't have to adapt your Java classes efforts.

    public class Customer {

       private String firstname;
       private String lastname;
       private String mail;
       private Integer age;
       private Boolean active;
       private Set<Order> orders;

       ...
    }
No need for …
  • Special superclasses
  • Special interfaces
  • Annotations
  • Mappings
  • Other internal configurations



Loading Data into the memory

Loading Data into the memory

    public class Customer {

        ...
        private Lazy<Set<Order>> orders;
        ...

        public Set<Order> getOrders() {
           return Lazy.get(this.orders);
        }

        public void setOrders(final Set<Order> orders) {
           this.orders = Lazy.Reference(orders);
        }

        ...
    }
  • You get a fully indexed in-memory database by default
  • You can pre-load any amount of data into the memory
  • When accessing an entity MicroStream loads the data into the
    memory fully automized behind the scenes (lazy-loading)
  • Multithreaded load-process for maximum speed
  • References that are no longer accessible are automatically
    deleted by the garbage collector of the Java-VM



Your object-graph is
the ultimate Java in-memory database

Java Object-Graph
  • Predestined for complex data structure
  • You can design your object-graph freely
  • All Java concepts can be used, e.g. collections
  • All Java APIs & frameworks can be used, e.g. Java streams API, Apache Lucene
  • Running through huge object-graphs takes only microseconds
  • Maximum query speed powered by the JVM's JIT-compiler
  • Concurrent writes can be managed by using Java standard concepts
  • If RAM is not enough, data can be loaded on-demand with MicroStream
  • Deleted references are removed by the JVM's garbage collector



Queries executed in microseconds.
Much faster than any conventional database-systems.

  • Your Java object-graph is your in-memory database
  • Write your queries with Java streams. Pure Java. Typesafe. Good testable
  • No more alien query language needed
  • Querying even a huge Java object-graphs takes only microseconds
  • Queries up to 1,000 times faster than any DBMS
  • Frequently used queries are optimized by the JVM's JIT-compiler and accelerated up to nanoseconds
  • Much faster than common data-caches, because no (OR-)mapping is needed
  • 100% pure Java-VM power
    public static void booksByAuthor()
    {
        final Map<Author, List<Book>> booksByAuthor =
            ReadMeCorp.data().books().stream()
                .collect(groupingBy(book -> book.author()));

        booksByAuthor.entrySet().forEach(e -> {
            System.out.println(e.getKey().name());
            e.getValue().forEach(book -> {
                System.out.print('\t');
                System.out.println(book.title());
            });
        });
    }



Storing Data persistently

Storing Data persistently

MicroStream enables you to store and load
any Java object-graph 1:1 as it is by calling only 1 simple method.


DataRoot root = microstreamDemo.root();
    root.getCustomers().add(customer);

    microstreamDemo.store(root.getCustomers());

  • Any file-system
  • Only changes are stored (single entities)
  • Append-only strategy
  • Transaction-safe
  • Super fast
  • Multithreaded store process for maximum speed
  • Splitting the storage into many files for even more speed is possible
  • Using different distributed file systems is possible

Getting Started




What's different to Java serialization and Blob-Stores?

MicroStream allows you to store and load single entities

Java serialization Blob-Stores MicroStream
Native Java Data-Store
Storing complete object-graphs
Storing single entities
Loading complete object-graphs
Loading single entities & updating the object-graph in the memory partially



Runs everywhere

MicroStream is a tiny Java API that you can include in any Java application and run in any JVM from Java 8

Desktop

On-Premise

Cloud

Container-ready

Great for
MicroServices


Getting Started



MicroStream

Next Generation Serialization for Java and Java-Native Persistence for developing ultra-fast Java in-memory database applications

Contact us