vipx / google-guice

Automatically exported from code.google.com/p/google-guice
Apache License 2.0
0 stars 0 forks source link

guice-persist - bound Properties improovement #695

Open GoogleCodeExporter opened 9 years ago

GoogleCodeExporter commented 9 years ago

Add support for named properties in JpaPesistModule, as 
JpaPersistModule#properties() method requires Properties class instance. In 
most cases, Properties instance is already bound to some kind of annotation or 
name, however, it cannot be accessed until injector is fully created.

for example new JpaPersistModule("jpa").properties(Names.named("configuration"))

(... or allow the developers to bound properties by themselves by un-protecting 
Jpa annotation, as it was in warp-persist).

Original issue reported on code.google.com by raimondas.valickas on 27 Mar 2012 at 3:22

GoogleCodeExporter commented 9 years ago

Original comment by cgruber@google.com on 27 Mar 2012 at 6:08

GoogleCodeExporter commented 9 years ago

Original comment by cgruber@google.com on 27 Mar 2012 at 6:25

GoogleCodeExporter commented 9 years ago
Candidate patch that allows binding to a properties provider implementation. 
You could use a linked binding if you wanted this to be a specific provider 
instance instead of the injector constructing the provider on demand. You can 
then decide how to retrieve the properties in your custom provider.

Original comment by mccu...@gmail.com on 29 Jul 2012 at 8:25

Attachments: