-
Notifications
You must be signed in to change notification settings - Fork 1.9k
Version 1.4.0-M1 #2297
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Merged
Merged
Version 1.4.0-M1 #2297
Conversation
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
…blems) DebugLeaksStressTest
* Immediate dispatcher on JS, test added * Style fixes
Non-deprecated 'jmhJar' configuration (#2032) (+9 squashed commits) Squashed commits: [8d07d36] Use new Kotlin/JS plugin (#1983) * Use new Kotlin/JS plugin * Support legacy DCE mode for 1.4-M2 [d224640] Add Dokka configuration method [56e1c9b] Dokka plugin in 'buildSrc' [dfdd202] Remove unused repositories [4cf1d02] Kotlin DSL - 'javafx' [d8f7d50] Avoid task name duplication [f06a56b] Avoid task name duplication [a09df3d] Separate 'UnpackAar' action [fd5bf6b] Separate 'RunR8' task
* General cleanup and TODOs Co-authored with: [email protected]
On CI set CACHE_REDIRECTOR=true environment property.
This commit adds awaitSingle variants similar to awaitFirst ones, but always emitting the value during onComplete(). Fixes #1993
The latest part of #2026
It seems to be the legacy from times when CC was a Job, in order to observe behaviour change, a specific example should be accurately made
* Kotlin DSL - 'reactive:reactor' * Kotlin DSL - 'reactive:jdk9' * Kotlin DSL - 'kotlinx-coroutines-slf4j' * Kotlin DSL - 'kotlinx-coroutines-guava' * Plugin repo management in 'pluginManagement' block * Remove redundant stdlib dependencies (#2253) Co-authored-by: Victor Turansky <[email protected]>
#2285) * Provide asFlowable and asObservable by their names in binary instead of 'from' function to prevent naming clash for Java users. * Do not provide @jvmoverloads for convenience of Java interop * Deprecate ReceiveChannel.asObservable by the way Fixes #2182
* All Flow.debounce/sample KDoc example code snippets are automatically tested with Knit. * Flow.sample timings are made larger, so that they produce an expected output when run under the real time, too. Fixes #2243
This is a tricky gotcha that needs additional explanation. There are two examples added, one showing the bad code and explaining why it does not work, and the other showing the correct way to write it. Fixes #2233
) Added instructions to work around #2023 Also, the answer to #2274 is now documented. Co-authored-by: Vsevolod Tolstopyatov <[email protected]>
When the Executor that was used with Executor.asCoroutineDispatcher() extension rejects the submitted task, it means that it had reached its capacity and so the executing current Job should be canceled to terminate it as soon as possible. This way RejectedExecutionException works as a rate-limiter just like it serves this purpose in executor-based Java code. Fixes #2003
…uncher (#2074) New source sets: * "concurrent" source set is shared between "jvm" and "native" * "native" source set is subdivided into "nativeDarwin" (Apple) and "nativeOther" (Linux, etc) Native tests are launched in two variants: * A default "test" task runs tests with memory leak checker from "mainNoExit" entry point. * A special "backgroundTest" task runs tests in a background worker from "mainBackground" entry point. Other build improvement: * Modernize old-style IDEA-active hacks to kts helper. * Extract versions of JS test runner dependencies. * Remove redundant google repo reference from android tests.
…1937) This is a problematic for Android when Main dispatcher is cancelled on destroyed activity. Atomic nature of channels is designed to prevent loss of elements, which is really not an issue for a typical application, but creates problem when used with channels. * Internal suspendAtomicCancellableCoroutine -> suspendCancellableCoroutine * Internal suspendAtomicCancellableCoroutineReusable -> suspendCancellableCoroutineReusable * Remove atomic cancellation from docs * Ensures that flowOn does not resume downstream after cancellation. * MODE_ATOMIC_DEFAULT renamed into MODE_ATOMIC * Introduced MODE_CANCELLABLE_REUSABLE to track suspendCancellableCoroutineReusable * Better documentation for MODE_XXX constants. * Added stress test for proper handling of MODE_CANCELLABLE_REUSABLE and fixed test for #1123 bug with job.join (working in MODE_CANCELLABLE) that was not properly failing in the absence of the proper code in CancellableContinuationImpl.getResult * Added test for Flow.combine that should be fixed * Support extended invokeOnCancellation contract * Introduced internal tryResumeAtomic * Channel onUnderliveredElement is introduced as a replacement. Fixes #1265 Fixes #1813 Fixes #1915 Fixes #1936 Co-authored-by: Louis CAD <[email protected]> Co-authored-by: Vsevolod Tolstopyatov <[email protected]>
* Introduce SharedFlow and sharing operators Summary of changes: * SharedFlow, MutableSharedFlow and its constructor. * StateFlow implements SharedFlow. * SharedFlow.onSubscription operator, clarified docs in other onXxx operators. * BufferOverflow strategy in kotlinx.coroutines.channels package. * shareIn and stateIn operators and SharingStarted strategies for them. * SharedFlow.flowOn error lint (up from StateFlow). * Precise cancellable() operator fusion. * Precise distinctUntilChanged() operator fusion. * StateFlow.compareAndSet function. * asStateFlow and asSharedFlow read-only view functions. * Consistently clarified docs on cold vs hot flows. * Future deprecation notice for BroadcastChannel, ConflatedBroadcastChannel, broadcast, and broadcastIn. * Channel(...) constructor function has onBufferOverflow parameter. * buffer(...) operator has onBufferOverflow parameter. * shareIn/stateIn buffer and overflow strategy are configured via upstream buffer operators. * shareIn/stateIn fuse with upstream flowOn for more efficient execution. * conflate() is implemented as buffer(onBufferOverflow=KEEP_LATEST), non-suspending strategies are reasonably supported with 0 and default capacities. * Added reactive operator migration hints. * WhileSubscribed with kotlin.time.Duration params Fixes #2034 Fixes #2047 Co-authored-by: Ibraheem Zaman <[email protected]> Co-authored-by: Thomas Vos <[email protected]> Co-authored-by: Travis Wyatt <[email protected]>
elizarov
reviewed
Oct 13, 2020
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Some suggested text improvements
eed4226
to
f3a9b60
Compare
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
No description provided.