The mass resignation of psychiatrists in NSW reveals a public health system on the verge of collapse amid years of chronic underfunding even as demand has surged.