Skip to end of metadata
Go to start of metadata

You are viewing an old version of this page. View the current version.

Compare with Current View Page History

« Previous Version 11 Next »

Understand and learn how to setup new agent environment on this page.

On this page


Extend Base Agent


  • Extend Base Agent.py file present in the agent directory.

Define config.json file


  • All complex JSON Objects should be kept under property name "dynamicTemplate". For example, Arrays, Properties having sub-properties as a JSON Object.
  • "responseTemplate" shall always be part of the dynamicTemplate, to capture the response from the external tool.
  • Th below dynamicTemplate example is for GitHub.

    Dynamic Template Format

    "dynamicTemplate": {
         "responseTemplate": {
              "sha": "commitId",
               "commit": {
                   "author": {
                         "name": "authorName",
                         "date": "commitTime"
                           }
                   }
               }
     }

Update installagent.sh file


  • Update "installagent.sh" file if the OS is other than Linux or Ubuntu.

Steps to upgrade existing Agents


1. Stop all existing running agents

2. Take backup of existing agent code

3. Note down last run date/time from tracking.json

4. Let Insights Engine consume all queues data. Verify all the queues have 0 pending data

5. Shut down Insights Engine.

6. Undeploy PlatformService WAR

7. Take back up of AGENT_CONFIGURATION table in PostgreSQL

8. DELETE all records from AGENT_CONFIGURATION table in PostgreSQL after taking backup

9. Deploy new PlatformService WAR and verify it has created below new columns in AGENT_CONFIGURATION table - 

  • agent_key
  • agent_status
  • agent_version
  • os_version

10. Run SQL DDL script –

ALTER TABLE public.agent_configuration ADD CONSTRAINT agentKeyUnique UNIQUE(unique_key);

11. Run below SQL query to register Daemon Agent -

INSERT INTO public.agent_configuration(

            id, agent_id, agent_json, agent_key, agent_status, agent_version,

            data_update_supported, os_version, tool_category, tool_name,

            unique_key, update_date)

VALUES (1, 0,'','daemon-1523257126' ,'' ,'' , FALSE,'' , 'DAEMONAGENT', 'AGENTDAEMON', 'daemon-1523257126', current_date);

12. Follow Agent 2.0 installation steps

13. Register all required agents using Agent management screen in Admin tab.

  • While registering, startTime should be from the time it was last update in tracking.json as mentioned above in step #3

14. Run latest new updated Insights Engine Jar

15. Validate all agents are running successfully and collecting data as usual

  • No labels