Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings
This repository was archived by the owner on Mar 2, 2022. It is now read-only.

A scala extension for Project Reactor's Flux and Mono

License

NotificationsYou must be signed in to change notification settings

spring-attic/reactor-scala-extensions

This project is being move to thespring-attic GitHub org, and may eventually reside in thevmware-archive org.

Special note from Simon Baslé @simonbasle, Reactor Project Lead:Should this project need to be revived, please reach out to the Reactor GitHub org @team + GitHub user @sinwe in a GitHub discussion or issue, or on Twitter to @projectreactor or @springops

Reactor Scala Extensions

Join the chat at https://gitter.im/reactor/reactor-scala-extensionsReactor Scala ExtensionsLatestDownload

Build Statuscodecov

Average time to resolve an issuePercentage of issues still open

This project is a Scala extension forreactor-core.

Using reactor-core project as it is in scala code will look ugly becausea lot of methods use Java 8 lambda which is not compatible with Scala lambda.This will force Scala code to use anonymous class which turns ugly.

So instead of

val mono = Mono.just(1)               .map(new java.util.function.Function[Int, String] {                   def apply(t: Int): String = t.toString               })

it becomes

val mono = SMono.just(1).map(_.toString)

This extension will also return scala'sscala.collection.immutable.Stream instead of Java'sjava.util.stream.Streamandscala.concurrent.Future instead ofjava.util.concurrent.CompletableFuture

Getting it

With SBT:

libraryDependencies += "io.projectreactor" %% "reactor-scala-extensions" % "0.7.0"

With Gradle:

repositories {    //maven { url 'https://oss.sonatype.org/content/repositories/snapshots/' }    mavenCentral()}dependencies {    //compile "io.projectreactor:reactor-scala-extensions_2.12:0.7.1-SNAPSHOT    //compile "io.projectreactor:reactor-scala-extensions_2.13:0.7.0 //for scala 2.13    compile "io.projectreactor:reactor-scala-extensions_2.12:0.7.0 //for scala 2.12    //compile "io.projectreactor:reactor-scala-extensions_2.11:0.7.0 //for scala 2.11}

With Maven:

<!-- To get latest SNAPSHOT version from Sonatype<repositories>    <repository>        <snapshots>            <enabled>true</enabled>        </snapshots>        <id>ossSonatypeSnapshot</id>        <name>OSS Sonatype Snapshots</name>        <url>https://oss.sonatype.org/content/repositories/snapshots/</url>        <layout>default</layout>    </repository> </repositories><dependency>    <groupId>io.projectreactor</groupId>    <artifactId>reactor-scala-extensions</artifactId>    <version>0.7.1-SNAPSHOT</version></dependency>--><dependency>    <groupId>io.projectreactor</groupId>    <artifactId>reactor-scala-extensions_2.12</artifactId> <!-- for scala 2.12 -->    <!--<artifactId>reactor-scala-extensions_2.11</artifactId> for scala 2.11 -->    <!--<artifactId>reactor-scala-extensions_2.13</artifactId> for scala 2.13 -->    <version>0.7.0</version></dependency>

Contributing

Contributions are welcome. Simply fork this project, make some modification, push andcreate a pull request.


[8]ページ先頭

©2009-2025 Movatter.jp