improve messages during publication and catch most serious migration server errors. Fix for #1011
Merge pull request #1014 from belforte/master

improve messages and fix #1011