如何指定重试 retry_policy_policy_exponential ,以下是我的代码
val job: Job =dispatcher.newJobBuilder()
.setTag("mytesttag")
.setService(MyJobService::class.java)
.setRetryStrategy(RetryStrategy.DEFAULT_EXPONENTIAL)
.build()
得到它,可以使用 firebasejobdispatcher 实例,就像此
var job = dispatcher.newJobBuilder()
.setTag("mytesttag")
.setService(MyJobService::class.java)
.setRetryStrategy(dispatcher.newRetryStrategy(
RetryStrategy.RETRY_POLICY_EXPONENTIAL,30,300))
.build()