Skip to content

Instantly share code, notes, and snippets.

@didier-wenzek
didier-wenzek / gist:d37d7cdb8bdbd5b0b572f6fb81d42801
Created March 11, 2024 10:02
Tegde MQTT bridge internal docs
## Bridging local messages to the cloud
The two `half-bridge` instances cooperate:
- The `half_bridge(local_event_loop,cloud_client)` receives local messages and publishes these message on the cloud.
- The `half_bridge(cloud_event_loop,local_client)` handles the acknowledgements: waiting for messages be acknowledged by the cloud, before sending acks for the original messages.
┌───────────────┐ ┌───────────────┐
@didier-wenzek
didier-wenzek / thin-edge-gen-certs.sh
Last active November 24, 2023 16:12
Generating thin-edge certificates
#!/bin/sh
set -e
DEVICE=$(tedge config get device.id)
## Signing certificate
openssl req \
-new \
-x509 \
@didier-wenzek
didier-wenzek / Fun.java
Created September 22, 2014 17:15
Transducers in java
interface Fun<A,B> {
B apply(A a);
}