I assume you're running two programs. One for the publisher and the other for the subscriber.
In this case you need to start the subscriber first and then the publisher.
The reason is that the publisher is a "fire-and-forget". It doesn't wait for subscribers to connect. This is described in the guide in the Getting the Message Out section as the "slow joiner" symptom.