rxjava2

null

License

License

Categories

Categories

Failsafe Application Layer Libs Distributed Applications RxJava Container Microservices Reactive libraries
GroupId

GroupId

com.github.venth.failsafe
ArtifactId

ArtifactId

rxjava2
Last Version

Last Version

0.1.4
Release Date

Release Date

Type

Type

jar
Description

Description

rxjava2
null
Project URL

Project URL

https://github.com/venth/failsafe-rxjava2
Source Code Management

Source Code Management

https://github.com/venth/failsafe-rxjava2

Download rxjava2

How to add to project

<!-- https://jarcasting.com/artifacts/com.github.venth.failsafe/rxjava2/ -->
<dependency>
    <groupId>com.github.venth.failsafe</groupId>
    <artifactId>rxjava2</artifactId>
    <version>0.1.4</version>
</dependency>
// https://jarcasting.com/artifacts/com.github.venth.failsafe/rxjava2/
implementation 'com.github.venth.failsafe:rxjava2:0.1.4'
// https://jarcasting.com/artifacts/com.github.venth.failsafe/rxjava2/
implementation ("com.github.venth.failsafe:rxjava2:0.1.4")
'com.github.venth.failsafe:rxjava2:jar:0.1.4'
<dependency org="com.github.venth.failsafe" name="rxjava2" rev="0.1.4">
  <artifact name="rxjava2" type="jar" />
</dependency>
@Grapes(
@Grab(group='com.github.venth.failsafe', module='rxjava2', version='0.1.4')
)
libraryDependencies += "com.github.venth.failsafe" % "rxjava2" % "0.1.4"
[com.github.venth.failsafe/rxjava2 "0.1.4"]

Dependencies

compile (2)

Group / Artifact Type Version
net.jodah : failsafe jar [1.0.4, 1.1.0)
io.reactivex.rxjava2 : rxjava jar [2.1.4, 2.2.0)

test (6)

Group / Artifact Type Version
org.springframework : spring-test jar [5.0.2.RELEASE,5.1.0.RELEASE)
org.codehaus.groovy : groovy-all jar [2.4.13, 2.5)
org.spockframework : spock-core jar [1.1-groovy-2.4, 2.0-groovy-2.4)
org.spockframework : spock-spring jar [1.1-groovy-2.4, 2.0-groovy-2.4)
cglib : cglib-nodep jar [3.2.5, 3.3.0)
org.objenesis : objenesis jar [2.6, 3.0)

Project Modules

There are no modules declared in this project.

Circuit Breaker Operator for RxJava2 (ReactiveX)

Build Status Maven Central Since introduction of Spring Reactive appeared a need of a circuit breaker that would follow the reactive principles and is very light.

FailSafe provides very light circuit breaker which works perfectly with Callable and Runnable and is complicated when comes to an application on an observable sequence.

This project brings new rxjava2 circuit breaker operator based on FailSafe which aims to be easy to use.

Usage

gradle

compile 'com.github.venth.failsafe:rxjava2:x.y.z'

maven

<dependency>
    <groupId>com.github.venth.failsafe</groupId>
    <artifactId>rxjava2</artifactId>
    <version>x.y.z</version>
</dependency>

Usage for each of the ReactiveX observables type is pretty similar. The examples presented below shall explain the usage.

  • xxxSequence - a sequence that depends on the operator's type.
  • circuitBreaker is configured instance of FailSafe CircuitBreaker.

Maybe

maybeSequence.lift(CircuitBreakerOperator.of(circuitBreaker))
    .subscribe()

Single

singleSequence.lift(CircuitBreakerOperator.of(circuitBreaker))
    .subscribe()

Observable

observableSequence.lift(CircuitBreakerOperator.of(circuitBreaker))
    .subscribe()

Flowable

flowableSequence.lift(CircuitBreakerOperator.of(circuitBreaker))
    .subscribe()

Completable

completableSequence.lift(CircuitBreakerOperator.of(circuitBreaker))
    .subscribe()

Versions

Version
0.1.4