Taking the latest changes from azure dev to azure master

I'm mostly interested in taking the Get Diagnostics bug fix into master, but I think I have to take them all.