The project called giulius-settings here sounds like exactly what you're after https://github.com/timboudreau/giulius and is available for use in Maven as described here: http://timboudreau.com/builds/
You can optionally pass a reload interval to a SettingsBuilder when passing a file to load, and the infrastructure will periodically poll the file and if it's timestamp has changed, reload it. There is also an extension for using etcd (one of those distributed HA key/value things) via Settings. Whether dynamic reloading on the fly is actually a good idea is another question. If you have long-lived objects, you'll need to inject Providers to have the values actually change, since nothing will reach into an object and update its fields. Personally, I find it preferable to do this sort of thing in response to a Unix signal, so that I control when the reloading actually happens. -Tim On Wednesday, June 4, 2014 6:08:39 PM UTC-4, Milan Brahmbhatt wrote: > > Hi, is there a way to autoload properties file using Guice? By autoload, > I mean reload the properties initialized using guice inject whenever the > file changes? > > Milan > -- You received this message because you are subscribed to the Google Groups "google-guice" group. To unsubscribe from this group and stop receiving emails from it, send an email to [email protected]. To post to this group, send email to [email protected]. Visit this group at http://groups.google.com/group/google-guice. For more options, visit https://groups.google.com/d/optout.
