Uploaded image for project: 'ZABBIX BUGS AND ISSUES'
  1. ZABBIX BUGS AND ISSUES
  2. ZBX-25302

API::Sla()->get returns also SLAs for another service.

XMLWordPrintable

    • Icon: Problem report Problem report
    • Resolution: Cannot Reproduce
    • Icon: Trivial Trivial
    • None
    • None
    • None
    • None
    • Zabbix 7.0

      API::Sla()->get returns also SLAs for another service.

       

      Steps to reproduce:

      1. Setup services, details are below
      2. Setup slas, details are below
      3. Call API::Sla()->get
      4. Check results

      Setup of Services:

      • ServiceI [level 0](service id 101)   -> ChildServiceI [level 1] (service id 332)(tags: sla-service:service-trapper) -> SubChildServiceI [level 2] (tags: sla-item:availability1, host:host1)
      • ServiceII [level 0](service id 102)  -> ChildServiceII  [level 1] (service id 334)(tags: sla-service:service-trapper) -> SubChildServiceII [level 2] (tags: sla-item:-availability2, host:host1)

      Setup of SLAs:

      • SLA for ServiceI (Service tags: sla-service:service-trapper)
      • SLA for ServiceII (Service tags: sla-service:service-trapper)

       

       

      Result:

      • api first call sla.get for [serviceids] => 332
      Array
      (
          [output] => Array
              (
                  [0] => slaid
                  [1] => name
                  [2] => period
                  [3] => slo
                  [4] => timezone
              )    [serviceids] => 332
          [sortfield] => name
      )
          Result:
      Array
      (
          [0] => Array
              (
                  [slaid] => 32
                  [name] => SLA for ServiceI
                  [period] => 0
                  [slo] => 90
                  [timezone] => Europe/Warsaw
              )    [1] => Array
              (
                  [slaid] => 33
                  [name] => SLA for ServiceII
                  [period] => 0
                  [slo] => 90
                  [timezone] => Europe/Warsaw
              ))
      • api second call sla.get for [serviceids] => 334
      Array
      (
          [output] => Array
              (
                  [0] => slaid
                  [1] => name
                  [2] => period
                  [3] => slo
                  [4] => timezone
              )    [serviceids] => 334
          [sortfield] => name
      )
          Result:
      Array
      (
          [0] => Array
              (
                  [slaid] => 32
                  [name] => SLA for ServiceI
                  [period] => 0
                  [slo] => 90
                  [timezone] => Europe/Warsaw
              )    [1] => Array
              (
                  [slaid] => 33
                  [name] => SLA for ServiceII
                  [period] => 0
                  [slo] => 90
                  [timezone] => Europe/Warsaw
              ))
      

        1. Main_Services.png
          19 kB
          Wojciech Adamski
        2. ServiceI.png
          19 kB
          Wojciech Adamski
        3. ChildService_I.png
          86 kB
          Wojciech Adamski
        4. ServiceII.png
          24 kB
          Wojciech Adamski
        5. ChildService_II.png
          25 kB
          Wojciech Adamski
        6. SLA_for_ServiceII.png
          77 kB
          Wojciech Adamski
        7. get_SLA_for_ChildService_I.png
          39 kB
          Wojciech Adamski
        8. SLA_for_ServiceI.png
          79 kB
          Wojciech Adamski
        9. service64_config.png
          51 kB
          Wojciech Adamski
        10. service64_config_tags.png
          26 kB
          Wojciech Adamski
        11. service64_config_childs.png
          32 kB
          Wojciech Adamski

            Unassigned Unassigned
            wojtekadams Wojciech Adamski
            Votes:
            0 Vote for this issue
            Watchers:
            3 Start watching this issue

              Created:
              Updated:
              Resolved: