ScottG489 / conjob

Simple web interface to run containers as jobs or serverless functions
MIT License
12 stars 0 forks source link

Allow config values to be updated dynamically through the admin interface #24

Closed ScottG489 closed 3 years ago

ScottG489 commented 3 years ago

Add an endpoint on the admin port to be able to update config values dynamically.

The main reason for this is testing, but it's also a useful feature to have in general.

For some of the tests, it's necessary to have values like request limiting or job timeouts changed or reduced for the sake of testing. For instance, the job timeout is 30 minutes. It isn't possible to test this, otherwise the test would take too long. However, if the tests are able to update the timeout limit to be shorter then they can test effectively.

This will require some research into how the dropwizard config can be dynamically updated.

ScottG489 commented 3 years ago

See here for a promising solution:

https://stackoverflow.com/a/31739228/14146969

ScottG489 commented 3 years ago

I ended up not going with the solution in the previous comment. It was easy enough to write my own. I actually created a blog post on how to solve this and created an example project for demonstration. \ \ Closed by ccd3d948623081b97b369da717c5adea8d290732.