Skip to content

Commit

Permalink
Change default consolidation mode to AUTO (#159)
Browse files Browse the repository at this point in the history
* Change default consolidation mode to AUTO

* Implement default function for ConsolidationMode
  • Loading branch information
oteffahi authored Aug 7, 2024
1 parent feefac9 commit 6ec7988
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -35,4 +35,8 @@ enum class ConsolidationMode {

/** Holds back samples to only send the set of samples that had the highest timestamp for their key. */
LATEST;

companion object {
fun default() = AUTO
}
}
2 changes: 1 addition & 1 deletion zenoh-kotlin/src/commonMain/kotlin/io/zenoh/query/Get.kt
Original file line number Diff line number Diff line change
Expand Up @@ -83,7 +83,7 @@ class Get<R> private constructor() {

private var timeout = Duration.ofMillis(10000)
private var target: QueryTarget = QueryTarget.BEST_MATCHING
private var consolidation: ConsolidationMode = ConsolidationMode.NONE
private var consolidation: ConsolidationMode = ConsolidationMode.default()
private var value: Value? = null
private var attachment: ByteArray? = null
private var onClose: (() -> Unit)? = null
Expand Down

0 comments on commit 6ec7988

Please sign in to comment.