CRON Scheduling

project id: 1b326884-0c17-43ed-9b52-f443662e8f50 Is it fine to enable App Sleeping for a CRON schedule service? I have a service (the psql s3 backup) but it missed the scheduled time. I wonder if I have something not configured properly. Something just feels off. Not to mention, it keeps reseting when it was "sleeping since". Not sure if this is just a UI bug. But it was definitely wrong. If there is a better way to setup / configure this, just lmk
No description
No description
No description
Solution:
then you wouldn't want to enable app sleeping with any kind of cron job / service
Jump to solution
28 Replies
Percy
Percy3w ago
Project ID: 1b326884-0c17-43ed-9b52-f443662e8f50
Brody
Brody3w ago
do you have it in single shot mode?
Joshie
Joshie3w ago
yea When I manually run it, it does work properly.
Solution
Brody
Brody3w ago
then you wouldn't want to enable app sleeping with any kind of cron job / service
Joshie
Joshie3w ago
No description
Joshie
Joshie3w ago
Ok yea. That is what I was wondering. Wasn't sure; but I did suspect that. It does feel strange to me though. ..... wait. Is this just a reporting thing .... it seemed to me that it was still consuming resources. But I guess if it wasn't and it just shows up in the graphs as if it is,,, hmmmmmm So if it is in single shot and has a railway CRON schedule, I don't need to sleep it, becuase the whole service is exited, taking up 0 resources; right?
Brody
Brody3w ago
that's correct also, even if you where using it's node-cron thing, you still wouldn't want to sleep it, because it's not like it can wake itself up the only thing than can wake a service is inbound public or private traffic
Joshie
Joshie3w ago
Right, this is intuitive. But I would think that a CRON schedule would wake it up. But I guess not.
Brody
Brody3w ago
nope, there's no traffic with that, ideally that option would be removed from the UI if you have cron enabled
Joshie
Joshie3w ago
Yea, that could make sense. I wonder if there is ever a reason why you would still want to sleep.
Brody
Brody3w ago
nope, there would not be a good reason to sleep a cron job
Joshie
Joshie3w ago
hmmmmm something feels off here ....
No description
No description
No description
Joshie
Joshie3w ago
No description
Brody
Brody3w ago
not enough data point to correctly draw a graph
Joshie
Joshie3w ago
Yea, I figure that too. Just more interesting that the different time scales show different data.
Joshie
Joshie3w ago
Should I manually remove the sleeping deployment?
No description
Brody
Brody3w ago
I blame the module they use for graphs yes
Joshie
Joshie3w ago
oh ummm or not
No description
Brody
Brody3w ago
haha, switch it back to a regular service for now
Joshie
Joshie3w ago
Turn off single shot?
Brody
Brody3w ago
no no just remove the cron expression to switch it back to a regular service but side note, glad you're using my single shot mode!
Joshie
Joshie3w ago
I figure it is better to use platform native options. And more than that, I have some ideas for a service I need to make. So I want to test out the railway native options
Brody
Brody3w ago
oh sorry I mean switch it back to a regular service to fix the sleeping service and then switch it back to a cron service
Joshie
Joshie3w ago
I kinda figured that, that is what you meant
Brody
Brody3w ago
you're the second person I've seen enabled app sleeping on a cron service
Joshie
Joshie3w ago
It did fix it
Brody
Brody3w ago
awesome
Brody
Brody3w ago
please do not close threads