SERVER-14731 print more debug info when plan_cache_ties.js fails

(cherry picked from commit 791e2e00806449a01e7dec4d9b969392e183f393)
Merge remote-tracking branch 'upstream/v2.6' into v2.6