Skip to content

Commit 6107881

Browse files
committed
Version 0.5-beta readme and changes
1 parent 7deefb8 commit 6107881

File tree

3 files changed

+31
-16
lines changed

3 files changed

+31
-16
lines changed

CHANGES.md

Lines changed: 14 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,17 @@
1-
# kotlinx.coroutines change log
1+
# Change log for kotlinx.coroutines
2+
3+
## Version 0.5-beta
4+
5+
* Switched to Kotlin version 1.1.0-beta-22 (republished version).
6+
* Removed `currentCoroutineContext` and related thread-locals without replacement.
7+
Explicitly pass coroutine context around if needed.
8+
* `lazyDefer(context) {...}` coroutine builder and `LazyDeferred` interface are introduced.
9+
* The default behaviour of all coroutine dispatchers is changed to always schedule execution of new coroutine
10+
for later in this thread or thread pool. Correspondingly, `CoroutineDispatcher.isDispatchNeeded` function
11+
has a default implementation that returns `true`.
12+
* `NonCancellable` context is introduced.
13+
* Performance optimizations for cancellable continuations (fewer objects created).
14+
* A [guide on coroutines](coroutines-guide.md) is added.
215

316
## Version 0.4-beta
417

README.md

Lines changed: 15 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -1,18 +1,20 @@
11
# kotlinx.coroutines
22

3-
Library support for Kotlin coroutines. This is a companion version for Kotlin 1.1.0-beta-18 release.
3+
Library support for Kotlin coroutines. This is a companion version for Kotlin 1.1.0-beta-22 release.
44

55
## Modules and features
66

77
* `kotlinx-coroutines-core` module with core primitives to work with coroutines. It is designed to work on any JDK6+ and Android
88
and contains the following main pieces:
9-
* `launch(context) { ... }` to start a coroutine in the given context and get reference to its `Job`.
10-
* `run(context) { ... }` to switch to a different context inside a coroutine.
11-
* `runBlocking { ... }` to use asynchronous Kotlin APIs from a thread-blocking code.
12-
* `defer(context) { ... }` to get a deferred result of coroutine execution in a non-blocking way
13-
via a light-weight future interface called `Deferred`.
14-
* `delay(...)` for a non-blocking sleep in coroutines.
15-
* `CommonPool` and `Here` contexts, `context` or a parent coroutine.
9+
* `launch(context) {...}` to start a coroutine in the given context and get reference to its `Job`.
10+
* `run(context) {...}` to switch to a different context inside a coroutine.
11+
* `runBlocking {...}` to use asynchronous Kotlin APIs from a thread-blocking code.
12+
* `defer(context) {...}` and `lazyDefer(context) {...}` to get a deferred result of coroutine execution in a
13+
non-blocking way via a light-weight future interface called `Deferred`.
14+
* `delay(...)` for a non-blocking sleep in coroutines and `yield` to release a thread in single-threaded dispatchers.
15+
* `withTimeout(timeout) {...}` scope function to easily set coroutine time-limit (deadline),
16+
and `NonCancellable` context to avoid it when needed.
17+
* `CommonPool` and `Here` contexts, access to `context` of a parent coroutine in its `CoroutineScope`.
1618
* `newSingleThreadContext(...)` and `newFixedThreadPoolContext(...)` functions,
1719
`Executor.toCoroutineDispatcher()` extension.
1820
* Cancellation support with `Job` interface and `suspendCancellableCoroutine` helper function.
@@ -36,9 +38,9 @@ from inside coroutines. It is in very basic form now (example-only, not even clo
3638

3739
## References and documentation
3840

39-
* [Coroutines guide](coroutines-guide.md)
40-
* [Change log](CHANGES.md)
41-
* [Coroutines design document](https://github.com/Kotlin/kotlin-coroutines/blob/master/kotlin-coroutines-informal.md)
41+
* [Guide to kotlinx.coroutines by example](coroutines-guide.md)
42+
* [Change log for kotlinx.coroutines](CHANGES.md)
43+
* [Coroutines design document (KEEP)](https://github.com/Kotlin/kotlin-coroutines/blob/master/kotlin-coroutines-informal.md)
4244

4345
## Using in your projects
4446

@@ -79,7 +81,7 @@ And make sure that you use the right Kotlin version:
7981

8082
```xml
8183
<properties>
82-
<kotlin.version>1.1.0-beta-18</kotlin.version>
84+
<kotlin.version>1.1.0-beta-22</kotlin.version>
8385
</properties>
8486
```
8587

@@ -105,6 +107,6 @@ And make sure that you use the right Kotlin version:
105107

106108
```groovy
107109
buildscript {
108-
ext.kotlin_version = '1.1.0-beta-18'
110+
ext.kotlin_version = '1.1.0-beta-22'
109111
}
110112
```

pom.xml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@
77

88
<groupId>org.jetbrains.kotlinx</groupId>
99
<artifactId>kotlinx-coroutines</artifactId>
10-
<version>0.4-beta-SNAPSHOT</version>
10+
<version>0.5-beta-SNAPSHOT</version>
1111
<packaging>pom</packaging>
1212

1313
<name>Kotlin coroutines libraries</name>
@@ -61,7 +61,7 @@
6161

6262
<properties>
6363
<project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
64-
<kotlin.version>1.1.0-beta-18</kotlin.version>
64+
<kotlin.version>1.1.0-beta-22</kotlin.version>
6565
<dokka.version>0.9.13</dokka.version>
6666
<junit.version>4.12</junit.version>
6767
<maven.compiler.source>1.6</maven.compiler.source>

0 commit comments

Comments
 (0)