Skip to content

Commit 018c9ce

Browse files
committed
Merge branch 'develop' into byte-channel-re
2 parents 5606133 + db0e22d commit 018c9ce

File tree

183 files changed

+652
-380
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

183 files changed

+652
-380
lines changed

CHANGES.md

Lines changed: 19 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,24 @@
11
# Change log for kotlinx.coroutines
22

3+
## Version 0.18
4+
5+
* Kotlin 1.1.4 is required to use this version, which enables:
6+
* `withLock` and `consumeEach` functions are now inline suspend functions.
7+
* `JobSupport` class implementation is optimized (one fewer field).
8+
* `TimeoutException` is public (see #89).
9+
* Improvements to `Mutex` (courtesy of @fvasco):
10+
* Introduced `holdsLock` (see #92).
11+
* Improved documentation on `Mutex` fairness (see #90).
12+
* Fixed NPE when `ArrayBroadcastChannel` is closed concurrently with receive (see #97).
13+
* Fixed bug in internal class LockFreeLinkedList that resulted in ISE under stress in extremely rare circumstances.
14+
* Integrations:
15+
* [quasar](integration/kotlinx-coroutines-quasar): Introduced integration with suspendable JVM functions
16+
that are instrumented with [Parallel Universe Quasar](http://docs.paralleluniverse.co/quasar/)
17+
(thanks to the help of @pron).
18+
* [reactor](reactive/kotlinx-coroutines-reactor): Replaced deprecated `setCancellation` with `onDipose` and
19+
updated to Aluminium-SR3 release (courtesy of @yxf07, see #96)
20+
* [jdk8](integration/kotlinx-coroutines-jdk8): Added adapters for `java.time` classes (courtesy of @fvasco, see #93)
21+
322
## Version 0.17
423

524
* `CompletableDeferred` is introduced as a set-once event-like communication primitive (see #70).

README.md

Lines changed: 14 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,11 @@
11
# kotlinx.coroutines [ ![Download](https://api.bintray.com/packages/kotlin/kotlinx/kotlinx.coroutines/images/download.svg) ](https://bintray.com/kotlin/kotlinx/kotlinx.coroutines/_latestVersion)
22

3-
Library support for Kotlin coroutines. This is a companion version for Kotlin 1.1 release.
3+
Library support for Kotlin coroutines.
4+
This is a companion version for Kotlin 1.1.4 release (this is the minimal required Kotlin runtime version).
45

56
## Modules
67

7-
* [kotlinx-coroutines-core](kotlinx-coroutines-core/README.md) -- core primitives to work with coroutines:
8+
* [core](core/README.md) -- core primitives to work with coroutines:
89
* `launch`, `async`, `produce`, `actor`, etc coroutine builders;
910
* `Job` and `Deferred` light-weight future with cancellation support;
1011
* `CommonPool` and other coroutine contexts;
@@ -20,9 +21,12 @@ Library support for Kotlin coroutines. This is a companion version for Kotlin 1.
2021

2122
## Documentation
2223

23-
* [Guide to kotlinx.coroutines by example](coroutines-guide.md) (**read it first**)
24-
* [Guide to UI programming with coroutines](ui/coroutines-guide-ui.md)
25-
* [Guide to reactive streams with coroutines](reactive/coroutines-guide-reactive.md)
24+
* [Introduction to Kotlin Coroutines](https://vimeo.com/222499934) video
25+
(Roman Elizarov at GeekOut 2017, [slides](https://www.slideshare.net/elizarov/introduction-to-kotlin-coroutines))
26+
* Guides and manuals:
27+
* [Guide to kotlinx.coroutines by example](coroutines-guide.md) (**read it first**)
28+
* [Guide to UI programming with coroutines](ui/coroutines-guide-ui.md)
29+
* [Guide to reactive streams with coroutines](reactive/coroutines-guide-reactive.md)
2630
* [Change log for kotlinx.coroutines](CHANGES.md)
2731
* [Coroutines design document (KEEP)](https://github.com/Kotlin/kotlin-coroutines/blob/master/kotlin-coroutines-informal.md)
2832
* [Full kotlinx.coroutines API reference](http://kotlin.github.io/kotlinx.coroutines)
@@ -34,7 +38,7 @@ Library support for Kotlin coroutines. This is a companion version for Kotlin 1.
3438
The libraries are published to [kotlinx](https://bintray.com/kotlin/kotlinx/kotlinx.coroutines) bintray repository
3539
and also linked to [JCenter](https://bintray.com/bintray/jcenter?filterByPkgName=kotlinx.coroutines).
3640

37-
These libraries require kotlin compiler version `1.1.x` and
41+
These libraries require kotlin compiler version `1.1.4` or later and
3842
require kotlin runtime of the same version as a dependency.
3943

4044
### Maven
@@ -54,15 +58,15 @@ Add dependencies (you can also add other modules that you need):
5458
<dependency>
5559
<groupId>org.jetbrains.kotlinx</groupId>
5660
<artifactId>kotlinx-coroutines-core</artifactId>
57-
<version>0.17</version>
61+
<version>0.18</version>
5862
</dependency>
5963
```
6064

6165
And make sure that you use the right Kotlin version:
6266

6367
```xml
6468
<properties>
65-
<kotlin.version>1.1.3-2</kotlin.version>
69+
<kotlin.version>1.1.4</kotlin.version>
6670
</properties>
6771
```
6872

@@ -79,13 +83,13 @@ repositories {
7983
Add dependencies (you can also add other modules that you need):
8084

8185
```groovy
82-
compile 'org.jetbrains.kotlinx:kotlinx-coroutines-core:0.17'
86+
compile 'org.jetbrains.kotlinx:kotlinx-coroutines-core:0.18'
8387
```
8488

8589
And make sure that you use the right Kotlin version:
8690

8791
```groovy
8892
buildscript {
89-
ext.kotlin_version = '1.1.3-2'
93+
ext.kotlin_version = '1.1.4'
9094
}
9195
```

benchmarks/pom.xml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,7 @@
2424
<parent>
2525
<groupId>org.jetbrains.kotlinx</groupId>
2626
<artifactId>kotlinx-coroutines</artifactId>
27-
<version>0.17-SNAPSHOT</version>
27+
<version>0.18-SNAPSHOT</version>
2828
</parent>
2929

3030
<artifactId>benchmarks</artifactId>

core/README.md

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,8 @@
1+
# Coroutines core
2+
3+
This directory contains modules that provide core coroutine support.
4+
5+
## Modules
6+
7+
* [kotlinx-coroutines-core](kotlinx-coroutines-core/README.md) -- core coroutine builders and synchronization primitives.
8+

kotlinx-coroutines-core/README.md renamed to core/kotlinx-coroutines-core/README.md

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -85,7 +85,7 @@ Select expression to perform multiple suspending operations simultaneously until
8585
<!--- MODULE kotlinx-coroutines-core -->
8686
<!--- INDEX kotlinx.coroutines.experimental -->
8787
[launch]: https://kotlin.github.io/kotlinx.coroutines/kotlinx-coroutines-core/kotlinx.coroutines.experimental/launch.html
88-
[Job]: https://kotlin.github.io/kotlinx.coroutines/kotlinx-coroutines-core/kotlinx.coroutines.experimental/-job.html
88+
[Job]: https://kotlin.github.io/kotlinx.coroutines/kotlinx-coroutines-core/kotlinx.coroutines.experimental/-job/index.html
8989
[CoroutineScope]: https://kotlin.github.io/kotlinx.coroutines/kotlinx-coroutines-core/kotlinx.coroutines.experimental/-coroutine-scope/index.html
9090
[async]: https://kotlin.github.io/kotlinx.coroutines/kotlinx-coroutines-core/kotlinx.coroutines.experimental/async.html
9191
[Deferred]: https://kotlin.github.io/kotlinx.coroutines/kotlinx-coroutines-core/kotlinx.coroutines.experimental/-deferred/index.html
@@ -97,7 +97,7 @@ Select expression to perform multiple suspending operations simultaneously until
9797
[java.util.concurrent.Executor.asCoroutineDispatcher]: https://kotlin.github.io/kotlinx.coroutines/kotlinx-coroutines-core/kotlinx.coroutines.experimental/java.util.concurrent.-executor/as-coroutine-dispatcher.html
9898
[Unconfined]: https://kotlin.github.io/kotlinx.coroutines/kotlinx-coroutines-core/kotlinx.coroutines.experimental/-unconfined/index.html
9999
[NonCancellable]: https://kotlin.github.io/kotlinx.coroutines/kotlinx-coroutines-core/kotlinx.coroutines.experimental/-non-cancellable/index.html
100-
[CoroutineExceptionHandler]: https://kotlin.github.io/kotlinx.coroutines/kotlinx-coroutines-core/kotlinx.coroutines.experimental/-coroutine-exception-handler.html
100+
[CoroutineExceptionHandler]: https://kotlin.github.io/kotlinx.coroutines/kotlinx-coroutines-core/kotlinx.coroutines.experimental/-coroutine-exception-handler/index.html
101101
[delay]: https://kotlin.github.io/kotlinx.coroutines/kotlinx-coroutines-core/kotlinx.coroutines.experimental/delay.html
102102
[yield]: https://kotlin.github.io/kotlinx.coroutines/kotlinx-coroutines-core/kotlinx.coroutines.experimental/yield.html
103103
[run]: https://kotlin.github.io/kotlinx.coroutines/kotlinx-coroutines-core/kotlinx.coroutines.experimental/run.html
@@ -109,7 +109,7 @@ Select expression to perform multiple suspending operations simultaneously until
109109
[suspendCancellableCoroutine]: https://kotlin.github.io/kotlinx.coroutines/kotlinx-coroutines-core/kotlinx.coroutines.experimental/suspend-cancellable-coroutine.html
110110
[newCoroutineContext]: https://kotlin.github.io/kotlinx.coroutines/kotlinx-coroutines-core/kotlinx.coroutines.experimental/new-coroutine-context.html
111111
<!--- INDEX kotlinx.coroutines.experimental.sync -->
112-
[kotlinx.coroutines.experimental.sync.Mutex]: https://kotlin.github.io/kotlinx.coroutines/kotlinx-coroutines-core/kotlinx.coroutines.experimental.sync/-mutex.html
112+
[kotlinx.coroutines.experimental.sync.Mutex]: https://kotlin.github.io/kotlinx.coroutines/kotlinx-coroutines-core/kotlinx.coroutines.experimental.sync/-mutex/index.html
113113
[kotlinx.coroutines.experimental.sync.Mutex.lock]: https://kotlin.github.io/kotlinx.coroutines/kotlinx-coroutines-core/kotlinx.coroutines.experimental.sync/-mutex/lock.html
114114
[kotlinx.coroutines.experimental.sync.Mutex.tryLock]: https://kotlin.github.io/kotlinx.coroutines/kotlinx-coroutines-core/kotlinx.coroutines.experimental.sync/-mutex/try-lock.html
115115
<!--- INDEX kotlinx.coroutines.experimental.channels -->
@@ -119,7 +119,7 @@ Select expression to perform multiple suspending operations simultaneously until
119119
[kotlinx.coroutines.experimental.channels.actor]: https://kotlin.github.io/kotlinx.coroutines/kotlinx-coroutines-core/kotlinx.coroutines.experimental.channels/actor.html
120120
[kotlinx.coroutines.experimental.channels.ActorJob]: https://kotlin.github.io/kotlinx.coroutines/kotlinx-coroutines-core/kotlinx.coroutines.experimental.channels/-actor-job/index.html
121121
[kotlinx.coroutines.experimental.channels.ActorScope]: https://kotlin.github.io/kotlinx.coroutines/kotlinx-coroutines-core/kotlinx.coroutines.experimental.channels/-actor-scope/index.html
122-
[kotlinx.coroutines.experimental.channels.Channel]: https://kotlin.github.io/kotlinx.coroutines/kotlinx-coroutines-core/kotlinx.coroutines.experimental.channels/-channel.html
122+
[kotlinx.coroutines.experimental.channels.Channel]: https://kotlin.github.io/kotlinx.coroutines/kotlinx-coroutines-core/kotlinx.coroutines.experimental.channels/-channel/index.html
123123
[kotlinx.coroutines.experimental.channels.SendChannel.send]: https://kotlin.github.io/kotlinx.coroutines/kotlinx-coroutines-core/kotlinx.coroutines.experimental.channels/-send-channel/send.html
124124
[kotlinx.coroutines.experimental.channels.ReceiveChannel.receive]: https://kotlin.github.io/kotlinx.coroutines/kotlinx-coroutines-core/kotlinx.coroutines.experimental.channels/-receive-channel/receive.html
125125
[kotlinx.coroutines.experimental.channels.SendChannel]: https://kotlin.github.io/kotlinx.coroutines/kotlinx-coroutines-core/kotlinx.coroutines.experimental.channels/-send-channel/index.html

kotlinx-coroutines-core/pom.xml renamed to core/kotlinx-coroutines-core/pom.xml

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,8 @@
2222
<parent>
2323
<groupId>org.jetbrains.kotlinx</groupId>
2424
<artifactId>kotlinx-coroutines</artifactId>
25-
<version>0.17-SNAPSHOT</version>
25+
<version>0.18-SNAPSHOT</version>
26+
<relativePath>../../pom.xml</relativePath>
2627
</parent>
2728

2829
<artifactId>kotlinx-coroutines-core</artifactId>
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.

0 commit comments

Comments
 (0)