Skip to content

Commit 75cfc4f

Browse files
committed
Version 0.26.0
1 parent 82a5dfd commit 75cfc4f

File tree

10 files changed

+37
-17
lines changed

10 files changed

+37
-17
lines changed

CHANGES.md

+21
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,26 @@
11
# Change log for kotlinx.coroutines
22

3+
## Version 0.26.0
4+
* Major rework of `kotlinx.coroutines` concurrency model (see #410 for a full explanation of the rationale behind this change):
5+
* All coroutine builders are now extensions on `CoroutineScope` and inherit its `coroutineContext`. Standalone builders are deprecated.
6+
* As a consequence, all nested coroutines launched via builders now automatically establish parent-child relationship and inherit `CoroutineDispatcher`.
7+
* All coroutine builders use `Dispatchers.Default` by default if `CoroutineInterceptor` is not present in their context.
8+
* [CoroutineScope](https://kotlin.github.io/kotlinx.coroutines/kotlinx-coroutines-core/kotlinx.coroutines.experimental/-coroutine-scope/) became the first-class citizen in `kolinx.coroutines`.
9+
* `withContext` `block` argument has `CoroutineScope` as a receiver.
10+
* [GlobalScope](https://kotlin.github.io/kotlinx.coroutines/kotlinx-coroutines-core/kotlinx.coroutines.experimental/-global-scope/) is introduced to simplify migration to new API and to launch global-level coroutines.
11+
* `currentScope` and `coroutineScope` builders are introduced to extract and provide `CoroutineScope`.
12+
* Factory methods to create `CoroutineScope` from `CoroutineContext` are introduced.
13+
* `CoroutineScope.isActive` became an extension property.
14+
* New sections about structured concurrency in core guide: ["Structured concurrency"](coroutines-guide.md#structured-concurrency), ["Scope builder"](coroutines-guide.md#scope-builder) and ["Structured concurrency with async"](coroutines-guide.md#structured-concurrency-with-async).
15+
* New section in UI guide with Android example: ["Structured concurrency, lifecycle and coroutine parent-child hierarchy"](ui/coroutines-guide-ui.md#structured-concurrency,-lifecycle-and-coroutine-parent-child-hierarchy).
16+
* Deprecated reactive API is removed.
17+
* Dispatchers are renamed and grouped in the Dispatchers object (see #41 and #533):
18+
* Dispatcher names are consistent.
19+
* Old dispatchers including `CommonPool` are deprecated.
20+
* Fixed bug with JS error in rare cases in `invokeOnCompletion(onCancelling = true)`.
21+
* Fixed loading of Android exception handler when `Thread.contextClassLoader` is mocked (see #530).
22+
* Fixed bug when `IO` dispatcher silently hung (see #524 and #525) .
23+
324
## Version 0.25.3
425

526
* Distribution no longer uses multi-version jar which is not supported on Android (see #510).

README.md

+5-6
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22

33
[![official JetBrains project](http://jb.gg/badges/official.svg)](https://confluence.jetbrains.com/display/ALL/JetBrains+on+GitHub)
44
[![GitHub license](https://img.shields.io/badge/license-Apache%20License%202.0-blue.svg?style=flat)](http://www.apache.org/licenses/LICENSE-2.0)
5-
[![Download](https://api.bintray.com/packages/kotlin/kotlinx/kotlinx.coroutines/images/download.svg?version=0.25.3) ](https://bintray.com/kotlin/kotlinx/kotlinx.coroutines/0.25.3)
5+
[![Download](https://api.bintray.com/packages/kotlin/kotlinx/kotlinx.coroutines/images/download.svg?version=0.26.0) ](https://bintray.com/kotlin/kotlinx/kotlinx.coroutines/0.26.0)
66

77
Library support for Kotlin coroutines with [multiplatform](#multiplatform) support.
88
This is a companion version for Kotlin 1.2.61 release.
@@ -63,7 +63,7 @@ Add dependencies (you can also add other modules that you need):
6363
<dependency>
6464
<groupId>org.jetbrains.kotlinx</groupId>
6565
<artifactId>kotlinx-coroutines-core</artifactId>
66-
<version>0.25.3</version>
66+
<version>0.26.0</version>
6767
</dependency>
6868
```
6969

@@ -80,7 +80,7 @@ And make sure that you use the latest Kotlin version:
8080
Add dependencies (you can also add other modules that you need):
8181

8282
```groovy
83-
implementation 'org.jetbrains.kotlinx:kotlinx-coroutines-core:0.25.3'
83+
implementation 'org.jetbrains.kotlinx:kotlinx-coroutines-core:0.26.0'
8484
```
8585

8686
And make sure that you use the latest Kotlin version:
@@ -113,10 +113,9 @@ Add [`kotlinx-coroutines-android`](ui/kotlinx-coroutines-android)
113113
module as dependency when using `kotlinx.coroutines` on Android:
114114

115115
```groovy
116-
implementation 'org.jetbrains.kotlinx:kotlinx-coroutines-android:0.25.3'
116+
implementation 'org.jetbrains.kotlinx:kotlinx-coroutines-android:0.26.0'
117117
```
118-
119-
This gives you access to Android [UI](https://kotlin.github.io/kotlinx.coroutines/kotlinx-coroutines-android/kotlinx.coroutines.experimental.android/-u-i.html)
118+
This gives you access to Android [Dispatchers.Main](https://kotlin.github.io/kotlinx.coroutines/kotlinx-coroutines-android/kotlinx.coroutines.experimental.android/kotlinx.coroutines.experimental.-dispatchers/index.html)
120119
coroutine dispatcher and also makes sure that in case of crashed coroutine with unhandled exception this
121120
exception is logged before crashing Android application, similarly to the way uncaught exceptions in
122121
threads are handled by Android runtime.

gradle.properties

+2-2
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
# Kotlin
2-
version = 0.25.3-SNAPSHOT
3-
group = org.jetbrains.kotlinx
2+
version=0.26.0-SNAPSHOT
3+
group=org.jetbrains.kotlinx
44
kotlin_version=1.2.61
55
kotlin_native_version=0.8.2
66

native/README.md

+1-1
Original file line numberDiff line numberDiff line change
@@ -42,7 +42,7 @@ repositories {
4242
}
4343
4444
dependencies {
45-
implementation 'org.jetbrains.kotlinx:kotlinx-coroutines-core-native:0.25.3'
45+
implementation 'org.jetbrains.kotlinx:kotlinx-coroutines-core-native:0.26.0'
4646
}
4747
4848
sourceSets {

ui/coroutines-guide-ui.md

+1-1
Original file line numberDiff line numberDiff line change
@@ -161,7 +161,7 @@ Add dependencies on `kotlinx-coroutines-android` module to the `dependencies { .
161161
`app/build.gradle` file:
162162

163163
```groovy
164-
compile "org.jetbrains.kotlinx:kotlinx-coroutines-android:0.25.3"
164+
compile "org.jetbrains.kotlinx:kotlinx-coroutines-android:0.26.0"
165165
```
166166

167167
Coroutines are experimental feature in Kotlin.

ui/kotlinx-coroutines-android/README.md

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
# Module kotlinx-coroutines-android
22

3-
Provides `UI` context for Android applications.
3+
Provides `Dispatchers.Main` context for Android applications.
44

55
Read [Guide to UI programming with coroutines](https://github.com/Kotlin/kotlinx.coroutines/blob/master/ui/coroutines-guide-ui.md)
66
for tutorial on this module.

ui/kotlinx-coroutines-android/animation-app/gradle.properties

+2-2
Original file line numberDiff line numberDiff line change
@@ -18,6 +18,6 @@ org.gradle.jvmargs=-Xmx1536m
1818

1919
kotlin.coroutines=enable
2020

21-
kotlin_version = 1.2.61
22-
coroutines_version = 0.25.3
21+
kotlin_version=1.2.61
22+
coroutines_version=0.26.0
2323

ui/kotlinx-coroutines-android/example-app/gradle.properties

+2-2
Original file line numberDiff line numberDiff line change
@@ -18,6 +18,6 @@ org.gradle.jvmargs=-Xmx1536m
1818

1919
kotlin.coroutines=enable
2020

21-
kotlin_version = 1.2.61
22-
coroutines_version = 0.25.3
21+
kotlin_version=1.2.61
22+
coroutines_version=0.26.0
2323

ui/kotlinx-coroutines-javafx/README.md

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
# Module kotlinx-coroutines-javafx
22

3-
Provides `JavaFx` context for JavaFX UI applications.
3+
Provides `Dispatchers.JavaFx` context for JavaFX UI applications.
44

55
Read [Guide to UI programming with coroutines](https://github.com/Kotlin/kotlinx.coroutines/blob/master/ui/coroutines-guide-ui.md)
66
for tutorial on this module.

ui/kotlinx-coroutines-swing/README.md

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
# Module kotlinx-coroutines-swing
22

3-
Provides `Swing` context for Swing UI applications.
3+
Provides `Dispatchers.Swing` context for Swing UI applications.
44

55
Read [Guide to UI programming with coroutines](https://github.com/Kotlin/kotlinx.coroutines/blob/master/ui/coroutines-guide-ui.md)
66
for tutorial on this module.

0 commit comments

Comments
 (0)