Archive for 'Testing'

Bugfix coming soon…

A few bugs have been identified with the 1.0 release; thanks to everyone who has got in touch about it. They’re mostly documentation/build script mistakes (see https://bitbucket.org/oojah/mosquitto/src/tip/ChangeLog.txt ), but there is a Python bug that makes it worthwhile making a quick bugfix release.

I intend to make the release this evening (in around 8 hours from this post), so if you have anything you think needs fixing please try and get in touch before then.

Upcoming release

The next release of mosquitto is approaching. There is currently only one feature left on the todo list to complete and I’ve pencilled in the end of the month as the release date. The date may slip a week or two after that depending on any bugs reported.

Despite the development being carried out in the 0.16 branch and the current in-development version numbers being 0.15.90, this will be version 1.0 of mosquitto. There has been significant API changes (now a lot more sane hopefully) which means the client library interface version has been incremented, and the number of changes involved in this release far outreach any previous release, including SSL support, a pure Python client implementation, a healthy start on tests and an associated improvement in protocol compliance, and threaded client support. I think it is well worthy of the version number.

I am, however, very keen that this be as bug free a release as possible. To this end, if you’re a mosquitto user I’d be very appreciative if you’d download the current source code and give it a try. Maybe read through the documentation and check it makes sense

The source for the current version is at either of these links (ignore the “0.16”, that is just the branch name):

If you want to test but with a minimum amount of effort, please download the source, run “make test” and report back any problems. This would be particularly  useful if you are using something other than a Debian/Ubuntu/openSUSE based Linux. If you have any problems, bugs can be reported at https://launchpad.net/mosquitto, by leaving a comment or by getting in touch directly. I’m interested in anything, but would be especially keen to hear from you if you think something to do with the client API needs changing.

Thanks in advance!

SSL support on Test Server

The next version of Mosquitto will provide SSL support for network encryption and authentication. This work is still in development, but is sufficiently advanced to make available for testing on test.mosquitto.org. In addition to the existing unencrypted access via port 1883, connections are now possible on ports 8883 and 8884.

Port 8883 provides simple encrypted access. Your client should verify the server certificate using the CA certificate available at http://test.mosquitto.org/ssl/mosquitto.org.crt

Port 8884 uses the same server certificate, but requires that your client provide a valid certificate signed by the mosquitto.org CA key. If you wish to obtain a client certificate for testing purposes, please get in touch.

The development Python module provides client SSL support. The latest version is available at http://test.mosquitto.org/ssl/mosquitto.py with a simple example at http://test.mosquitto.org/ssl/ssub.py. You will need to place the mosquitto.org CA certificate linked above in the same directory. All versions of Python from 2.7 upwards (including Python 3) are supported.

Please get in touch if you have any problems.

Update:

All clients in the development version now support SSL.

IPv6 on Test Server

The public Mosquitto test server, test.mosquitto.org has supported IPv6 since it was originally put online but the required DNS record was missing. This has now been fixed so once the record has propagated across the internet you should be able to test your IPv6 clients.

As part of the ongoing work on mosquitto 0.16, the libmosquitto C client library has been ported to Python. It provides complete MQTTv3.1 support and will eventually remove the need for the current Python wrapper around the C library and will allow it to be used more easily and in more situations.

The interface is largely the same as the existing Python wrapper. The differences are that it uses the current development interface which differs slightly from that in 0.15 (see the Python documentation), not all of the new interface is implemented – there is no threading support and finally some datatypes may be more Python like (e.g. lists in on_subscribe() callback rather than an integer).

The conversion from ~4000 lines C to ~1000 lines Python took just two evenings and is now ready for testing. It is available in the 0.16 branch in the bitbucket repository, or as a single file at http://mosquitto.org/files/python/mosquitto.py

Please give it a try and report any bugs you find using any of the methods on the Support page.

Please note that the new Python module does not currently support Python 3.

Mosquitto Test Server

A publicly accessible Mosquitto server is now available to use. Details are at http://test.mosquitto.org/

Mosquitto 0.9~test2

Mosquitto 0.9, which I hope to release mid November, represents the most significant change to mosquitto to date – the removal of sqlite as an absolute dependency. In addition, this removes the dependency on the sqlite3-pcre extension and on pcre. This gives a definite performance improvement, reduces the amount of object code that needs loading by around 95%, reduces memory usage and also makes it lots easier to compile on more unusual systems.

It’s quite a substantial change though, so I’ve made a test release to hopefully get some external testing. If you could give it a try and report back that’d be great. The source is at http://mosquitto.org/files/source/test/ (use the highest numbered version available). There are also Ubuntu packages available at the mosquitto-expt ppa and binaries for Fedora, Mandriva,  SLES and openSUSE at the openSUSE build service. If you’d like binaries for other systems, please get in touch.

Note that this is a test release, not a release candidate – there are definitely things that still need changing. The following list shows the points I’m currently aware of:

  • Old style sqlite will be imported when the option is compiled in (enabled by default). This import currently only imports retained messages and durable subscriptions, but not queued messages.
  • The max_inflight_messages and max_queued_messages config options are ignored and no maximum is applied.
  • The CMake compilation scripts aren’t updated.

Update

I’ve uploaded test3 with a python fix, updated CMake scripts and fixed max_inflight_messages and max_queued_mesages.

MQTT client library

I have been working on a client library for MQTT for the next release of Mosquitto. It is now at a stage where it is usable and ready for wider testing. There isn’t any documentation yet (!) so it’s only available in the source repository at http://bitbucket.org/oojah/mosquitto.Use the “get source” link in the top right corner of the page to download a snapshot. If you’re interested in developing your own open source MQTT clients, it’d be great if you could take a look to make sure the interface is sane before I make a release!

The library itself is written in C, with bindings for C++ and Python.

I plan to package it up in a more easy to access form in the not too distant future, hopefully with some documentation as well.

Update

I’ve put the start of a man page online, which shows an example of using libmosquitto to subscribe to a topic and print the results: libmosquitto.3