Project

General

Profile

Actions

Bug #12572

closed

Custom node properties from inventory are not found in group search

Bug #12572: Custom node properties from inventory are not found in group search

Added by Félix DALLIDET over 7 years ago. Updated over 7 years ago.

Status:
Released
Priority:
N/A
Category:
Web - UI & UX
Target version:
Severity:
Critical - prevents main use of Rudder | no workaround | data loss | security
UX impact:
User visibility:
Operational - other Techniques | Technique editor | Rudder settings
Effort required:
Priority:
75
Name check:
Fix check:
Regression:

Description

In a node web-page, in the properties tab, or in the group creation page, queries can be done on node properties.
When the properties source is the inventory, they are loaded on the interface but do not appear in the query answer.
Query are functional after entering manually a "classic" node property (key/value from the same web page).


Files

no_query_output.png (78.8 KB) no_query_output.png Félix DALLIDET, 2018-05-02 14:00
no_query_output.png

Related issues 2 (0 open2 closed)

Related to Rudder - User story #4670: Allows inventories to be augmented by the user with custom propertiesReleasedFrançois ARMANDActions
Related to Rudder - Bug #9299: Extend groups search capabilities for complex JSON Properties / JsonPathReleasedVincent MEMBRÉActions

Updated by Benoît PECCATTE over 7 years ago Actions #1

  • Category set to Web - UI & UX
  • Target version set to 410
  • Severity set to Critical - prevents main use of Rudder | no workaround | data loss | security
  • User visibility set to Operational - other Techniques | Technique editor | Rudder settings
  • Priority changed from 0 to 76

Updated by Benoît PECCATTE over 7 years ago Actions #2

  • Target version changed from 410 to 4.3.2

Updated by François ARMAND over 7 years ago Actions #3

  • Description updated (diff)

Updated by François ARMAND over 7 years ago Actions #4

  • Status changed from New to In progress
  • Assignee set to François ARMAND

Updated by François ARMAND over 7 years ago Actions #5

So, what is happening is:

- when the value comes from inventory, we only have it in inventory LDAP branch ("ou=Accepted Node, ou=inventories, etc).
- the search for group does not look at that place, so it is "normal" to not find it with that search,
- the quicksearch does look at that place and find it,

BUT when we add a proprety, "inventory", it copy all properties to node, making it searchable.

Moreover, it seems that only the last inventory property is added.

Updated by François ARMAND over 7 years ago Actions #6

  • Related to User story #4670: Allows inventories to be augmented by the user with custom properties added

Updated by François ARMAND over 7 years ago Actions #8

So, the copy bug was hidding the fact that the search is just plain missing on custom node properties from inventory.

So, the idea is to rework a little the way our search works to cleanly split search on node info apport from the one on inventories properties. It was not working eleganlty for NodeState in all case.

Basically, it means that each Criterion in DIT will be either an LDAP criterion (everything until now is such an LDAP criterion) or it will be a "node info criterion" (basically, a NodeInfo => Value => Boolean).

Then, we just post process these element correctly. We are already relying on NodeInfoService for that, we just have to extends a little the "getLDAPNodeInfo" method.

Finally, it will open-up the real of REAL JSON query (because, on node info, node properties are parsed JSON).

WIP here: https://github.com/fanf/rudder/commit/766b309930b9519b016da49e5a137a9b7bdc8492

Everything works for NodeState, now we need to build a NodeCriterion for NodeProperties and use it.

Updated by François ARMAND over 7 years ago Actions #9

  • Status changed from In progress to Pending technical review
  • Assignee changed from François ARMAND to Vincent MEMBRÉ
  • Pull Request set to https://github.com/Normation/rudder/pull/1960
  • Priority changed from 76 to 75

Updated by François ARMAND over 7 years ago Actions #10

  • Subject changed from node properties from inventory are not well loaded when executing queries on the web Interface to Custom node properties from inventory are not found in group search

Updated by François ARMAND over 7 years ago Actions #11

  • Related to Bug #9299: Extend groups search capabilities for complex JSON Properties / JsonPath added

Updated by François ARMAND over 7 years ago Actions #12

  • Status changed from Pending technical review to Pending release

Updated by Vincent MEMBRÉ over 7 years ago Actions #13

  • Status changed from Pending release to Released

This bug has been fixed in Rudder 4.3.2 which was released today.

Actions

Also available in: PDF Atom