[ZBX-7152] API get method subselects not working correctly if a node is selected Created: 2013 Oct 15  Updated: 2017 May 30  Resolved: 2013 Oct 22

Status: Closed
Project: ZABBIX BUGS AND ISSUES
Component/s: API (A)
Affects Version/s: 2.1.8
Fix Version/s: 2.1.9, 2.2.0

Type: Incident report Priority: Major
Reporter: Pavels Jelisejevs (Inactive) Assignee: Ivo Kurzemnieks
Resolution: Fixed Votes: 0
Labels: dm
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified


 Description   

I have a DM configuration with two nodes: a local and a child node. The child node has a host with an application and an item in that app. I choose to display all nodes and perform the following request:

{
"jsonrpc": "2.0",
"method": "application.get",
"params":

{ "applicationids": "200100000000010", "selectItems": [ "itemid" ] }

,
"id": 3,
"auth": "729bd3e39886d2d773b31fffda4544ba"
}

Everything works ok. But when I select the local node, the selectItems parameter does not return any items. That happens because CZBXAPI::createRelationMap() method builds relations only using the records from the selected node. It should not take nodes into account.



 Comments   
Comment by Ivo Kurzemnieks [ 2013 Oct 16 ]

RESOLVED in svn://svn.zabbix.com/branches/dev/ZBX-7152

Comment by Pavels Jelisejevs (Inactive) [ 2013 Oct 21 ]

(1) Please review the changes that we discussed in r39444.

iivs REVIEWED.
Ok.
CLOSED.

Comment by Pavels Jelisejevs (Inactive) [ 2013 Oct 21 ]

(2) This bug also needs to be fixed in action.get selectOperations and any subrequest that uses a separate API call for mapping objects.

iivs RESOLVED in r39467

jelisejev This has to be fixed on the subselect level, not it CZBXAPI::select().

iivs RESOLVED in r39486

jelisejev CLOSED.

Comment by Pavels Jelisejevs (Inactive) [ 2013 Oct 23 ]

Great work!

TESTED.

Comment by Ivo Kurzemnieks [ 2013 Oct 23 ]

Fixed in pre-2.1.9 (trunk) r39516

Comment by Marc Schoechlin [ 2013 Nov 19 ]

Issue ZBX-7404 seems to be similar.

Generated at Fri Mar 29 15:57:42 EET 2024 using Jira 9.12.4#9120004-sha1:625303b708afdb767e17cb2838290c41888e9ff0.