@ThreadSafe public class Publisher extends Object
Constructor and Description |
---|
Publisher(Client client,
String nsqd,
String failoverNsqd) |
Publisher(String nsqd) |
Publisher(String nsqd,
String failoverNsqd) |
Modifier and Type | Method and Description |
---|---|
void |
connectionClosed(com.sproutsocial.nsq.PubConnection closedCon) |
Client |
getClient() |
Config |
getConfig() |
int |
getFailoverDurationSecs() |
void |
publish(String topic,
byte[] data) |
void |
publish(String topic,
List<byte[]> dataList) |
void |
publishBuffered(String topic,
byte[] data) |
void |
publishDeferred(String topic,
byte[] data,
long delay,
TimeUnit unit) |
void |
setBatchConfig(String topic,
int maxSizeBytes,
int maxDelayMillis) |
void |
setConfig(Config config) |
void |
setFailoverDurationSecs(int failoverDurationSecs) |
void |
stop() |
public Publisher(String nsqd)
public void connectionClosed(com.sproutsocial.nsq.PubConnection closedCon)
public void publish(String topic, byte[] data)
public void publishBuffered(String topic, byte[] data)
public void setBatchConfig(String topic, int maxSizeBytes, int maxDelayMillis)
public void stop()
public int getFailoverDurationSecs()
public void setFailoverDurationSecs(int failoverDurationSecs)
public final Client getClient()
public Config getConfig()
public void setConfig(Config config)
Copyright © 2018. All rights reserved.