merge in small changes from pacto-server branch