start you redis server frist redis-server test use redis api go run main.go test publish/subscribe go run pubsub.go