Bug #12572
closedCustom node properties from inventory are not found in group search
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
Updated by Benoît PECCATTE over 6 years ago
- 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 6 years ago
- Target version changed from 410 to 4.3.2
Updated by François ARMAND over 6 years ago
- Status changed from New to In progress
- Assignee set to François ARMAND
Updated by François ARMAND over 6 years ago
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 6 years ago
- Related to User story #4670: Allows inventories to be augmented by the user with custom properties added
Updated by François ARMAND over 6 years ago
Work in progess here: https://github.com/fanf/rudder/commit/766b309930b9519b016da49e5a137a9b7bdc8492
Updated by François ARMAND over 6 years ago
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 6 years ago
- 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 6 years ago
- 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 6 years ago
- Related to Bug #9299: Extend groups search capabilities for complex JSON Properties / JsonPath added
Updated by François ARMAND over 6 years ago
- Status changed from Pending technical review to Pending release
Applied in changeset rudder|0fe6ce6fb6192c0e870d68f23bbe4c418aa8b2e8.
Updated by Vincent MEMBRÉ over 6 years ago
- Status changed from Pending release to Released
This bug has been fixed in Rudder 4.3.2 which was released today.
- 4.3.2: Announce Changelog
- Download: https://www.rudder-project.org/site/get-rudder/downloads/