Hello,

I'm using Akka with Java 8. Here is my directory structure and jsvc command 
that runs the application as a daemon

*Directory structure:*

myapp
 \---------myapp.jar
 \---------configuration
            \----------application.conf
            \----------application-dev.conf
\----------lib
            \----------mylib1.jar
            \----------mylib2.jar
\----------daemon-base.sh
\----------run.sh


*application-dev.conf:*

include "application"

akka {
..
..
..
}



*Application run command:*

jsvc.exec -cp 
/deploydir/myapp:/deploydir/myapp/myapp-1.0-SNAPSHOT.jar:/deploydir/myapp:/deploydir/myapp/lib/*.jar:/deploydir/myapp/configuration
 
*-Dconfig.file=/deploydir/myapp/configuration/application-dev.conf* 
-Dakka.log-config-on-start=on -pidfile .myapp.pid 
com.company.myapp.daemon.MyAppDaemon

*MyApp.java:*

        Config configuration = ConfigFactory.parseFile(new 
File("configuration/application.conf"))
                .withFallback(ConfigFactory.load());

*Log of config on startup:*

    # merge of configuration/application.conf: 4,system 
properties,/deploydir/myapp/configuration/application-dev.conf: 
3,/deploydir/myapp/configuration/application.conf: 4,system 
properties,reference.conf: 7-77



As you can see in the jsvc command, I am overriding application.conf by 
providing -Dconfig.file. However, when I log the configuration on startup I 
see it is actually overriding the other way. I am not sure what the numbers 
mean exactly, but at least the final result takes the values from 
application.conf instead of application-dev.conf. 

Can you please help me figure out what is wrong with my code?

Thanks a lot!

lakshmi

-- 
>>>>>>>>>>      Read the docs: http://akka.io/docs/
>>>>>>>>>>      Check the FAQ: 
>>>>>>>>>> http://doc.akka.io/docs/akka/current/additional/faq.html
>>>>>>>>>>      Search the archives: https://groups.google.com/group/akka-user
--- 
You received this message because you are subscribed to the Google Groups "Akka 
User List" 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/akka-user.
For more options, visit https://groups.google.com/d/optout.

Reply via email to