... | ... | @@ -24,9 +24,11 @@ Further details on each smell are provided in the subsections below. |
|
|
This smell represents a component (by *components* we refer to both classes and packages, but in the case of UD, we only mean packages/folders.} that depends upon a significant number of components that are less stable than itself.
|
|
|
The stability of a component is measured using Martin's [instability metric](https://en.wikipedia.org/wiki/Software_package_metrics), which measures the degree to which a component (e.g. a package) is susceptible to change based on the classes it depends upon and on the classes depending on it.
|
|
|
The smell thus arises when a component has a significant number of components -- the tool Arcan uses a 30% threshold -- it depends upon with an instability value higher than its own.
|
|
|
A UD smell is detectable on Java package-like (or folders for C/C++ systems) elements only. A simplified example of UD is shown in Figure \ref{fig:unstable-dep}.
|
|
|
A UD smell is detectable on Java package-like (or folders for C/C++ systems) elements only. A simplified example of UD is shown in the figure below.
|
|
|
|
|
|
The main problem caused by UD is that the probability to change the main component grows higher as the number of unstable components it depends upon grows accordingly. This increases the likelihood that the components that depend upon it (not shown in Figure \ref{fig:unstable-dep} for simplicity) change as well when it is changed (ripple effect), thus inflating future maintenance efforts.
|
|
|
![architectural-smells-unstable-dep](uploads/237dc0c2199f6107a47795c8dfc890bb/architectural-smells-unstable-dep.png)
|
|
|
|
|
|
The main problem caused by UD is that the probability to change the main component grows higher as the number of unstable components it depends upon grows accordingly. This increases the likelihood that the components that depend upon it (not shown in the figure for simplicity) change as well when it is changed (ripple effect), thus inflating future maintenance efforts.
|
|
|
|
|
|
\subsubsection{Hublike dependency (HL)}\label{sec:arch-smells-hl}
|
|
|
This smell represents a component where the number of ingoing and outgoing dependencies is higher than the median in the system and the absolute difference between these ingoing and outgoing dependencies is less than a quarter of the total number of dependencies of the component \cite{Fontana2016}. A hublike dependency can be detected both at the package and at the class level.
|
... | ... | |