8. Given complex numbers $z_{1}, z_{2}, z_{3}$ satisfy $\left|z_{1}\right|=\left|z_{2}\right|=\left|z_{3}\right|=1,\left|z_{1}+z_{2}+z_{3}\right|=r$, where $r$ is a given real number, then the real part of $\frac{z_{1}}{z_{2}}+\frac{z_{2}}{z_{3}}+\frac{z_{3}}{z_{1}}$ is (expressed in terms of $r$).
$$
\begin{array}{l}
\text { Let } z_{1}=\cos \alpha+\mathrm{i} \sin \alpha, z_{2}=\cos \beta+\mathrm{i} \sin \beta, z_{3}=\cos \gamma+\mathrm{i} \sin \gamma, \\
\text { then } z_{1}+z_{2}+z_{3}=(\cos \alpha+\cos \beta+\cos \gamma)+\mathrm{i}(\sin \alpha+\sin \beta+\sin \gamma) \\
\Rightarrow(\cos \alpha+\cos \beta+\cos \gamma)^{2}+(\sin \alpha+\sin \beta+\sin \gamma)^{2}=r^{2} \\
\Rightarrow \cos (\alpha-\beta)+\cos (\beta-\gamma)+\cos (\gamma-\alpha)=\frac{r^{2}-3}{2} \text {. }
\end{array}
$$

So $\boldsymbol{\operatorname { R e }}\left(\frac{z_{1}}{z_{2}}+\frac{z_{2}}{z_{3}}+\frac{z_{3}}{z_{1}}\right)=\cos (\alpha-\beta)+\cos (\beta-\gamma)+\cos (\gamma-\alpha)=\frac{r^{2}-3}{2}$.