All of our servers have an attribute indicating their datacenter:
default[“facility”] = “DC1”
We do that so we can restrict searches to a single DC:
knife search node “facility:DC1”
That’s worked very well for several years. Recently, we added a new cookbook that created this attribute on its nodes:
default[“flume_relay”][“kafka_sink”][“facility”] = “DC1”
Now servers with that cookbook who have the root “facility” attribute set to “DC2”,“DC3”, etc are now being returned incorrectly in facility:DC1 searches because of having the attribute [“flume_relay”][“kafka_sink”][“facility”] = “DC1”.
Historically we’ve expected nested attributes not to greedy match like that (you have to do something like flume_relay_kafka_sink_facility to search for a nested attribute).
Any advice is greatly appreciated, because this could cause a lot of issues for us.