Cavity resonance wavemeter