scaldi-play-example
scaldi-play-example copied to clipboard
Play configuration Injectornot working for me
Hey, maybe I'm missing something essentially, but I can't get scaldi to work with application.conf in play. the only thing which happens is
Caused by: scaldi.InjectException: No binding found with following identifiers:
* TypeTagIdentifier(String)
* StringIdentifier(riak.uri)
my application.conf:
riak.uri="localhost"
riak.uri=${?RIAK_URI}
riak.port=18098
riak.port=${?RIAK_PORT}
play.application.loader = scaldi.play.ScaldiApplicationLoader
play.modules.enabled += "modules.ApplicationModule"
and in side my ApplicationModule I try to bind them to my beautiful riakclient:
bind[RiakClient] to RiakClient(
system,
inject[String](identified by "riak.uri"),
inject[Int](identified by "riak.port")
)
Which compiles beautifully, but when running it, it throws the exception above. Since it (almost) looks like the example and I tried to follow the docs as close as possible, I'm really not sure, what happens there or why it doesn't look into the conf for retrieving the values.
play-version is 2.5.3 scaldi-play is 0.5.15
Greetings