Documentation ¶
Overview ¶
Package resource contains types and factory functions for various broker resources such as topics and queues.
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Destination ¶
type Destination interface { // GetName retrieves the name of the destination GetName() string }
Destination represents a message destination on a broker. Some examples of destinations include queues and topics. Destination implementations can be retrieved by the various helper functions, such as TopicOf, QueueDurableExclusive, and TopicSubscriptionOf.
type Queue ¶
type Queue struct {
// contains filtered or unexported fields
}
Queue represents a queue used for guaranteed messaging receivers.
func QueueDurableExclusive ¶
QueueDurableExclusive creates a new durable, exclusive queue with the specified name.
func QueueDurableNonExclusive ¶
QueueDurableNonExclusive creates a durable, non-exclusive queue with the specified name.
func QueueNonDurableExclusive ¶
QueueNonDurableExclusive creates an exclusive, non-durable queue with the specified name.
func QueueNonDurableExclusiveAnonymous ¶
func QueueNonDurableExclusiveAnonymous() *Queue
QueueNonDurableExclusiveAnonymous creates an anonymous, exclusive, and non-durable queue.
func (*Queue) GetName ¶
GetName returns the name of the queue. Implements the Destination interface.
func (*Queue) IsDurable ¶
IsDurable determines if the Queue is durable. Durable queues are privisioned objects on the broker that have a lifespan that is independent of any one client session.
func (*Queue) IsExclusivelyAccessible ¶
IsExclusivelyAccessible determines if Queue supports exclusive or shared-access mode. Returns true if the Queue can serve only one consumer at any one time, false if the Queue can serve multiple consumers with each consumer serviced in a round-robin fashion.
type ShareName ¶
type ShareName struct {
// contains filtered or unexported fields
}
ShareName is an interface for identifiers that are associated with a shared subscription. See https://docs.solace.com/PubSub-Basics/Direct-Messages.htm#Shared in the Solace documentation.
func ShareNameOf ¶
ShareNameOf returns a new share name with the provided name. Valid share names are not empty and do not contain special characters '>' or '*'. Returns a new ShareName with the given string.
type Subscription ¶
type Subscription interface { Destination // GetSubscriptionType will return the type of the subscription as a string GetSubscriptionType() string }
Subscription represents the valid subscriptions that can be specified to receivers. Valid subscriptions include *resource.TopicSubscription.
type Topic ¶
type Topic struct {
// contains filtered or unexported fields
}
Topic is an implementation of destination representing a topic that can be published to.
type TopicSubscription ¶
type TopicSubscription struct {
// contains filtered or unexported fields
}
TopicSubscription is a subscription to a topic often used for receivers.
func TopicSubscriptionOf ¶
func TopicSubscriptionOf(topic string) *TopicSubscription
TopicSubscriptionOf creates a TopicSubscription of the specified topic string.
func (*TopicSubscription) GetName ¶
func (t *TopicSubscription) GetName() string
GetName returns the topic subscription expression. Implements the Destination interface.
func (*TopicSubscription) GetSubscriptionType ¶
func (t *TopicSubscription) GetSubscriptionType() string
GetSubscriptionType returns the type of the topic subscription as a string
func (*TopicSubscription) String ¶
func (t *TopicSubscription) String() string
String implements fmt.Stringer