AddServer returns an Option which makes client connection and set server url.
Connect takes a connected net.Conn and performs the initial handshake.
No description provided by the author
No description provided by the author
TimeNow returns current wall time in UTC rounded to milliseconds.
WithBatchByteThreshold sets byte threshold for publish batch.
WithBatchCountThreshold sets message count threshold for publish batch.
WithBatchDuration sets batch duration to group publish requestes into single group.
WithCleanSession returns an Option which makes client connection and set CleanSession.
WithClientID returns an Option which makes client connection and set ClientID.
WithConnectionHandler sets handler function to be called when client is connected.
WithConnectionLostHandler sets handler function to be called when connection to the client is lost.
WithConnectTimeout limits how long the client will wait when trying to open a connection to server before timing out and erroring the attempt.
WithDefaultOptions will create client connection with some default values.
WithInsecure returns an Option which makes client connection with insecure flag so that client can provide topic with key prefix.
WithKeepAlive will set the amount of time (in seconds) that the client should wait before sending a PING request to the server.
WithLast allows to specify duration to retrive stored messages on a new relay request.
WithPingTimeout will set the amount of time (in seconds) that the client will wait after sending a PING request to the server, before deciding that the connection has been lost.
WithPubDelay allows to specify delay in milliseconds for delivery of messages if DeliveryMode is set to RELIABLE or BATCH.
WithPubDeliveryMode sets DeliveryMode of publish packet.
WithResumeSubs will enable resuming stored subscribe/unsubscribe messages when connecting but not reconnecting if CleanSession is false.
WithSessionKey returns an Option which makes client connection with an existing SessionKey.
WithStoreLogReleaseDuration sets log release duration, it must be greater than WriteTimeout.
WithStoreDir sets database directory.
WithStoreSize sets buffer size store will use to write messages into log.
WithSubDelay allows to specify delay in milliseconds for delivery of messages if DeliveryMode is set to RELIABLE or BATCH.
WithSubDeliveryMode sets DeliveryMode of a subscription.
WithTLSConfig will set an SSL/TLS configuration to be used when connecting to server.
WithTTL allows to specify time to live for a publish packet.
WithUserName returns an Option which makes client connection and pass UserName.
WithWriteTimeout puts a limit on how long a publish should block until it unblocks with a timeout error.