Use Path::extension to simplify mesos code.
Use Path::extension to simplify mesos code.

Review: https://reviews.apache.org/r/41753

kaysoky/mesos,andschwa/mesos,craimbert/mesos,neilconway/mesos,zmalik/mesos,dforsyth/mesos,verizonlabs/mesos,abudnik/mesos,andschwa/mesos,andschwa/mesos,jpeach/mesos,zmalik/mesos,chhsia0/mesos,zmalik/mesos,yuquanshan/customizedMesos,asamerh4/mesos,chhsia0/mesos,abudnik/mesos,gsantovena/mesos,dforsyth/mesos,asamerh4/mesos,gsantovena/mesos,Aman-Jain-14/customizedMesos,Gilbert88/mesos,neilconway/mesos,dforsyth/mesos,Gilbert88/mesos,andschwa/mesos,Aman-Jain-14/customizedMesos,dforsyth/mesos,Aman-Jain-14/customizedMesos,zmalik/mesos,abudnik/mesos,yuquanshan/customizedMesos,reneploetz/mesos,kaysoky/mesos,Aman-Jain-14/customizedMesos,yuquanshan/customizedMesos,abudnik/mesos,verizonlabs/mesos,andschwa/mesos,dforsyth/mesos,yuquanshan/customizedMesos,gsantovena/mesos,craimbert/mesos,kaysoky/mesos,Gilbert88/mesos,craimbert/mesos,asamerh4/mesos,abudnik/mesos,Aman-Jain-14/customizedMesos,yuquanshan/customizedMesos,kaysoky/mesos,Gilbert88/mesos,andschwa/mesos,craimbert/mesos,asamerh4/mesos,kaysoky/mesos,asamerh4/mesos,asamerh4/mesos,reneploetz/mesos,asamerh4/mesos,Aman-Jain-14/customizedMesos,gsantovena/mesos,chhsia0/mesos,reneploetz/mesos,craimbert/mesos,gsantovena/mesos,neilconway/mesos,jpeach/mesos,chhsia0/mesos,chhsia0/mesos,jpeach/mesos,verizonlabs/mesos,jpeach/mesos,reneploetz/mesos,reneploetz/mesos,gsantovena/mesos,craimbert/mesos,Gilbert88/mesos,dforsyth/mesos,yuquanshan/customizedMesos,yuquanshan/customizedMesos,reneploetz/mesos,verizonlabs/mesos,abudnik/mesos,chhsia0/mesos,neilconway/mesos,abudnik/mesos,zmalik/mesos,neilconway/mesos,neilconway/mesos,verizonlabs/mesos,andschwa/mesos,Gilbert88/mesos,verizonlabs/mesos,zmalik/mesos,kaysoky/mesos,kaysoky/mesos,neilconway/mesos,gsantovena/mesos,chhsia0/mesos,jpeach/mesos,dforsyth/mesos,Aman-Jain-14/customizedMesos,craimbert/mesos,verizonlabs/mesos,reneploetz/mesos,Gilbert88/mesos,jpeach/mesos,jpeach/mesos,zmalik/mesos