Erlang/OTP Forums

Author Message

<  Open Telecom Platform (OTP)  ~  Permanent resource file changes (on the fly)

peter631
Posted: Thu May 21, 2009 8:36 am Reply with quote
Joined: 21 May 2009 Posts: 3
Hello all,

1) Is it possible to change content of application resource file - (.app
file) on the fly?
I changed some environment parameters using application:set_env, and it has
changed,
but content in .app file still the same. Is it normal?

2) Additionally, I noticed, that whole resource file was built in the .boot
file, and target system uses environment parameters this boot, not .app
file.
Should I use sys.config instead?


Thx in adv,
Peter

P.S.
Sorry if it is FAQ
View user's profile Send private message Send e-mail ICQ Number
spawn.think
Posted: Wed Dec 09, 2009 10:03 am Reply with quote
User Joined: 29 Sep 2009 Posts: 21
Hi Peter,
Well it's possible to change .app and see the effect in the shell , but you can't call it "on the fly". The reason for that is you have to stop the application, unload it , then start it again.
On the other hand, changing the environment variable from the shell has no effect on the .app file.

In case you are using a target system, you would better use sys.config to override env. values in .app [which are built into the .boot file]
(note: changes to sys.config can't be done on the fly, you will need to set it it manually from the shell or restart the target system to have effect).

hope i made it a bit clear.

Best Regards
AD
View user's profile Send private message

Display posts from previous:  

All times are GMT
Page 1 of 1
This forum is locked: you cannot post, reply to, or edit topics.

Jump to:  

You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum
You can attach files in this forum
You can download files in this forum