Topics
In Diffusion®, a topic is a channel through which data is distributed to clients.
Topics provide a logical link between publishing clients and subscribing clients.
Data types
Diffusion® topics are based on 'data types'. Data sent through topics must match the data type of the topic. You can publish data to these topics, and the data is streamed to subscribing clients.
The possible data types are:
-
JSON
-
Binary
-
String
-
Int64
-
Double
-
RecordV2
Time series topics
Time Series topics provide additional capabilities such as, storing a sequence of events. They are useful for collaborative applications such as chat rooms. Multiple users can concurrently update a time series topic.
Topic selectors
A client can reference a topic by its topic path.
Alternatively, you can also use topic selectors to access all the topics that match a regex or topic tree expression.
For example, you might want your client to subscribe to every topic under the /foo/bar
path.
Since you cannot know ahead of time which topics will exist there; instead of specifying every topic path, you can use a topic selector.
Topic selector | foo |
bar |
foo/bar |
foo/baz |
foo/bar/baz/bing |
---|---|---|---|---|---|
|
|||||
|
|||||
|
|||||
|
|||||
|
|||||
|