Skip to content

Commit

Permalink
Update all dependencies (#3275)
Browse files Browse the repository at this point in the history
* Update all dependencies

| datasource | package                                                                                           | from          | to            |
| ---------- | ------------------------------------------------------------------------------------------------- | ------------- | ------------- |
| maven      | com.google.devtools.ksp:com.google.devtools.ksp.gradle.plugin                                     | 1.9.10-1.0.13 | 1.9.20-1.0.13 |
| maven      | com.google.devtools.ksp:symbol-processing-api                                                     | 1.9.10-1.0.13 | 1.9.20-1.0.13 |
| maven      | org.jetbrains.kotlin.plugin.serialization:org.jetbrains.kotlin.plugin.serialization.gradle.plugin | 1.9.10        | 1.9.20        |
| maven      | org.jetbrains.kotlin.multiplatform:org.jetbrains.kotlin.multiplatform.gradle.plugin               | 1.9.10        | 1.9.20        |
| maven      | org.jetbrains.kotlin.jvm:org.jetbrains.kotlin.jvm.gradle.plugin                                   | 1.9.10        | 1.9.20        |

Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
Co-authored-by: Alejandro Serrano Mena <trupill@gmail.com>
  • Loading branch information
renovate[bot] and serras authored Nov 4, 2023
1 parent 1a2927b commit fde5680
Show file tree
Hide file tree
Showing 6 changed files with 48 additions and 45 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/pull_request.yml
Original file line number Diff line number Diff line change
Expand Up @@ -179,7 +179,7 @@ jobs:
- name: jvmTest (K2 enabled)
uses: gradle/gradle-build-action@v2
with:
arguments: "jvmTest -Pkotlin_version=2.0.0-dev-5387 -Pkotlin_repo_url=https://maven.pkg.jetbrains.space/kotlin/p/kotlin/bootstrap -Pkotlin_language_version=2.0"
arguments: "jvmTest -Pkotlin_version=2.0.0-dev-6573 -Pkotlin_repo_url=https://maven.pkg.jetbrains.space/kotlin/p/kotlin/bootstrap -Pkotlin_language_version=2.0 -Pkotlin_api_version=2.0"

- name: Upload reports
if: failure()
Expand Down
Original file line number Diff line number Diff line change
@@ -1,3 +1,5 @@
@file:Suppress("DUPLICATE_PARAMETER_NAME_IN_FUNCTION_TYPE")

package arrow.core

import arrow.core.test.either
Expand Down
Original file line number Diff line number Diff line change
@@ -1,3 +1,5 @@
@file:Suppress("DUPLICATE_PARAMETER_NAME_IN_FUNCTION_TYPE")

package arrow.core

import arrow.core.test.laws.MonoidLaws
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -621,26 +621,31 @@ private constructor(
onClosed: suspend () -> Unit = { },
onHalfOpen: suspend () -> Unit = { },
onOpen: suspend () -> Unit = { },
): CircuitBreaker =
CircuitBreaker(
): CircuitBreaker {
require(maxFailures >= 0) {
"maxFailures expected to be greater than or equal to 0, but was $maxFailures"
}
require(resetTimeoutNanos > 0) {
"resetTimeout expected to be greater than 0, but was $resetTimeoutNanos"
}
require(exponentialBackoffFactor > 0) {
"exponentialBackoffFactor expected to be greater than 0, but was $exponentialBackoffFactor"
}
require(maxResetTimeoutNanos > 0) {
"maxResetTimeout expected to be greater than 0, but was $maxResetTimeoutNanos"
}
return CircuitBreaker(
state = AtomicRef(Closed(0)),
maxFailures = maxFailures
.takeIf { it >= 0 }
.let { requireNotNull(it) { "maxFailures expected to be greater than or equal to 0, but was $maxFailures" } },
resetTimeoutNanos = resetTimeoutNanos
.takeIf { it > 0 }
.let { requireNotNull(it) { "resetTimeout expected to be greater than 0, but was $resetTimeoutNanos" } },
exponentialBackoffFactor = exponentialBackoffFactor
.takeIf { it > 0 }
.let { requireNotNull(it) { "exponentialBackoffFactor expected to be greater than 0, but was $exponentialBackoffFactor" } },
maxResetTimeoutNanos = maxResetTimeoutNanos
.takeIf { it > 0 }
.let { requireNotNull(it) { "maxResetTimeout expected to be greater than 0, but was $maxResetTimeoutNanos" } },
maxFailures = maxFailures,
resetTimeoutNanos = resetTimeoutNanos,
exponentialBackoffFactor = exponentialBackoffFactor,
maxResetTimeoutNanos = maxResetTimeoutNanos,
onRejected = onRejected,
onClosed = onClosed,
onHalfOpen = onHalfOpen,
onOpen = onOpen
)
}

/**
* Attempts to create a [CircuitBreaker].
Expand Down Expand Up @@ -682,20 +687,10 @@ private constructor(
onOpen: suspend () -> Unit = suspend { },
): CircuitBreaker =
of(
maxFailures = maxFailures
.takeIf { it >= 0 }
.let { requireNotNull(it) { "maxFailures expected to be greater than or equal to 0, but was $maxFailures" } },
resetTimeoutNanos = resetTimeout
.takeIf { it.isPositive() && it != Duration.ZERO }
.let { requireNotNull(it) { "resetTimeout expected to be greater than ${Duration.ZERO}, but was $resetTimeout" } }
.toDouble(DurationUnit.NANOSECONDS),
exponentialBackoffFactor = exponentialBackoffFactor
.takeIf { it > 0 }
.let { requireNotNull(it) { "exponentialBackoffFactor expected to be greater than 0, but was $exponentialBackoffFactor" } },
maxResetTimeoutNanos = maxResetTimeout
.takeIf { it.isPositive() && it != Duration.ZERO }
.let { requireNotNull(it) { "maxResetTimeout expected to be greater than ${Duration.ZERO}, but was $maxResetTimeout" } }
.toDouble(DurationUnit.NANOSECONDS),
maxFailures = maxFailures,
resetTimeoutNanos = resetTimeout.toDouble(DurationUnit.NANOSECONDS),
exponentialBackoffFactor = exponentialBackoffFactor,
maxResetTimeoutNanos = maxResetTimeout.toDouble(DurationUnit.NANOSECONDS),
onRejected = onRejected,
onClosed = onClosed,
onHalfOpen = onHalfOpen,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -520,24 +520,28 @@ private constructor(
onClosed: suspend () -> Unit = suspend { },
onHalfOpen: suspend () -> Unit = suspend { },
onOpen: suspend () -> Unit = suspend { }
): CircuitBreaker =
CircuitBreaker(
): CircuitBreaker {
require(resetTimeout > Duration.ZERO) {
"resetTimeout expected to be greater than ${Duration.ZERO}, but was $resetTimeout"
}
require(exponentialBackoffFactor > 0) {
"exponentialBackoffFactor expected to be greater than 0, but was $exponentialBackoffFactor"
}
require(maxResetTimeout > Duration.ZERO) {
"maxResetTimeout expected to be greater than ${Duration.ZERO}, but was $maxResetTimeout"
}
return CircuitBreaker(
state = AtomicRef(Closed(openingStrategy)),
resetTimeout = resetTimeout
.takeIf { it.isPositive() && it != Duration.ZERO }
.let { requireNotNull(it) { "resetTimeout expected to be greater than ${Duration.ZERO}, but was $resetTimeout" } },
exponentialBackoffFactor = exponentialBackoffFactor
.takeIf { it > 0 }
.let { requireNotNull(it) { "exponentialBackoffFactor expected to be greater than 0, but was $exponentialBackoffFactor" } },
maxResetTimeout = maxResetTimeout
.takeIf { it.isPositive() && it != Duration.ZERO }
.let { requireNotNull(it) { "maxResetTimeout expected to be greater than ${Duration.ZERO}, but was $maxResetTimeout" } },
resetTimeout = resetTimeout,
exponentialBackoffFactor = exponentialBackoffFactor,
maxResetTimeout = maxResetTimeout,
timeSource = timeSource,
onRejected = onRejected,
onClosed = onClosed,
onHalfOpen = onHalfOpen,
onOpen = onOpen
)
}
}

public sealed class OpeningStrategy {
Expand Down
10 changes: 5 additions & 5 deletions gradle/libs.versions.toml
Original file line number Diff line number Diff line change
Expand Up @@ -8,15 +8,15 @@ dokka = "1.9.10"
jUnit = "4.13.2"
jUnitJupiter = "5.10.0"
jUnitVintage = "5.10.0"
kotest = "5.7.2"
kotestGradle = "5.7.2"
kotest = "5.8.0"
kotestGradle = "5.8.0"
kover = "0.7.4"
kotlin = "1.9.10"
kotlinxSerializationPlugin = "1.9.10"
kotlin = "1.9.20"
kotlinxSerializationPlugin = "1.9.20"
kotlinBinaryCompatibilityValidator = "0.13.2"
kotlinCompileTesting = "1.5.0"
knit = "0.4.0"
kspVersion = "1.9.10-1.0.13"
kspVersion = "1.9.20-1.0.14"
kotlinxSerialization = "1.6.0"
mockWebServer = "4.12.0"
retrofit = "2.9.0"
Expand Down

0 comments on commit fde5680

Please sign in to comment.