- Spring 5.0 Microservices(Second Edition)
- Rajesh R V
- 55字
- 2025-04-04 18:53:35
Publisher
A Publisher holds the source of data, and then publishes data elements as per the request from a subscriber. A Subscriber can then attach a subscription on the Publisher. Note that the subscribe method is just a registration method, and will not return any result:
public interface Publisher<T> {
public void subscribe(Subscriber<? super T> s);
}