<!-- #Number of retries on failure orderTaskWorker.retryCount=100 #Retry weight, the algorithm is: current time + (rate * retryCount) > update time, executable orderTaskWorker.rate=100 --> and RetryCount <= #retryCount# and UpdateTime < dateadd(n, #rate# * RetryCount, getdate())
<!--Unlock reset times plus one--> <update id="unlockTask" parameterClass="java.lang.Long"> update MayiTask set IsFinished = 0, RetryCount = RetryCount + 1, UpdateTime = getdate() where Id = #value# and IsFinished = 100 </update>