Need help with scalecube-services?
Click the “chat” button below for chat support from the developer who created it, or find similar developers for support.

About the developer

[email protected]
476 Stars 72 Forks Apache License 2.0 4.6K Commits 27 Opened issues


ScaleCube Services is a high throughput, low latency reactive microservices library built to scale. it features: API-Gateways, service-discovery, service-load-balancing, the architecture supports plug-and-play service communication modules and features. built to provide performance and low-latency real-time stream-processing. its open and designed to accommodate changes. (no sidecar in a form of broker or any kind)

Services available


Need anything else?

Contributors list

No Data


Codacy Badge Maven Central SourceSpy Dashboard


An open-source project that is focused on streamlining reactive-programming of Microservices Reactive-systems that scale, built by developers for developers.

ScaleCube Services provides a low latency Reactive Microservices library for peer-to-peer service registry and discovery based on gossip protocol, without single point-of-failure or bottlenecks.

Scalecube more gracefully address the cross cutting concernes of distributed microservices architecture.

ScaleCube Services Features:

  • Provision and interconnect microservices peers in a cluster
  • Fully Distributed with No single-point-of-failure or single-point-of-bottleneck
  • Fast - Low latency and high throughput
  • Scaleable over- cores, jvms, clusters, regions.
  • Built-in Service Discovery and service routing
  • Zero configuration, automatic peer-to-peer service discovery using gossip
  • Simple non-blocking, asynchronous programming model
  • Reactive Streams support.
    • Fire And Forget - Send and not wait for a reply
    • Request Response - Send single request and expect single reply
    • Request Stream - Send single request and expect stream of responses.
    • Request bidirectional - send stream of requests and expect stream of responses.
  • Built-in failure detection, fault tolerance, and elasticity
  • Routing and balancing strategies for both stateless and stateful services
  • Embeddable into existing applications
  • Natural Circuit-Breaker via scalecube-cluster discovery and failure detector.
  • Support Service instance tagging.
  • Modular, flexible deployment models and topology
  • pluggable api-gateway providers (http / websocket / rsocket)
  • pluggable service transports (tcp / aeron / rsocket)
  • pluggable encoders (json, SBE, Google protocol buffers)

User Guide:

Basic Usage:

The example provisions 2 cluster nodes and making a remote interaction. 1. seed is a member node and provision no services of its own. 2. then microservices variable is a member that joins seed member and provision GreetingService instance. 3. finally from seed node - create a proxy by the GreetingService api and send a greeting request.

    //1. ScaleCube Node node with no members
    Microservices seed = Microservices.builder().startAwait();

//2. Construct a ScaleCube node which joins the cluster hosting the Greeting Service
Microservices microservices =
            self ->
                new ScalecubeServiceDiscovery(self)
                    .options(opts -> opts.seedMembers(toAddress(seed.discovery().address()))))
        .services(new GreetingServiceImpl())

//3. Create service proxy
GreetingsService service =;

// Execute the services and subscribe to service events
service.sayHello("joe").subscribe(consumer -> {

Basic Service Example:

  • RequestOne: Send single request and expect single reply
  • RequestStream: Send single request and expect stream of responses.
  • RequestBidirectional: send stream of requests and expect stream of responses.

A service is nothing but an interface declaring what methods we wish to provision at our cluster.

public interface ExampleService {

@ServiceMethod Mono sayHello(String request);

@ServiceMethod Flux helloStream();

@ServiceMethod Flux helloBidirectional(Flux requests); }


Available api-gateways are rsocket, http and websocket

Basic API-Gateway example:

        .discovery(options -> options.seeds(seed.discovery().address()))
        .services(...) // OPTIONAL: services (if any) as part of this node.

    // configure list of gateways plugins exposing the apis
    .gateway(options -> new WebsocketGateway("ws").port(8080)))
    .gateway(options -> new HttpGateway("http").port(7070)))
    .gateway(options -> new RSocketGateway("rsws").port(9090)))


    // HINT: you can try connect using the api sandbox to these ports to try the api.


With scalecube-services you may plug-and-play alternative providers for Transport,Codecs and discovery. Scalecube is using ServiceLoader to load providers from class path,

You can think about scalecube as slf4j for microservices - Currently supported SPIs:

Transport providers:

  • scalecube-services-transport-rsocket: using rsocket to communicate with remote services.

Message codec providers:

  • scalecube-services-transport-jackson: using Jackson to encode / decode service messages.
  • scalecube-services-transport-protostuff: using protostuff to encode / decode service messages.

Service discovery providers:

  • scalecube-services-discovery: using scalecue-cluster do locate service Endpoint within the cluster

Binaries and dependency information for Maven can be found at

To add a dependency on ScaleCube Services using Maven, use the following:

Maven Central







Sponsored by OM2

We use cookies. If you continue to browse the site, you agree to the use of cookies. For more information on our use of cookies please see our Privacy Policy.