@@ -9,6 +9,8 @@ import "github.com/Azure/iot-operations-sdks/go/mqtt"
99- [ Constants] ( < #constants > )
1010- [ func IsTopicFilterMatch\( topicFilter, topicName string\) bool] ( < #IsTopicFilterMatch > )
1111- [ func RandomClientID\(\) string] ( < #RandomClientID > )
12+ - [ type AIOBrokerFeatureError] ( < #AIOBrokerFeatureError > )
13+ - [ func \( e \* AIOBrokerFeatureError\) Error\(\) string] ( < #AIOBrokerFeatureError.Error > )
1214- [ type Ack] ( < #Ack > )
1315- [ type ClientState] ( < #ClientState > )
1416- [ type ClientStateError] ( < #ClientStateError > )
@@ -33,8 +35,8 @@ import "github.com/Azure/iot-operations-sdks/go/mqtt"
3335 - [ func \( e \* FatalConnackError\) Error\(\) string] ( < #FatalConnackError.Error > )
3436- [ type FatalDisconnectError] ( < #FatalDisconnectError > )
3537 - [ func \( e \* FatalDisconnectError\) Error\(\) string] ( < #FatalDisconnectError.Error > )
36- - [ type InvalidAIOBrokerFeature ] ( < #InvalidAIOBrokerFeature > )
37- - [ func \( e \* InvalidAIOBrokerFeature \) Error\(\) string] ( < #InvalidAIOBrokerFeature .Error > )
38+ - [ type HandlerPanicError ] ( < #HandlerPanicError > )
39+ - [ func \( e \* HandlerPanicError \) Error\(\) string] ( < #HandlerPanicError .Error > )
3840- [ type InvalidArgumentError] ( < #InvalidArgumentError > )
3941 - [ func \( e \* InvalidArgumentError\) Error\(\) string] ( < #InvalidArgumentError.Error > )
4042 - [ func \( e \* InvalidArgumentError\) Unwrap\(\) error] ( < #InvalidArgumentError.Unwrap > )
@@ -127,6 +129,26 @@ func RandomClientID() string
127129
128130RandomClientID generates a random valid MQTT client ID. This should never be used in production \(as it fully invalidates all session guarantees\) but can be useful in testing to prevent parallel tests from conflicting.
129131
132+ <a name="AIOBrokerFeatureError"></a>
133+ ## type [AIOBrokerFeatureError](<https:// github.com/Azure/iot-operations-sdks/blob/main/go/mqtt/errors.go#L159-L161>)
134+
135+ AIOBrokerFeatureError indicates that a feature specific to the AIO Broker was used when AIO Broker features were explicitly disabled.
136+
137+ ```go
138+ type AIOBrokerFeatureError struct {
139+ // contains filtered or unexported fields
140+ }
141+ ```
142+
143+ <a name =" AIOBrokerFeatureError.Error " ></a >
144+ ### func \(\* AIOBrokerFeatureError\) [ Error] ( < https://github.com/Azure/iot-operations-sdks/blob/main/go/mqtt/errors.go#L163 > )
145+
146+ ``` go
147+ func (e *AIOBrokerFeatureError ) Error () string
148+ ```
149+
150+
151+
130152<a name="Ack"></a>
131153## type [Ack](<https:// github.com/Azure/iot-operations-sdks/blob/main/go/mqtt/alias.go#L30>)
132154
@@ -376,22 +398,22 @@ func (e *FatalDisconnectError) Error() string
376398
377399
378400
379- <a name="InvalidAIOBrokerFeature "></a>
380- ## type [InvalidAIOBrokerFeature ](<https:// github.com/Azure/iot-operations-sdks/blob/main/go/mqtt/errors.go#L159-L161 >)
401+ <a name="HandlerPanicError "></a>
402+ ## type [HandlerPanicError ](<https:// github.com/Azure/iot-operations-sdks/blob/main/go/mqtt/errors.go#L172-L174 >)
381403
382- InvalidAIOBrokerFeature indicates that a feature specific to the AIO Broker was used when AIO Broker features were explicitly disabled .
404+ HandlerPanicError indicates that a user\-provided handler panicked. This error will never be returned, only logged .
383405
384406```go
385- type InvalidAIOBrokerFeature struct {
407+ type HandlerPanicError struct {
386408 // contains filtered or unexported fields
387409}
388410```
389411
390- <a name =" InvalidAIOBrokerFeature .Error" ></a >
391- ### func \(\* InvalidAIOBrokerFeature \) [ Error] ( < https://github.com/Azure/iot-operations-sdks/blob/main/go/mqtt/errors.go#L163 > )
412+ <a name =" HandlerPanicError .Error" ></a >
413+ ### func \(\* HandlerPanicError \) [ Error] ( < https://github.com/Azure/iot-operations-sdks/blob/main/go/mqtt/errors.go#L176 > )
392414
393415``` go
394- func (e *InvalidAIOBrokerFeature ) Error () string
416+ func (e *HandlerPanicError ) Error () string
395417```
396418
397419
@@ -572,7 +594,7 @@ func (c *SessionClient) RegisterConnectEventHandler(handler ConnectEventHandler)
572594RegisterConnectEventHandler registers a handler to a list of handlers that are called synchronously in registration order whenever the session client successfully establishes an MQTT connection. Note that since the handler gets called synchronously, handlers should not block for an extended period of time to avoid blocking the session client.
573595
574596<a name="SessionClient.RegisterDisconnectEventHandler"></a>
575- ### func \(\*SessionClient\) [RegisterDisconnectEventHandler](<https:// github.com/Azure/iot-operations-sdks/blob/main/go/mqtt/connect.go#L31-L33 >)
597+ ### func \(\*SessionClient\) [RegisterDisconnectEventHandler](<https:// github.com/Azure/iot-operations-sdks/blob/main/go/mqtt/connect.go#L38-L40 >)
576598
577599```go
578600func (c *SessionClient) RegisterDisconnectEventHandler(handler DisconnectEventHandler) func()
@@ -581,7 +603,7 @@ func (c *SessionClient) RegisterDisconnectEventHandler(handler DisconnectEventHa
581603RegisterDisconnectEventHandler registers a handler to a list of handlers that are called synchronously in registration order whenever the session client detects a disconnection from the MQTT server. Note that since the handler gets called synchronously, handlers should not block for an extended period of time to avoid blocking the session client.
582604
583605<a name="SessionClient.RegisterFatalErrorHandler"></a>
584- ### func \(\*SessionClient\) [RegisterFatalErrorHandler](<https:// github.com/Azure/iot-operations-sdks/blob/main/go/mqtt/connect.go#L39-L41 >)
606+ ### func \(\*SessionClient\) [RegisterFatalErrorHandler](<https:// github.com/Azure/iot-operations-sdks/blob/main/go/mqtt/connect.go#L53-L55 >)
585607
586608```go
587609func (c *SessionClient) RegisterFatalErrorHandler(handler func(error)) func()
@@ -599,7 +621,7 @@ func (c *SessionClient) RegisterMessageHandler(handler MessageHandler) func()
599621RegisterMessageHandler registers a message handler on this client. Returns a callback to remove the message handler.
600622
601623<a name="SessionClient.Start"></a>
602- ### func \(\*SessionClient\) [Start](<https:// github.com/Azure/iot-operations-sdks/blob/main/go/mqtt/connect.go#L48 >)
624+ ### func \(\*SessionClient\) [Start](<https:// github.com/Azure/iot-operations-sdks/blob/main/go/mqtt/connect.go#L69 >)
603625
604626```go
605627func (c *SessionClient) Start() error
@@ -608,7 +630,7 @@ func (c *SessionClient) Start() error
608630Start the session client, spawning any necessary background goroutines. In order to terminate the session client and clean up any running goroutines, Stop\(\) must be called after calling Start\(\).
609631
610632<a name="SessionClient.Stop"></a>
611- ### func \(\*SessionClient\) [Stop](<https:// github.com/Azure/iot-operations-sdks/blob/main/go/mqtt/connect.go#L73 >)
633+ ### func \(\*SessionClient\) [Stop](<https:// github.com/Azure/iot-operations-sdks/blob/main/go/mqtt/connect.go#L94 >)
612634
613635```go
614636func (c *SessionClient) Stop() error
@@ -617,7 +639,7 @@ func (c *SessionClient) Stop() error
617639Stop the session client, terminating any pending operations and cleaning up background goroutines.
618640
619641<a name="SessionClient.Subscribe"></a>
620- ### func \(\*SessionClient\) [Subscribe](<https:// github.com/Azure/iot-operations-sdks/blob/main/go/mqtt/subscribe.go#L75-L79 >)
642+ ### func \(\*SessionClient\) [Subscribe](<https:// github.com/Azure/iot-operations-sdks/blob/main/go/mqtt/subscribe.go#L80-L84 >)
621643
622644```go
623645func (c *SessionClient) Subscribe(ctx context.Context, topic string, opts ...SubscribeOption) (*Ack, error)
@@ -626,7 +648,7 @@ func (c *SessionClient) Subscribe(ctx context.Context, topic string, opts ...Sub
626648Subscribe to the given topic.
627649
628650<a name="SessionClient.Unsubscribe"></a>
629- ### func \(\*SessionClient\) [Unsubscribe](<https:// github.com/Azure/iot-operations-sdks/blob/main/go/mqtt/subscribe.go#L118-L122 >)
651+ ### func \(\*SessionClient\) [Unsubscribe](<https:// github.com/Azure/iot-operations-sdks/blob/main/go/mqtt/subscribe.go#L123-L127 >)
630652
631653```go
632654func (c *SessionClient) Unsubscribe(ctx context.Context, topic string, opts ...UnsubscribeOption) (*Ack, error)
0 commit comments