This patch modifies current attributes matching from a single
name-value->node hit to a best-match score.
Also using an UUID as the attributes table primary key to allow exposing
attributes in API later (bug 1525231).
Change-Id: I205e31652b21b9e030b9530149e533b29c52a387
Closes-Bug: 1651719
Partial-Bug: 1525231