Thanks for the reply @Nate, @Alejandro, I can confirm that the STATUS command does NOT receive any configuration (custom, global or system) properties. That means neither of this would work inside the STATUS command:
- config['configuration']['my-config.xml']['my-property'], - config['configuration']['global']['...'] - configconfig['hostLevelParams'][`...`] (assuming: config = Script.get_config()) Seem that this is not a bug but an intentional behaviour. Any explanations what drives such design? Also if this is intentional at least the WIKI page should mention it. It might save a lot of efforts :) At the moment to use some custom/system properties within the STATUS command one has to store the desired properties in shared storage while in the START command. Yes, using PID files is a common practice but it doesn't cover my use case. Cheers, Christian On 22 July 2015 at 22:11, Nate Cole <nc...@hortonworks.com> wrote: > Typical status commands don’t send down full configurations like > start/stop do. Usually you’re just checking for a process to be up via > checking a PID file in a known location. > > Thanks, > Nate > > > On Jul 22, 2015, at 12:12 PM, Christian Tzolov <ctzo...@pivotal.io> > wrote: > > (i'd wrongly posted this question to the dev list instead of asking here > - sorry for the noise) > > Hi fellows, > > I'm working on a simple Service extension for Ambari 1.7. > > It looks like the Script.get_config() does not initialize the config files > (e.g. my-site.xml) defined in the metainfo.xml, when the get_config is > called inside the "status" method of the master script. > > An attempt to access the config['configuration']['my-site'] inside the > status method throws the following error: > >>> Configuration parameter \'my-site\' was not found in configurations > dictionary!' > > But the same configuration properties are accessible inside the > "initialize", "start" and "stop" methods. > > Is there something special for the 'status' method initialization or am i > overlooking some important detail? > > Would appreciate and ideas/advices. Also I can share the problem source > code if needed > > Thanks, > Christian > > -- > Christian Tzolov <http://www.linkedin.com/in/tzolov> | Solution > Architect, EMEA Practice Team | Pivotal <http://pivotal.io/> > ctzo...@pivotal.io|+31610285517 > > > -- Christian Tzolov <http://www.linkedin.com/in/tzolov> | Solution Architect, EMEA Practice Team | Pivotal <http://pivotal.io/> ctzo...@pivotal.io|+31610285517