Similar to what CommonsWare commented:
According to the Otto docs (http://square.github.io/otto/), the @Produce
annotation is intended to provide new subscribers with the current state of some event. To see the need for this functionality, consider the following sequence:
- ProducerA publishes some really important data
- Some time later, SubscriberA subscribes to the same really important data
Without using the @Produce
functionality, SubscriberA would not receive the really important data. However, if a producer of the "really important data" is defined then the same sequence becomes:
- ProducerA publishes some really important data
- Some time later, SubscriberA subscribes to the same really important data
- SubscriberA receives data from the producer of the really important data
Therefore producers can provide information to "late joiner" subscribers that would otherwise miss information that was published before the subscriber registered.