53
) *scheduledQueue {
54
paginationFnProvider := func(r Range) collection.PaginationFn[tasks.Task] {
55
>
return func(paginationToken []byte) ([]tasks.Task, []byte, error) {
queue_scheduled.go
56
>
ctx, cancel := newQueueIOContext()
57
>
defer cancel()
58
>
59
>
request := &persistence.GetHistoryTasksRequest{
60
>
ShardID: shard.GetShardID(),
61
>
TaskCategory: category,
62
>
InclusiveMinTaskKey: tasks.NewKey(r.InclusiveMin.FireTime, 0),
63
>
ExclusiveMaxTaskKey: tasks.NewKey(
64
>
r.ExclusiveMax.FireTime.Add(common.ScheduledTaskMinPrecision),
65
>
0,
66
>
),
67
>
BatchSize: options.BatchSize(),
68
>
NextPageToken: paginationToken,
69
>
}
70
>
71
>
resp, err := shard.GetHistoryTasks(ctx, request)
72
>
if err != nil {
73
return nil, nil, err
74
}