Skip to content

Releases: eclipse-paho/paho.mqtt.golang

v1.5.0

31 Jul 00:06
714f7c0
Compare
Choose a tag to compare

In the year since the release of v1.4.3 the majority of changes have been small incremental improvements/fixes. One notable change is that Go v1.20+ is now required (due to PR #646).

What's Changed

New Contributors

Full Changelog: v1.4.3...v1.5.0

v1.4.3

06 Jul 03:36
aa0a8ad
Compare
Choose a tag to compare

Release 1.4.3 is a relatively small release to bring in changes made in the eight months since 1.4.2.

Thanks to everyone who submitted issues and contributed code (list of the main merged pull requests below):

What's Changed

  • Avoid Panic when keepalive is 1 by @tomatod in #622
  • Allow MQTT username/password in websocket URI @MattBrittan in #624
  • Add backoff when reconnecting following immediate connection loss @tomatod in #625
  • Update dependencies (github.com/gorilla/[email protected], golang.org/x/net, golang.org/x/sync) and specify go 1.18 in go.mod.

Full Changelog: v1.4.2...v1.4.3

v1.4.2

25 Oct 01:34
a1800d8
Compare
Choose a tag to compare

Release 1.4.2 is relatively small and is mostly focused on tidying up the way the library manages the connection status. Previously sync/ atomic was used to read/update the status but this led to a range of potential deadlocks, and workarounds to avoid these, which made the code difficult to follow. The new connectionStatus separates status handling from client and should simplify further development whilst resolving potential race conditions. It is my hope that users will not notice any change (@master was updated on 10th August and the updated code has been running in production at a few sites since then without issue).

A further change is that it is now possible to disable auto acknowledgment so that received messages can be manually acknowledged (or, more to the point, not acknowledged!).

Thanks to everyone who submitted issues and contributed code (list of the main merged pull requests below):

What's Changed

New Contributors

Full Changelog: v1.4.1...v1.4.2

v1.4.1

05 Jun 22:35
bcb58ee
Compare
Choose a tag to compare

The license update in v1.4.0 included changes which prevented https://pkg.go.dev from displaying the documentation. The only change in this release is to update LICENSE such that it includes the full test of the Eclipse Public License v2.0 (tested this on a fork and it appears to resolve the issue).

v1.4.0

05 Jun 21:48
8717376
Compare
Choose a tag to compare

In the year since the release of v1.3.5 the majority of changes have been small incremental improvements/fixes. It is worth noting that the library has moved to the EPL v2.0 license (faq).

A few new features have been added:

  • Managing the connection to the broker can become involved (e.g. setting unusual TCP/TLS options, need for a non-standard TLS library, require a specific web-socket library etc) and the library already has too many options! To address this a new option, SetCustomOpenConectionFn, has been added that enables users to provide a function (func(uri *url.URL, options ClientOptions) (net.Conn, error)) that will be called to establish a connection (replacing the inbuilt code). This should enable edge cases to be addressed without the need for further changes to this library.
  • When connecting/reconnecting it is possible that there will be a lot of packets queued; in the past the library sent all of these packets as rapidly as possible when the connection came up. However this could saturate some network links causing the connection to drop (a vicious circle). The new option SetMaxResumePubInFlight allows a limit to be imposed; the library will send out the requested number of packets and then wait for acknowledgements before sending more (only applicable at QOS1+).

Thanks to everyone who submitted issues and contributed code (list of the main merged pull requests below):

What's Changed

  • SetMaxResumePubInFlight option - limit inflight publish packets on resume by @MattBrittan in #521
  • Test for PR 521 (forgot to commit) by @MattBrittan in #522
  • Dont panic if there are files with short names in the file store folder. by @MattBrittan in #523
  • Add license headers to all files and move from EPL v1.0 to EPL v2.0 by @MattBrittan in #524 / #525
  • Add warning to Disconnect function by @MattBrittan in #537
  • Use uri.Path instead of uri.Host for UNIX domain socket URLs by @webconn in #540
  • CodeQL & integer conversion fix by @jfcg in #541
  • Mosquitto related changes (updated config and comments). by @MattBrittan in #546
  • README enhancements by @MattBrittan in #547 / #548
  • Improve handling of SUBSCRIBE/UNSUBSCRIBE over disconnect/reconnect. by @MattBrittan in #557
  • log err.error() if ConnectRetry is enabled by @TomasVojacek in #558
  • Add tcp option to set keep alive value on the tcp layer by @mogaleaf in #561
  • Document token.Wait behaviour during reconnect by @ecksun in #565
  • Custom open connection for different network types by @GilGil1 in #574 / #575
  • nil c.options.Dialer caused a panic. by @MattBrittan in #577
  • Disconnect refactor by @ptsneves in #586
  • client.go Remove Disconnect()'s wait on c.commsStopped. by @ptsneves in #590

New Contributors

Full Changelog: v1.3.5...v1.4.0

v1.3.5

06 Jun 22:07
88d5334
Compare
Choose a tag to compare

This is a minor release that resolves two serious, but rarely experienced, issues:

#508 Resolve send on closed channel when order=false and connection closed - @MattBrittan (thanks to @thomas-tacquet for raising this issue and suggesting a solution #504 )
#512 Resolve rare deadlock caused by loss of connection (in particular circumstances) - @MattBrittan (thanks to @dehort for raising #509 and providing the detailed logging needed to trace this)

v1.3.4

03 May 22:02
8e87e5f
Compare
Choose a tag to compare

This is a minor release that improves support for proxies, removes passwords from the logs, and resolves a potential deadlock in Disconnect().

#497 Provides a callback (c.options.OnConnectAttempt) on connection allowing per attempt tls details; improves proxy support - @amir-khassaia
#500 Redact password in Stringer of packets.ConnectPacket - @besedad
#502 Handle connection loss during call to Disconnect() - @MattBrittan

v1.3.3

31 Mar 22:06
a140ed8
Compare
Choose a tag to compare

This is a minor release that adds support for websocket proxies, resolves a potential panic, and sets the DUP flag when resenting PUBLISH packets.

#431 Add Proxy to WebsocketOptions (also logs status if connection fails) - @fulder
#489 If options.AutoReconnect is true calling Disconnect may trigger panic - @MattBrittan
#490 When resending QOS 1+ PUBLISH packets the DUP flag should be set - @MattBrittan

v1.3.2

07 Feb 07:59
18bfbde
Compare
Choose a tag to compare

This is a minor release that resolves a reported issue (#479 & #469) that broke connections to AWS IoT over WSS. Fixing this involved reversing PR #319 which may break some specific IPV6 use-cases (if this impacts this you will need to update your code to pass in an address that complies with RFC3986/RFC6874; i.e. escape % chars in the zone identifier).

  • Export connection refused errors outside of the map - @umeat
  • Remove changes introduced in PR #319 (escaping % in server string) - @MattBrittan
  • Documentation / sample code updates - @MattBrittan

v1.3.1

30 Dec 02:31
7597d77
Compare
Choose a tag to compare

This is a minor release that resolves a reported issue that could lead to a deadlock when shutting down following a loss of connection (thanks to @williamshaocharles for reporting this and providing logs).