etcdserver: add publish func

for #1094 
// shutdown the server after ...
time.AfterFunc(srv.Stop(), someDuration)
srv.publish()...