...
Note |
---|
Note the following rules when defining the key: - To define the key-value pair asmeta data, follow the syntax arbitraryData.put("meta.buyerbuyer","Joe");
- To define the key-value pair as correlation data, follow the syntax arbitraryData.put("correlation.buyer","Joe");
- To define the key-value pair as payload data, follow the syntax arbitraryData.put("buyer","Joe"); - No prefix.
Other than the above, you can't use dot(.) for key. |
5. Publish the map with the event.
Code Block |
---|
language | java |
---|
linenumbers | true |
---|
|
Event eventOne = new Event(streamId, System.currentTimeMillis(), new Object[]{"external"}, null,
new Object[]{"IBM", 45, 2500},arbitraryData);
dataPublisher.publish(eventOne); |