ZEN-13008: ported from ZEN-13018