Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Worker started every secondes #143

Open
DavidHenryThoreau opened this issue May 7, 2024 · 5 comments
Open

Worker started every secondes #143

DavidHenryThoreau opened this issue May 7, 2024 · 5 comments

Comments

@DavidHenryThoreau
Copy link
Contributor

I'm looking at docker logs workout-tracker -f

It's appears a worker starts every secondes, is that normal ?

"time":"2024-05-07T11:12:53.151237364+02:00","level":"INFO","msg":"Worker started...","app":"workout-tracker","version":"v0.14.2"
{"time":"2024-05-07T11:12:53.153765084+02:00","level":"INFO","msg":"Worker finished...","app":"workout-tracker","version":"v0.14.2","s
{"time":"2024-05-07T11:14:53.167323297+02:00","level":"INFO","msg":"Worker started...","app":"workout-tracker","version":"v0.14.2","
{"time":"2024-05-07T11:14:53.16989256+02:00","level":"INFO","msg":"Worker finished...","app":"workout-tracker","version":"v0.14.2",
@jovandeginste
Copy link
Owner

It seems from your logs to start every two minutes; you see a log line when it starts, and when it finishes.

... which is strange, because the code says it should sleep for one minute...

@DavidHenryThoreau
Copy link
Contributor Author

Yes, every two minutes.
Do you have documentation about that worker ?

@jovandeginste
Copy link
Owner

Not really; you mean what it is expected to do?

@DavidHenryThoreau
Copy link
Contributor Author

It's strange that waits every two minutes, I mean it could be better to trigger an action if something is happened instead of watting every two minutes ?

@jovandeginste
Copy link
Owner

It checks if any user has an import directory (and then checks if something should be imported), and if any workouts should be re-parsed (for bulk operations which take too long to run live)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants