Fix ES thread mapping.