I’ve been using a self-hosted file sharing service for the past three years in order to move away from large commercial parties in this space. I started using owncloud in the summer of 2016, but switched to nextcloud later that year as Frank Karlitschek, the founder, left owncloud. The open source, large community and the self-hosted aspects of nextcloud are the biggest draws to the project for me. Hosting my own instance means I get to indulge in some sysops, one of my pastimes. You can find more details on the self-hosted aspect in the ‘Self-hosted’ section at bottom of this post. In short, I decided to switch to a new offering of my VPS provider which meant migrating nextcloud to a new server.
Continue reading “Migrating nextcloud to a new server”
Lately I have been looking at Google’s format for interchanging data between multiple processes or Protocol Buffers. As you would expect for an inter-process data format Protocol Buffers are supported on different platforms and implementations are available for most popular programming languages. An interesting example of such a platform is the stm32l1 micro controller, which is supported by a third party protobuf implementation named nano pb.
One of the interesting feats of Google’s C++ protobuf implementation is that it supports deserializing arbitrary protobuf objects at run-time. As long as the proto definition is known at run time, the library is capable of parsing any message back into the individual fields from the proto definition. This is especially useful in situations where a program has to be able to handle proto definitions that are unknown at compile time. In this case the standard approach of using the proto compiler (protoc) to construct C++ class definitions, writing (de)serialization code and linking the resulting program with these definitions is obviously not possible.
This post addresses the lack of examples that demonstrate this ‘at run-time deserialization’ feature of Google’s C++ protobuf implementation. The example below was constructed by combining the protobuf unit tests with this example provided by cxwangyi. It has been tested with the v3.0.0-beta-3 from Google’s github repo. Use at your own discretion. The example should be self explanatory.
Continue reading “Google protobuf at run-time deserialization example in C++”
At IBCN – my research group – we rely on Click router for implementing and evaluating various Internet communication protocols. Click is a modular software router in C++ that was developed at the end of the last century by Eddie Kohler and others at MIT (the original research paper is available here). Apart from the IP routing functionality that ships with Click, we’ve added a CoAP implementation that has been widely tested at ETSI Plugtest interoperability events. We also have a working 6LoWPAN implementation that was tested in at last year’s summer IETF in Berlin. Lately, we’ve also added DTLS integration via CyaSSL. Continue reading “Cross compiling C projects with external dependencies: Click modular router and the Raspberry PI”