The dynamics of vibrational energy relaxation (VER) of the OH-stretching vibration of HOD in liquid-to-supercritical heavy water is studied as a function of temperature and solvent density by femtosecond mid-infrared spectroscopy. Using the dielectric constant of the fluid both, the OH-stretching absorption frequency and the VER rate, can be correlated phenomenologically with the average hydrogen-bond connectivity within the random D2O network. This correlation enables the identification of thermodynamic conditions under which spectral diffusion due to hydrogen-bond breakage/formation is much faster than VER.