Closed batpad closed 7 years ago
@batpad This seems like a good idea, if you make a pr I think we would be happy to merge it in. Thank you very much!
added via #897
Also @batpad if you still run into issues even with a longer time, you could try this solution to ensure it's only running on one instance: https://github.com/hotosm/osm-tasking-manager2/issues/659#issuecomment-213628164
Currently, there is the scheduler job that checks for expired tasks every 5 seconds here: https://github.com/hotosm/osm-tasking-manager2/blob/master/osmtm/__init__.py#L160
Would there be any objections to making this configurable? Am happy to PR.
I've found myself wanting to increase this time, especially in an auto-scaling type configuration when there are multiple instances of the app running, and each instance hitting the db every 5 seconds causes a bit of load.
If this is not a common use-case and people don't see the value in making this configurable, please feel free to close :-), but if it seems okay to do, I can go ahead and PR. Thank you!