On the quantization of gravity