Uploaded image for project: 'ZABBIX FEATURE REQUESTS'
  1. ZABBIX FEATURE REQUESTS
  2. ZBXNEXT-5570

Change Agent2 plugin configuration

XMLWordPrintable

    • Team INT
    • Sprint 57 (Oct 2019), Sprint 58 (Nov 2019), Sprint 59 (Dec 2019), Sprint 60 (Jan 2020), Sprint 61 (Feb 2020), Sprint 62 (Mar 2020), Sprint 63 (Apr 2020), Sprint 64 (May 2020), Sprint 65 (Jun 2020), Sprint 66 (Jul 2020), Sprint 67 (Aug 2020)
    • 2

      Currently plugin Configure interface accepts string map of key=value pairs taken directly from the Plugins.<name> configuration parameter.

      There are several drawbacks with this approach:

      • complex configuration can be supported only by encoding it into key names
      • to access common parameters (timeout) plugin must directly access global agent configuration
      • no built in (through tags) validation, default values

       

      The idea is to change Configure parameter to interface{} which plugin would unmarshal into own configuration structure using Unmarshal method from conf package.

      The parameter would contain a tree structure of configuration nodes (something like this is already used by configuration parser internally), but it would be better to hide the internal implementation by passing interface{}. All common parameters would be added to this tree structure under Common node.

      Plugins would need to define their own options structure and embed the common options structure:

      type Options struct {
         conf.Common
         // plugin options
      }

       

            vadimipatov Vadim Ipatov
            wiper Andris Zeila
            Team INT
            Votes:
            0 Vote for this issue
            Watchers:
            8 Start watching this issue

              Created:
              Updated:
              Resolved: