Skip to content

Commit 3fafc4e

Browse files
authored
4.x: Upgrade to Java 26 baseline compilation, test isolation (#8074)
1 parent 7b0fddf commit 3fafc4e

File tree

7 files changed

+27
-25
lines changed

7 files changed

+27
-25
lines changed

.github/workflows/gradle_branch.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -16,11 +16,11 @@ jobs:
1616
runs-on: ubuntu-latest
1717
steps:
1818
- uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2
19-
- name: Set up JDK 25
19+
- name: Set up JDK 26
2020
uses: actions/setup-java@be666c2fcd27ec809703dec50e508c2fdc7f6654 # v5.2.0
2121
with:
2222
distribution: 'zulu'
23-
java-version: '25'
23+
java-version: '26'
2424
- name: Cache Gradle packages
2525
uses: actions/cache@668228422ae6a00e4ad889ee87cd7109ec5666a7 # v5.0.4
2626
with:

.github/workflows/gradle_pr.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -18,11 +18,11 @@ jobs:
1818
runs-on: ubuntu-latest
1919
steps:
2020
- uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2
21-
- name: Set up JDK 25
21+
- name: Set up JDK 26
2222
uses: actions/setup-java@be666c2fcd27ec809703dec50e508c2fdc7f6654 # v5.2.0
2323
with:
2424
distribution: 'zulu'
25-
java-version: '25'
25+
java-version: '26'
2626
- name: Cache Gradle packages
2727
uses: actions/cache@668228422ae6a00e4ad889ee87cd7109ec5666a7 # v5.0.4
2828
with:

.github/workflows/gradle_release.yml

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -20,11 +20,11 @@ jobs:
2020
CI_BUILD_NUMBER: ${{ github.run_number }}
2121
steps:
2222
- uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2
23-
- name: Set up JDK 25
23+
- name: Set up JDK 26
2424
uses: actions/setup-java@be666c2fcd27ec809703dec50e508c2fdc7f6654 # v5.2.0
2525
with:
2626
distribution: 'zulu'
27-
java-version: '25'
27+
java-version: '26'
2828
- name: Cache Gradle packages
2929
uses: actions/cache@668228422ae6a00e4ad889ee87cd7109ec5666a7 # v5.0.4
3030
with:
@@ -50,11 +50,11 @@ jobs:
5050
contents: write
5151
steps:
5252
- uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2
53-
- name: Set up JDK 25
53+
- name: Set up JDK 26
5454
uses: actions/setup-java@be666c2fcd27ec809703dec50e508c2fdc7f6654 # v5.2.0
5555
with:
5656
distribution: 'zulu'
57-
java-version: '25'
57+
java-version: '26'
5858
- name: Cache Gradle packages
5959
uses: actions/cache@668228422ae6a00e4ad889ee87cd7109ec5666a7 # v5.0.4
6060
with:

.github/workflows/gradle_snapshot.yml

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -19,11 +19,11 @@ jobs:
1919
CI_BUILD_NUMBER: ${{ github.run_number }}
2020
steps:
2121
- uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2
22-
- name: Set up JDK 25
22+
- name: Set up JDK 26
2323
uses: actions/setup-java@be666c2fcd27ec809703dec50e508c2fdc7f6654 # v5.2.0
2424
with:
2525
distribution: 'zulu'
26-
java-version: '25'
26+
java-version: '26'
2727
- name: Cache Gradle packages
2828
uses: actions/cache@668228422ae6a00e4ad889ee87cd7109ec5666a7 # v5.0.4
2929
with:
@@ -60,11 +60,11 @@ jobs:
6060
CI_BUILD_NUMBER: ${{ github.run_number }}
6161
steps:
6262
- uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2
63-
- name: Set up JDK 25
63+
- name: Set up JDK 26
6464
uses: actions/setup-java@be666c2fcd27ec809703dec50e508c2fdc7f6654 # v5.2.0
6565
with:
6666
distribution: 'zulu'
67-
java-version: '25'
67+
java-version: '26'
6868
- name: Cache Gradle packages
6969
uses: actions/cache@668228422ae6a00e4ad889ee87cd7109ec5666a7 # v5.0.4
7070
with:

README.md

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -13,18 +13,18 @@ It extends the [observer pattern](http://en.wikipedia.org/wiki/Observer_pattern)
1313

1414
#### Version 4.x ([Javadoc](http://reactivex.io/RxJava/4.x/javadoc/))
1515

16-
- :+1: Native Java 25* implementation. Will go 26 or even 27 depending on how long it takes.
16+
- :+1: Native Java 26* implementation. Will go 27 depending on how long it takes and what useful things 27 brings.
1717
- :+1: No 3rd party library required at runtime.
1818
- :+1: JPMS and :question: OSGi support still intact.
1919
- :+1: `java.util.concurrent.Flow`-based implementation.
2020
- :+1: Virtual Thread support; `virtualCreate()`, `virtualTransform()`, :eye: `Schedulers.virtual()`.
21+
- :+1: New `Streamable<T>` built around Virtual Threads & virtual blocking. Think `IAsyncEnumerable` for Java. :satellite: in progress.
2122
- :information_source: Reactive Streams Test Compatibility Kit usage; [Reactive-Streams](https://github.com/reactive-streams/reactive-streams-jvm).
2223
- :satellite: Rewamp of the javadoc bloat in the base types via `sealed` interfaces.
2324
- :satellite: Reduce overload bloat by using `record`-based configurations.
2425
- :satellite: Internal optimizations now that I have the master :key:.
2526
- :eye: Possible usages for Scoped variables for context and per-item resource management.
2627
- :eye: Possible use for the Java Cleaner API.
27-
- :eye: Possible new monad `Streamable<T>` built around Virtual Threads & virtual blocking. Think `IAsyncEnumerable` for Java.
2828
- :eye: Possible inclusion of 2nd and 3rd party operators.
2929
- :eye: Possible inclusion of the Iterable Extensions (Ix) 2nd party library. ju.Stream is sh|t wrt interfacing and composability.
3030
- :question: Android compatibility depends on your API level and what desugaring is available.
@@ -509,11 +509,11 @@ For further details, consult the [wiki](https://github.com/ReactiveX/RxJava/wiki
509509

510510
## Versioning
511511

512-
Version 3.x is in development. Bugfixes will be applied to both 2.x and 3.x branches, but new features will only be added to 3.x.
512+
Version 4.x is in development. Bugfixes will be applied to both 3.x and 4.x branches if possible, but new features will only be added to 4.x.
513513

514-
Minor 3.x increments (such as 3.1, 3.2, etc) will occur when non-trivial new functionality is added or significant enhancements or bug fixes occur that may have behavioral changes that may affect some edge cases (such as dependence on behavior resulting from a bug). An example of an enhancement that would classify as this is adding reactive pull backpressure support to an operator that previously did not support it. This should be backwards compatible but does behave differently.
514+
Minor 4.x increments (such as 4.1, 4.2, etc) will occur when non-trivial new functionality is added or significant enhancements or bug fixes occur that may have behavioral changes that may affect some edge cases (such as dependence on behavior resulting from a bug). An example of an enhancement that would classify as this is adding reactive pull backpressure support to an operator that previously did not support it. This should be backwards compatible but does behave differently.
515515

516-
Patch 3.x.y increments (such as 3.0.0 -> 3.0.1, 3.3.1 -> 3.3.2, etc) will occur for bug fixes and trivial functionality (like adding a method overload). New functionality marked with an [`@Beta`][beta source link] or [`@Experimental`][experimental source link] annotation can also be added in the patch releases to allow rapid exploration and iteration of unstable new functionality.
516+
Patch 4.x.y increments (such as 4.0.0 -> 4.0.1, 4.3.1 -> 4.3.2, etc) will occur for bug fixes and trivial functionality (like adding a method overload). New functionality marked with an [`@Beta`][beta source link] or [`@Experimental`][experimental source link] annotation can also be added in the patch releases to allow rapid exploration and iteration of unstable new functionality.
517517

518518
#### @Beta
519519

build.gradle

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -56,11 +56,11 @@ dependencies {
5656

5757
java {
5858
toolchain {
59-
vendor = JvmVendorSpec.ADOPTIUM
60-
languageVersion = JavaLanguageVersion.of(25) // Temurin 26 is not out yet
59+
// vendor = JvmVendorSpec.ADOPTIUM <-- for now
60+
languageVersion = JavaLanguageVersion.of(26)
6161
}
62-
sourceCompatibility = JavaVersion.VERSION_25
63-
targetCompatibility = JavaVersion.VERSION_25
62+
sourceCompatibility = JavaVersion.VERSION_26
63+
targetCompatibility = JavaVersion.VERSION_26
6464
}
6565

6666
tasks.withType(JavaCompile) {
@@ -98,7 +98,7 @@ javadoc {
9898
failOnError = false
9999

100100
options.links(
101-
"https://docs.oracle.com/en/java/javase/25/docs/api/",
101+
"https://docs.oracle.com/en/java/javase/26/docs/api/",
102102
"https://reactivex.io/RxJava/org.reactivestreams.javadoc/${reactiveStreamsVersion}/"
103103
)
104104

src/test/java/io/reactivex/rxjava4/completable/CompletableTest.java

Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -19,14 +19,15 @@
1919

2020
import java.util.*;
2121
import java.util.concurrent.*;
22+
import java.util.concurrent.Flow.*;
2223
import java.util.concurrent.atomic.*;
2324

2425
import org.junit.*;
25-
import static java.util.concurrent.Flow.*;
26+
import org.junit.jupiter.api.parallel.Isolated;
2627

2728
import io.reactivex.rxjava4.core.*;
2829
import io.reactivex.rxjava4.core.Observable;
29-
import io.reactivex.rxjava4.disposables.*;
30+
import io.reactivex.rxjava4.disposables.Disposable;
3031
import io.reactivex.rxjava4.exceptions.*;
3132
import io.reactivex.rxjava4.functions.*;
3233
import io.reactivex.rxjava4.internal.disposables.*;
@@ -44,6 +45,7 @@
4445
/**
4546
* Test Completable methods and operators.
4647
*/
48+
@Isolated
4749
public class CompletableTest extends RxJavaTest {
4850
/**
4951
* Iterable that returns an Iterator that throws in its hasNext method.
@@ -1981,7 +1983,7 @@ public Completable apply(Throwable v) {
19811983
c.blockingAwait();
19821984
}
19831985

1984-
@Test
1986+
@org.junit.jupiter.api.Test
19851987
public void repeatNormal() {
19861988
final AtomicReference<Throwable> err = new AtomicReference<>();
19871989
final AtomicInteger calls = new AtomicInteger();

0 commit comments

Comments
 (0)