Open guettli opened 1 year ago
Hi @guettli, really appreciate your feedback on this 🙏 Here's my initial idea for these two operations:
Default command (e.g. kubectl lineage <RESOURCE>
)
<RESOURCE>
in its metadata.ownerReferences
field, consistent with the terminology used in Kubernetes official documentation
Deployment
— ReplicaSet
— Pod
<RESOURCE>
Pod
— Service
— Ingress
Pod
— Service
— APIService
PersistentVolume
— PersistentVolumeClaim
— Pod
ConfigMap
— Pod
ClusterRole
— ClusterRoleBinding
— ServiceAccount
— Pod
Inverse of the default command (e.g. kubectl lineage --<BOOLEAN_FLAG_FOR_INVERSE_OPERATION> <RESOURCE>
)
<RESOURCE>
metadata.ownerReferences
field, consistent with the terminology used in Kubernetes official documentation
Pod
— ReplicaSet
— Deployment
<RESOURCE>
Ingress
— Service
— Pod
APIService
— Service
— Pod
Pod
— PersistentVolumeClaim
— PersistentVolume
Pod
— ConfigMap
Pod
— ServiceAccount
— ClusterRoleBinding
— ClusterRole
For
1.ii. Recursively list all dependents — "dependents" here means k8s resources referencing/using the specified
<RESOURCE>
I think it still makes sense to call them dependents (eg. Service
references/depends on the Pod
to work, Ingress
references/depends on Service
to work)
As for
2.ii. Recursively list all dependencies — "dependencies" are k8s resources referenced/used by the specified
<RESOURCE>
I guess the word "dependencies" is a little ambiguous/awkward, perhaps a better way is to just describe this as "printing the dependents in reverse order" & I should use the --reverse
/-r
flags instead 🤔
What's your thoughts on this?
I like the list owners, since this is easy to understand. But -r
for "reverse" is good, too.
Since the plugin is named lineage, would using "children" and "parents" be appropriate?
Thank your very much for this great tool.
Could you please explain in the README (and/or in
-h
) the difference between dependencies and dependents?Are you sure "dependencies" is the correct term?
With option
-D
For me
-D
looks like reverse-dependencies to me.