public interface ReaderGroupManager
extends java.lang.AutoCloseable
Modifier and Type | Method and Description |
---|---|
void |
close()
Close this manager class.
|
ReaderGroup |
createReaderGroup(java.lang.String groupName,
ReaderGroupConfig config,
java.util.Set<java.lang.String> streamNames)
Creates a new ReaderGroup
Readers will be able to join the group by calling
ClientFactory.createReader(String, String, Serializer, ReaderConfig)
. |
void |
deleteReaderGroup(java.lang.String groupName)
Deletes a reader group, removing any state associated with it.
|
ReaderGroup |
getReaderGroup(java.lang.String groupName)
Returns the requested reader group.
|
static ReaderGroupManager |
withScope(java.lang.String scope,
java.net.URI controllerUri)
Creates a new instance of ReaderGroupManager.
|
static ReaderGroupManager withScope(java.lang.String scope, java.net.URI controllerUri)
scope
- The Scope string.controllerUri
- The Controller URI.ReaderGroup createReaderGroup(java.lang.String groupName, ReaderGroupConfig config, java.util.Set<java.lang.String> streamNames)
ClientFactory.createReader(String, String, Serializer, ReaderConfig)
. Once this is done they will start receiving events from the point defined in the config
passed here.
Note: This method is idempotent assuming called with the same name and config. This method may block.
groupName
- The name of the group to be created.config
- The configuration for the new ReaderGroup.streamNames
- The name of the streams the reader will read from.void deleteReaderGroup(java.lang.String groupName)
groupName
- The group to be deleted.ReaderGroup getReaderGroup(java.lang.String groupName)
groupName
- The name of the groupvoid close()
close
in interface java.lang.AutoCloseable
AutoCloseable.close()