PROTON-1486: merge changes by Keith and Rob. This closes #9