The role of growth conditions on the p-doping of GaN by plasma-assisted molecular beam epitaxy