whimxiqal/nope

Improve Zone Inheritance

Closed this issue · 2 comments

There really is no reason why a zone can only have one parent. When evaluating values for a point, every encapsulating zone will look up all its parents and add them to the priority queue by order of priority.

This will allow for more advanced inheritance.

Actually, I'm not sure that simply allowing multiple Zone parents will make everything better. Currently, a parent will just be another Zone inside which a location is considered encompassed as long as the child encompasses it. The settings are evaluated in reverse-priority order, like other Host inheritance. Ensuring that the order is applied appropriately and priorities are not conflicting can become very confusing, in the case that two parents use the same setting and have the same priority.

Another solution is to make another type of SettingCollection. Earlier, there was a concept of a Template, which was basically Zone without the Volumes. This could be a similar concept, perhaps called Template again or Provider. This new object would be a SettingCollection, but would not have an inherent priority. Rather, it would be put somewhere in an ordered list and applied in order when the Zone is being evaluated. So, it would almost have a "micro" priority because the overall Host priority has the "macro" priority tier.

This will now be tracked here #17