Failure Diagnosis for Datacenter Applications