Documentation
¶
Index ¶
- type Configuration
- type Message
- type MessageState
- type ReceivedMessage
- type Receiver
- type RootModule
- type Sender
- type ServiceBus
- func (sb *ServiceBus) Close()
- func (sb *ServiceBus) CreateQueueReceiver(queue string) *sobek.Object
- func (sb *ServiceBus) CreateSender(queueOrTopic string) *sobek.Object
- func (sb *ServiceBus) CreateSubscriptionReceiver(topic, subscription string) *sobek.Object
- func (sb *ServiceBus) Exports() modules.Exports
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Configuration ¶
type Configuration struct {
ConnectionString string `js:"connectionString"`
Timeout int64 `js:"timeout"`
InsecureSkipVerify bool `js:"insecureSkipVerify"`
}
Configuration represents the configuration for the module.
type Message ¶
type Message struct {
ApplicationProperties map[string]string `js:"applicationProperties"`
Body []byte `js:"body"`
BodyAsString string `js:"bodyAsString"`
ContentType string `js:"contentType"`
CorrelationID string `js:"correlationID"`
MessageID string `js:"messageID"`
PartitionKey string `js:"partitionKey"`
SessionID string `js:"sessionID"`
Subject string `js:"subject"`
TimeToLive time.Duration `js:"timeToLive"`
To string `js:"to"`
}
type MessageState ¶
type MessageState string
const ( MessageStateActive MessageState = "active" MessageStateDeferred MessageState = "deferred" MessageStateScheduled MessageState = "scheduled" )
type ReceivedMessage ¶
type ReceivedMessage struct {
ApplicationProperties map[string]string `js:"applicationProperties"`
Body []byte `js:"body"`
BodyAsString string `js:"bodyAsString"`
ContentType string `js:"contentType"`
CorrelationID string `js:"correlationID"`
DeadLetterErrorDescription string `js:"deadLetterErrorDescription"`
DeadLetterReason string `js:"deadLetterReason"`
DeadLetterSource string `js:"deadLetterSource"`
DeliveryCount uint32 `js:"deliveryCount"`
EnqueuedSequenceNumber int64 `js:"enqueuedSequenceNumber"`
EnqueuedTime time.Time `js:"enqueuedTime"`
ExpiresAt time.Time `js:"expiresAt"`
LockedUntil time.Time `js:"lockedUntil"`
MessageID string `js:"messageID"`
PartitionKey string `js:"partitionKey"`
ReplyTo string `js:"replyTo"`
ReplyToSessionID string `js:"replyToSessionID"`
ScheduledEnqueueTime time.Time `js:"scheduledEnqueueTime"`
SequenceNumber int64 `js:"sequenceNumber"`
SessionID string `js:"sessionID"`
State MessageState `js:"state"`
Subject string `js:"subject"`
TimeToLive time.Duration `js:"timeToLive"`
To string `js:"to"`
}
type Receiver ¶
type Receiver struct {
// contains filtered or unexported fields
}
func (*Receiver) GetMessage ¶
func (r *Receiver) GetMessage() *ReceivedMessage
func (*Receiver) GetMessages ¶
func (r *Receiver) GetMessages(count int) []*ReceivedMessage
type RootModule ¶
type RootModule struct{}
RootModule is the global module object type. It is instantiated once per test run and will be used to create k6/x/nats module instances for each VU.
func (*RootModule) NewModuleInstance ¶
func (r *RootModule) NewModuleInstance(vu modules.VU) modules.Instance
NewModuleInstance implements the modules.Module interface and returns a new instance for each VU.
type Sender ¶
type Sender struct {
// contains filtered or unexported fields
}
func (*Sender) SendBatchMessages ¶
func (*Sender) SendMessage ¶
type ServiceBus ¶
type ServiceBus struct {
// contains filtered or unexported fields
}
ModuleInstance represents an instance of the module for every VU.
func (*ServiceBus) Close ¶
func (sb *ServiceBus) Close()
func (*ServiceBus) CreateQueueReceiver ¶
func (sb *ServiceBus) CreateQueueReceiver(queue string) *sobek.Object
func (*ServiceBus) CreateSender ¶
func (sb *ServiceBus) CreateSender(queueOrTopic string) *sobek.Object
func (*ServiceBus) CreateSubscriptionReceiver ¶
func (sb *ServiceBus) CreateSubscriptionReceiver(topic, subscription string) *sobek.Object
func (*ServiceBus) Exports ¶
func (sb *ServiceBus) Exports() modules.Exports
Exports implements the modules.Instance interface and returns the exports of the JS module.
Click to show internal directories.
Click to hide internal directories.