Spectral reciprocity and non-vanishing of L-functions