You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Dependency bus factor: For each dependency (direct or transitive), we can get rid of this dependency by removing how many direct dependencies? i.e., how many direct dependencies introduce this dependency?
Dependency bus-harmonic: For a dependency, if its bus factor is n, then its bus harmonic would be the nth harmonic. The idea behind bus-harmonic is when a new dependency is added into the dep graph (direct or transitive) , i.e., bus factor going from 0 to 1 - the significance of this case is much larger than the case when the bus factor goes from 4 to 5. This metric in form of harmonics will reflect that.
Total bus-harmonic: Summation of the bus-harmonics for each dependency. This metric satisfies below criteria:
i. Whenever a new dependency is added, total bus-harmonic would increase.
ii. Whenever a dependency is removed, total bus-harmonic would decrease
iii. The increase/decrease will reflect if dependency is freshly added/removed (in which case the delta will be large) compared to if a dependencie’s bus factor is simply going from 4 to 5 (in which case the delta will be small).
Motivation behind metrics
When a new dependency is added, we can report how much the total bus-harmonic is increasing. If the increase in the bus-harmonic is over a certain threshold, we can rethink if the dependency addition is justifiable compared to the functionalities it is providing.
Similarly we can use these metrics in efforts where we look for opportunities to reduce the total number of dependencies - although this case may be less useful in practice.
Dependency Metrics
i. Whenever a new dependency is added, total bus-harmonic would increase.
ii. Whenever a dependency is removed, total bus-harmonic would decrease
iii. The increase/decrease will reflect if dependency is freshly added/removed (in which case the delta will be large) compared to if a dependencie’s bus factor is simply going from 4 to 5 (in which case the delta will be small).
Motivation behind metrics
cc @bmwill
The text was updated successfully, but these errors were encountered: