File tree Expand file tree Collapse file tree 2 files changed +5
-1
lines changed
src/main/java/com/diffplug/common/rx Expand file tree Collapse file tree 2 files changed +5
-1
lines changed Original file line number Diff line number Diff line change 1
1
# DurianRx releases
2
2
3
3
## [ Unreleased]
4
+ ### Fixed
5
+ - ` Rx.createEmitFlow() ` now creates a flow with unlimited buffer, same as RxJava's ` PublishSubject ` .
4
6
5
7
## [ 5.0.1] - 2025-01-26
6
8
### Changed
Original file line number Diff line number Diff line change @@ -36,6 +36,7 @@ import kotlinx.coroutines.Deferred
36
36
import kotlinx.coroutines.Job
37
37
import kotlinx.coroutines.asCoroutineDispatcher
38
38
import kotlinx.coroutines.channels.BufferOverflow
39
+ import kotlinx.coroutines.channels.Channel
39
40
import kotlinx.coroutines.flow.Flow
40
41
import kotlinx.coroutines.flow.MutableSharedFlow
41
42
import kotlinx.coroutines.flow.merge
@@ -102,7 +103,8 @@ import kotlinx.coroutines.flow.merge
102
103
object Rx {
103
104
@JvmStatic
104
105
fun <T > createEmitFlow () =
105
- MutableSharedFlow <T >(replay = 0 , extraBufferCapacity = 1 , BufferOverflow .SUSPEND )
106
+ MutableSharedFlow <T >(
107
+ replay = 0 , extraBufferCapacity = Channel .UNLIMITED , BufferOverflow .SUSPEND )
106
108
107
109
@JvmStatic
108
110
fun <T > emit (flow : MutableSharedFlow <T >, value : T ) {
You can’t perform that action at this time.
0 commit comments