RHQ, the common services project for infrastructure management

  Dashboard > RHQ-Project > ... > Design-Agent > Design-Adding Agent Configuration Preference
  RHQ-Project Log In | Sign Up   View a printable version of the current page.  
  Design-Adding Agent Configuration Preference
Added by John Mazzitelli , last edited by John Mazzitelli on Apr 14, 2008  (view change)
Labels: 
(None)

Adding a New Configuration Preference to the Agent

If you want to add a new configuration preference to the agent, do the following:

  • Put it in agent-configuration.xml - fully document it in the comments like the rest
  • Put it in embedded-agent-configuration.xml - fully document it in the comments like the rest
  • Add a getter to AgentConfiguration
    • Add a constant to AgentConfigurationConstants
    • If this is a plugin container configuration, you probably just need to modify AgentConfiguration.getPluginContainerConfiguration() rather than creating a standalone AgentConfiguration.getXXX() method
    • If this is a comm sender config, edit AgentConfiguration.getClientCommandSenderConfiguration appropriately
  • Add the ability to set it by adding code to SetupPromptCommand
  • Add it to on-plugin.xml in the agent plugin's <resource-configuration>
  • You might have to add it to test-agent*-configuration.xml test files (in the agent module and agent plugin module) unless the hardcoded default is safe for the tests to use
  • Add it to the agentspawn.properties agentspawn module

Server Configuration

If you added the configuration to the comm stuff (client sender config or service container config):

  • You modify ClientCommandSenderConfiguration or ServerConfiguration[Constants]
  • Modify rhq-container.build.xml so it generates the new setting in rhq-server.properties
  • Edit server-comm-configuration.xml and server-comm-service.xml as appropriate
Powered by a free Atlassian Confluence Open Source Project License granted to Hyperic HQ. Evaluate Confluence today.
Powered by Atlassian Confluence 2.7.1, the Enterprise Wiki. Bug/feature request - Atlassian news - Contact administrators