-
Notifications
You must be signed in to change notification settings - Fork 11
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Move Delivery Retry logic outside EmbraceApiService.
- Loading branch information
1 parent
143544f
commit 4dae99c
Showing
8 changed files
with
586 additions
and
424 deletions.
There are no files selected for viewing
This file contains 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
19 changes: 19 additions & 0 deletions
19
...id-sdk/src/main/java/io/embrace/android/embracesdk/comms/delivery/DeliveryRetryManager.kt
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,19 @@ | ||
package io.embrace.android.embracesdk.comms.delivery | ||
|
||
import io.embrace.android.embracesdk.comms.api.ApiRequest | ||
|
||
/** | ||
* Manages the retrying of failed API calls. | ||
*/ | ||
internal interface DeliveryRetryManager { | ||
|
||
/** | ||
* Schedules a failed API call for retry. | ||
*/ | ||
fun scheduleForRetry(request: ApiRequest, payload: ByteArray) | ||
|
||
/** | ||
* Sets the executor that will be used to retry failed API calls. | ||
*/ | ||
fun setPostExecutor(postExecutor: (request: ApiRequest, payload: ByteArray) -> Unit) | ||
} |
Oops, something went wrong.