Open DJNinNZ opened 4 years ago
I have just deployed the app on our test platform and let it not used (less than 10 connections a day) and it costs 3,6€ of App Engine per day. Because of the cron I guess. The other services don't cost for now. I'd use F1 App Engine instances instead of F4 to reduce the cost (and I'm not quite sure why there are Datastore and BigQuery...)
@DJNinNZ and @ValentinCoudert we've worked with several partners regarding running costs (how to optimize to some extent) and since this is OSS, we kind of let you all configure it to exactly what works best for your organization.
As with most things, everyone will have various mileage/experience on a matter such as this. Depending on the fleet size, how often crons are running, how frequently the Chrome App is making heartbeats, how often an API call is made, etc will all have an impact on the cost. If you're trying to run with minimal costs, look into changing the heartbeat and cron frequency, but do understand there are obvious trade-offs with things such as data insights and reporting.
If any of our OSS users feel comfortable sharing more info on their costs and maybe a bit more about their fleet size, cron frequency, etc, I think that might help @DJNinNZ. To my knowledge (currently) what we push to OSS is pretty much exactly what our frequencies internally are for crons and heartbeats. I hope this helps!
On our prod domain - promevo.com - we see about 135-150 a month, 1 shelf, 4 devices, light usage, stock cron settings.
On Thu, Sep 19, 2019 at 12:27 PM Michael Helfrich notifications@github.com wrote:
@DJNinNZ https://github.com/DJNinNZ and @ValentinCoudert https://github.com/ValentinCoudert we've worked with several partners regarding running costs (how to optimize to some extent) and since this is OSS, we kind of let you all configure it to exactly what works best for your organization.
As with most things, everyone will have various mileage/experience on a matter such as this. Depending on the fleet size, how often crons are running, how frequently the Chrome App is making heartbeats, how often an API call is made, etc will all have an impact on the cost. If you're trying to run with minimal costs, look into changing the heartbeat and cron frequency, but do understand there are obvious trade-offs with things such as data insights and reporting.
If any of our OSS users feel comfortable sharing more info on their costs and maybe a bit more about their fleet size, cron frequency, etc, I think that might help @DJNinNZ https://github.com/DJNinNZ. To my knowledge (currently) what we push to OSS is pretty much exactly what our frequencies internally are for crons and heartbeats. I hope this helps!
— You are receiving this because you are subscribed to this thread. Reply to this email directly, view it on GitHub https://github.com/google/loaner/issues/72?email_source=notifications&email_token=ALGD54WSQ3WPAG5WT4L5R63QKOSAVA5CNFSM4IV6OIL2YY3PNVWWK3TUL52HS4DFVREXG43VMVBW63LNMVXHJKTDN5WW2ZLOORPWSZGOD7EB5MI#issuecomment-533208753, or mute the thread https://github.com/notifications/unsubscribe-auth/ALGD54RXVMEGH5R7NSIZBF3QKOSAVANCNFSM4IV6OILQ .
we have >400 Chromebooks in GnG, with >1000 staff have taken out loans, our billing is showing these costs for September:
We have around 20 racks distributed around our sites and we are using a very light touch in that we do not audit our racks, we expect staff to behave properly, and we know that Chromebooks will be locked after 10 days. I'm impressed that GnG hasn't fallen-over at all in the past six months, we have clocked-up thousands of loans and I probably spend about a couple of days per month keeping things tidy by responding to emails from users, marking devices as returned from time to to time and unlocking devices once I know that they're in a rack (typically, devices are locked because the device itself has been "unlucky" and hasn't been used or someone's take it home/put it in their locker; I just send them an email and ask what they're doing with the device.
We're going to be engaging with the various rack custodians and we'll evolve our service to see how we can improve from here.
It's difficult to imagine a simpler, less resource-intensive system. I'm just dying to see what the next big release will do!
Hi everyone, thanks for the feedback. can you confirm where and how these are set? Heartbeat part of the Chrome app, currently 5 minutes, hardcoded in loaner/loaner/chrome_app/src/app/background/heartbeat.ts requires rebuild and republishing of the Chrome App
Cron Jobs part of the web app, various intervals, hardcoded in loaner/loaner/web_app/cron.yaml requires rebuild and push of new appengine version
Regards
Hi everyone, thanks for the feedback. can you confirm where and how these are set? Heartbeat part of the Chrome app, currently 5 minutes, hardcoded in loaner/loaner/chrome_app/src/app/background/heartbeat.ts requires rebuild and republishing of the Chrome App
Cron Jobs part of the web app, various intervals, hardcoded in loaner/loaner/web_app/cron.yaml requires rebuild and push of new appengine version
Regards
Heartbeat durations are specific to the Chrome App, but are defined in the shared/config.ts file. You will have to rebuild and redeploy the Chrome App for this to take effect. This is defaulted to 10 minutes externally.
For crons, as far as I know you can adjust them in web_app/cron.yaml. There's some guidance on cron.yaml's in our official documentation here. This will require rebuilding and redeploying as well. Additionally, you'll need to update the serving app engine versions for each of the services (action-system, endpoints, chrome, etc...).
Hope this helps!
Hi Michael, thanks for confirming this. one last question, there is a cron job, run_custom_events, that runs 5 minutes. What is the purpose of this?
regards
Those are for if you have custom events for the action system. You can see this handler here
More on custom events: https://github.com/google/loaner/blob/master/docs/customizations.md#custom-events
Late to the party, was just reading through.
I did some testing with different Cron settings, but it didn't seem to change the overall cost very much at all. This did surprise me at the time (this is from memory as it was last year.)
So maybe the heartbeat was overriding the winding back of the Cron jobs. Maybe I should do some testing around that also.
cheers.
Can anyone give any idea of GCP running costs and how these may grow over time the more devices, shelves you add etc.
Thanks