Releases: slackhq/EitherNet
Releases · slackhq/EitherNet
1.9.0
- Update to Kotlin
2.0.0
.
What's Changed
- Update to K2 by @ZacSweers in #72
Full Changelog: 1.8.1...1.9.0
1.8.1
- Fix: (hopefully) fix kdocs publishing for test fixtures.
- Update to Kotlin
1.9.22
.
What's Changed
- Update misc repo infra by @ZacSweers in #75
- Try fixing doc publishing for test fixtures by @ZacSweers in #73
Full Changelog: 1.8.0...1.8.1
1.8.0
- Fix: Deprecate old
fold()
functions and introduce new ones that use the underlying value rather thanSuccess
. This was an oversight in the previous implementation. Binary compatibility is preserved. - Enhancement: Mark functions
inline
where possible to allow carried over context (i.e. in suspend functions, etc) - Enhancement: Use contracts to inform the compiler about possible calls to lambdas.
- New: Add fluent
onSuccess
andonFailure*
functional extension APIs toApiResult
.
What's Changed
- Misc extensions improvements by @ZacSweers in #71
Full Changelog: 1.7.0...1.8.0
1.7.0
- Enhancement: Add new
ApiResult<*, *>.successOrNothing()
andApiResult.Failure<*>.exceptionOrNull()
functional extension APIs. - Update to Kotlin
1.9.20
.
What's Changed
- Prepare for Kotlin 1.9.20 by @ZacSweers in #67
- Add successOrNothing and exceptionOrNull extensions by @ZacSweers in #70
Full Changelog: 1.6.0...1.7.0
1.6.0
- Enhancement: Add
shouldRetry
parameter toretryWithExponentialBackoff()
to allow conditional short-circuiting of retries.
What's Changed
- Add shouldRetry overload for retries by @ZacSweers in #69
Full Changelog: 1.5.0...1.6.0
1.5.0
1.4.1
1.4.0
Happy new year!
A common pattern in making network requests is to retry with exponential backoff. EitherNet now ships with a highly configurable retryWithExponentialBackoff()
function for this case.
// Defaults for reference
val result = retryWithExponentialBackoff(
maxAttempts = 3,
initialDelay = 500.milliseconds,
delayFactor = 2.0,
maxDelay = 10.seconds,
jitterFactor = 0.25,
onFailure = null, // Optional Failure callback for logging
) {
api.getData()
}
- Update to Kotlin
1.8.21
. - Update to Kotlin Coroutines
1.7.1
. - EitherNet now depends on
org.jetbrains.kotlinx:kotlinx-coroutines-core
.
1.3.1
1.3.0
- Update to Kotlin
1.8.0
. - Fix: Fix exception on annotation traversal when target is not present
- Fix: Publish test-fixtures artifact sources.
- Update to JVM target 11.
What's Changed
- Fix exception on annotation traversal when target is not present by @flavioarfaria in #51
- Update gradle to 7.4.2.+ deps by @ZacSweers in #52
- Misc updates, mostly around Kotlin 1.7.20 by @ZacSweers in #54
- Use version catalogs + target java 11 by @ZacSweers in #55
- Update misc dependencies by @ZacSweers in #57
New Contributors
- @flavioarfaria made their first contribution in #51
Full Changelog: 1.2.1...1.3.0