max_blogger

/Maximilian Batz

About Maximilian Batz

Keine
So far Maximilian Batz has created 47 blog entries.

envoy websockets per route configuration, JavaScript test setup

In my article yesterday I discussed the configuration & test of envoy for proxying websockets at length.Today I would like to add some additional information.correct syntax for websocket upgrade per routeYou can enable websocket upgrade per route. No need to add it globally:- name: envoy.http_connection_manager    config:      #upgrade_configs:      #  - upgrade_type: websocket      stat_prefix: ingress_https      use_remote_address: true      [...]

By | Mai 19th, 2019|Development|Kommentare deaktiviert für envoy websockets per route configuration, JavaScript test setup

envoy, docker and websockets – debugging and configuration

Websockets are an exciting technology, allowing you to upgrade a HTTP connection to a long-running persistent binary connection, which you can use to send bi-directional messages.As an aside, the MQTT protocol can be transported using websockets – which is the only (?) way for a JavaScript client delivered by the website, for instance.In any case, [...]

By | Mai 18th, 2019|Development, Docker|Kommentare deaktiviert für envoy, docker and websockets – debugging and configuration

correct way to instantiate Paho Client in JavaScript for wss (secure websocket)

The Paho documentation is unfortunately quite fragmented at the moment, and some links on Eclipse’s website do not work.Here are some working links (as of 05/2019):https://www.eclipse.org/paho/clients/js/https://www.eclipse.org/paho/files/jsdoc/index.htmlhttps://github.com/eclipse/paho.mqtt.javascriptAnd here’s a fantastic website by Steve:http://www.steves-internet-guide.com/using-javascript-mqtt-client-websockets/There is an important breaking change in the Paho namespace, where you will run into trouble using Steve’s code:“Previously the Client's Namepsace was Paho.MQTT, [...]

By | Mai 17th, 2019|Development|Kommentare deaktiviert für correct way to instantiate Paho Client in JavaScript for wss (secure websocket)

Understanding Erlang & Lua / Luerl for VerneMQ MongoDB auth_on_register hook

My goal / TLDRMy goal with this blog post is to explain how to set custom mountpoints for VerneMQ by modifying the shipped MongoDB auth Lua script  (lua/auth/mongodb.lua).Setting a custom mountpoint is possible with VerneMQ not only by setting mountpoints manually for specific listeners (e.g. ports), but also programmatically during authorization in your scripts.I had [...]

By | Mai 12th, 2019|Development|Kommentare deaktiviert für Understanding Erlang & Lua / Luerl for VerneMQ MongoDB auth_on_register hook

mongo_orm Exception: missing bson key: publish_acl (Exception)

When you extend your field definitions in the mongo_orm document classes, specifically with embedded documents, you might run into the following runtime (!) error:Exception: missing bson key: <name> (Exception)This is not an error in your code – your code is raising, because the database structure is not as it expects it to be!Here’s the sample [...]

By | Mai 10th, 2019|Crystal Language|Kommentare deaktiviert für mongo_orm Exception: missing bson key: publish_acl (Exception)

Introduction to the SNAP protocol

IntroductionS.N.A.P. is a protocol for communication between several connected hosts. It provides:· addressing· flags· ack/nak request· error detection (different error detection methods available)It can be run over different media, including RS485. It is optimized for a small footprint (limited computing, memory resources), but scaleable depending upon your needs.Basically, if you want to connect several compute [...]

By | April 23rd, 2019|Development|Kommentare deaktiviert für Introduction to the SNAP protocol

Elektronik-Gehäuse & Platinenabmessungen Standards

Abmessungen Raspberry PiEin Raspberry Pi 3B+ hat, als Vergleich, die Abmessungen: 85 mm x 56 mm für die Basisplatine. (USB & LAN, sowie andere Stecker ragen teilweise über die Platine hinaus). Hutschiene / DIN-SchieneHutschiene: TS35, U-förmiges Profil. Standarisierte Befestigungsschiene für Gehäuse, Racks, Schaltschränke, u.s.w. Sie wird vielfach in der Industrie eingesetzt. Einer der ersten Einsatzzwecke [...]

By | April 20th, 2019|Raspberry Pi Blog|Kommentare deaktiviert für Elektronik-Gehäuse & Platinenabmessungen Standards

Packaging Python projects for Debian / Raspbian with dh-virtualenv

This article aims to explain some things to developers which don’t use Python a lot, and might struggle with some of the concepts otherwise.I highly recommend the lecture of the following article as an introduction to the concepts discussed here:https://www.dabapps.com/blog/introduction-to-pip-and-virtualenv-python/pypi.orgpypi.org is an official repository of software for the Python programming language. It includes libraries we [...]

By | April 19th, 2019|Development, Raspberry Pi Embedded Development|Kommentare deaktiviert für Packaging Python projects for Debian / Raspbian with dh-virtualenv

mongo_orm custom name for collection

mongo_orm will automatically determine the name for your collection by using the Module and Class name, and appending an “s”.In cases where you want to name your collection, you can simply do this:class PapiTest < Mongo::ORM::Document     collection_name "Buster"     field test : String end get "/" do     pt = PapiTest.new     pt.test = "I want your sex"     [...]

By | April 17th, 2019|Crystal Language|Kommentare deaktiviert für mongo_orm custom name for collection

Avahi how to assign several .local names to same IP

In some situations you would like to access the same computer / IP using different .local names.This is possible using the Avahi daemon. The following is written for Ubuntu 18.04 Bionic Beaver.Install Avahiapt install avahi-daemon avahi-utilsAvahi automatically adds your computer’s hostname to the .local Domain. For instance, my computer is called morpheus. Therefore it will [...]

By | April 10th, 2019|Tips & tricks|Kommentare deaktiviert für Avahi how to assign several .local names to same IP