Skip to content

memoria-io/reactive

master
Switch branches/tags
Code

Latest commit

 

Git stats

Files

Permalink
Failed to load latest commit information.
Type
Name
Latest commit message
Commit time
 
 
 
 
sec
 
 
 
 
web
 
 
 
 
 
 
 
 
 
 

Release GitHub tag (latest by date) GitHub commits since latest release (by date) Quality Gate Status

reactive

هذا العلم والعمل وقف للّه تعالي اسأل اللّه ان يرزقنا الاخلاص فالقول والعمل

This work and knowledge is for the sake of Allah, may Allah grant us sincerity in what we say or do.

reactive is a tool-box that makes it easier and faster to build reactive applications. It relies heavily on Reactive Streams and uses Project-Reactor, Reactor Netty, it also uses functional paradigms and collections from Vavr.

JDK notes

  • reactive is up-to-date with the latest versions of JDK preview feature, currently Java 18.

Core Features

  • Vavr + Reactor Functional utilities
  • Reactor Netty utility functions
  • Reactive CQRS and Eventsourcing utilities (beta stage)
  • Reactive functional in-memory generic cruds (for tests, not for production)
  • Jackson Adapter (Json & Yaml) utilities
  • FileOps reader utility
  • ResourceFileOps utility
  • ConfigFileOps is a module for reading yaml configuration files (depends on Jackson Adapter)
    • Allows nesting of files using a marker e.g include: sub_file.yaml would replace this line with content of sub_file.yaml
    • Reading as a system property if not found as environment variable or else the default value if it was supplied:
      • path: ${JAVA_HOME}
      • myVar: ${SOME_VAR:-defaultValue}

TODOs

  • Event Sourcing
    • State decider, evolver, Stream pipeline
    • Sagas decider, Stream pipeline
    • id safety with typed classed (StateId, CommandId, EventId)
    • Events reduction
      • If using reduction the event reducer should map all states to creation event
      • Init states can't have creation events.
    • Stream sharding to be used later for scaling
      • Tests
      • Due to sharding (reading from multiple src event streams) the whole cluster should be down first before executing sharding, so that oldStreams are not receiving new events, while being ingested, they should be in read only state
  • Streaming
    • Stream api for usage in event sourcing
    • Stream api for messaging patterns
  • Increase test coverage to >85%

Release notes

  • Current versioning YEAR.JDK.BREAKING_CHANGES.NON_BREAKING

Usage

All modules depend on Core. There are currently no other inter-dependencies between them.

Disclaimer:

reactive is on edge, it's a work in progress and a pragmatic learning effort, so feel free to create issues or PRs.

<project>
    <properties>
        <reactive.version>...</reactive.version>
    </properties>

    <dependencies>
        <dependency>
            <groupId>io.memoria.reactive</groupId>
            <artifactId>core</artifactId>
            <version>${reactive.version}</version>
        </dependency>

        <dependency>
            <!-- replace module_name with your preferred module -->
            <groupId>io.memoria.reactive</groupId>
            <artifactId>module_name</artifactId>
            <version>${reactive.version}</version>
        </dependency>
    </dependencies>
</project>

Contribution

You can just do pull requests, and I will check them asap.

Related Articles