Comments (4)
Hi @alipiry. Currently we do not support this; our lowest denominator is seconds. Mind if I ask you if this is a real usecase or just a question out of curiosity? If a real usecase, would you mind to describe it a little further?
from gocron.
I see. If you need this level of granularity I'd suggest using a timer directly. Currently we cannot guarantee at what frame of a second our jobs run. However in the future we might, as we plan to migrate the current core-runner to use timers inside as well.
Oh alright, thanks a lot!
from gocron.
Hello @Streppel, thank you for quick response, yeah it is a real use case, I'm working this project that does 10 concurrent POST requests per second and so I need to send these requests at the very least time.
Here it is my main func:
func main() {
loc, err := time.LoadLocation("Asia/Tehran")
util.CheckError(err)
scheculer := gocron.NewScheduler(loc)
scheculer.Every(1).Day().At("8:29:51").Do(concurrency.Run, broker.Buy)
scheculer.StartBlocking()
}
I want to run my task at "8:29:51.01"
from gocron.
I see. If you need this level of granularity I'd suggest using a timer directly. Currently we cannot guarantee at what frame of a second our jobs run. However in the future we might, as we plan to migrate the current core-runner to use timers inside as well.
from gocron.
Related Issues (20)
- [FEATURE] - Add Distributed Locker At Job level
- [FEATURE] - Add Go 1.22 to test matrix
- [BUG] - WithLimitConcurrentJobs causes jobs not to resume HOT 4
- [Job RunTime] - Provide the next N RunTime for a schedule
- [BUG] - Repo not found when running go get github.com/go-co-op/gocronmocks/v2 HOT 2
- [BUG] - Scheduler with LimitModeWait and Job Singleton mode with LimitModeReschedule - Job Queues up if Scheduler limit reached HOT 6
- [BUG] - Unable to Use timezone in GoCron HOT 1
- [FEATURE] - Dynamic duration
- [FEATURE] - no mechanism to handle panic in jobs for `v2` HOT 10
- [BUG] - OneTimeJobStartDateTime returns error if date in the past HOT 2
- [BUG] - CronJob `withSeconds` documentation and implementation inconsistency
- [FEATURE] - Support for an `AtTimes` job
- [BUG] - OneTime (and potential future jobs) do not clear `NextRun` after last schedule is run HOT 4
- [FEATURE] - Exposing job definition/scheduling information HOT 5
- [FEATURE] - Provide more details of ErrPanicRecovered HOT 2
- [BUG] - library incompatible with the go latest version 1.22.4 HOT 2
- [BUG] - Timing cycle trigger problem HOT 3
- [BUG] - Reschedule Count Up From Time Zero HOT 2
- [FEATURE] - Allow UUID to be set in the job HOT 3
- [BUG] - cannot handle variadic interface parameters HOT 1
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from gocron.