I'm dynamically inserting jobs into river with ScheduledAt attribute.
It seems from my tests that when I call:
res, err := riverClient.Insert(ctx,
SomeArgs{}, &river.InsertOpts{
ScheduledAt: scheduleTime,
UniqueOpts: river.UniqueOpts{
ByPeriod: 12 * time.Minute,
},
},
)
twice in a loop, second job is treated as violating uniqueness condition and not created. scheduleTime is (of course) different by more than 12 minutes.
Does "Uniqueness" feature check only created time, and dosen't work well with scheduled?
I'm dynamically inserting jobs into river with ScheduledAt attribute.
It seems from my tests that when I call:
twice in a loop, second job is treated as violating uniqueness condition and not created.
scheduleTimeis (of course) different by more than 12 minutes.Does "Uniqueness" feature check only created time, and dosen't work well with scheduled?