Coder Social home page Coder Social logo

soundvibe / reacto Goto Github PK

View Code? Open in Web Editor NEW
6.0 1.0 3.0 602 KB

Functional reactive microservices for the JVM. Uses Observables for composing event streams.

License: Apache License 2.0

Java 100.00%
java reactive rxjava functional microservices observable-streams stream-processing reactive-streams flow

reacto's People

Contributors

gitter-badger avatar soundvibe avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar

reacto's Issues

Allow other implementations apart from vert.x

Extract vert.x implementation into separate module.
Refactor main reacto source code to support other possible implementations for service discovery, event handlers, command executors.

Typed commands and events

Investigate possibility to implement typed commands and events.
Executing command could look like this:

ServiceRegistry services = new TypedReactoServiceRegistry(ServiceDiscovery.create(vertx), mapper);
MakeDemo command = new MakeDemo("Hello, World!");
services.execute(command, DemoMade.class)
    .subscribe((DemoMade demoMade) -> System.out.println(demoMade.name));

TypedReactoServiceRegistry should register type info of commands and their typed events to service discovery registry so executing incompatible commands should not be possible.

Registering commands could look like this:

CommandRegistry.ofTyped(
    MakeDemo.class, 
    DemoMade.class, 
    makeDemo -> Observable.just(new DemoMade(makeDemo.name)))
    .withMapper(mapper);

Support new communication method (Webhooks)

Consider implementing new communication method in addition to websockets. One of the simplest solutions could be using something similar to Webhooks.

Flow could be something like this:

  1. Command invoked
  2. Initial POST request (which contains given command and webhooksUrl where events should be pushed) is sent to the command handler
  3. Command handler receives command and executes it
  4. Each onNext, OnError or OnCompleted events send POST requests with given event data to registered webhooksUrl.

Some thoughts:

  • Do we send the data in json format (preferred way when using Restful services) or just use protocol buffers?

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.