Release v0.3.7

This commit is contained in:
John Haverlack 2026-02-01 21:21:17 -09:00
commit b2c5e01dc4
11 changed files with 79 additions and 30 deletions

View File

@ -5,7 +5,7 @@
| **Author** | John Haverlack |
| **Copyright** | 2026 John Haverlack |
| **License** | MIT |
| **Version** | 0.3.6 |
| **Version** | 0.3.7 |
| **Date** | 2026-02-01 |
## Overview
@ -44,7 +44,7 @@ sudo ufw allow in proto udp from <NETWORK CIDR> to any port 10101
Listen to UDP 10101 for beacon messages broadcast by your SDL Manager.
```
nc -u 127.0.0.1 10101
nc -u -l -k 10101 |jq
```
> NOTE: CTRL-C to exit `nc`. You cannot run `nc` on port 10101 in parallel with the sdl-wkr. So run it once to get the install command. Tnen install sdl-wkr.

View File

@ -1,5 +1,12 @@
{
"releases": [
{
"version": "0.3.7",
"date": "2026-02-01",
"maturity": "ALPHA",
"summary": "sdl-wkr Telemetry",
"notes": ""
},
{
"version": "0.3.6",
"date": "2026-02-01",

View File

@ -5,14 +5,23 @@
| **Author** | John Haverlack |
| **Copyright** | 2026 John Haverlack |
| **License** | MIT |
| **Version** | 0.3.6 |
| **Version** | 0.3.7 |
| **Date** | 2026-02-01 |
## v0.3.7 - 2026-02-01 (ALPHA)
**Summary**
sdl-wkr Telemetry
- Fixing sdl-wkr RAM detection
- Start v0.3.7
## v0.3.6 - 2026-02-01 (ALPHA)
**Summary**
Light/Dark Mode, Wkr Install, Cluster Stats
- v0.3.6
- Adding Cluster Telemetry
- WIP: Worker Display
- Tweaks

View File

@ -5,7 +5,7 @@
| **Author** | John Haverlack |
| **Copyright** | 2026 John Haverlack |
| **License** | MIT |
| **Version** | 0.3.6 |
| **Version** | 0.3.7 |
| **Date** | 2026-02-01 |
## Overview

View File

@ -3,7 +3,7 @@
"name": "sdl",
"description": "Software Defined Laboratory",
"abbr": "SDL",
"version": "0.3.6",
"version": "0.3.7",
"version_date": "2026-02-01",
"maturity": "ALPHA",
"author": "John Haverlack",

View File

@ -659,30 +659,48 @@ function startTelemetryListener() { // ✅ Renamed function
});
});
client.on('message', (topic, message) => {
if (topic !== telemetryTopic) return;
client.on('message', (topic, message) => {
if (topic !== telemetryTopic) return;
try {
const telemetry = JSON.parse(message.toString());
const sdl_id = telemetry.msg.sdl_id;
try {
const telemetry = JSON.parse(message.toString());
const sdl_id = telemetry.msg.sdl_id;
// Update worker's last_seen timestamp
if (clusterState.workers[sdl_id]) {
clusterState.workers[sdl_id].last_seen = new Date().toISOString();
clusterState.workers[sdl_id].status = 'active';
// Update worker's last_seen timestamp
if (clusterState.workers[sdl_id]) {
clusterState.workers[sdl_id].last_seen = new Date().toISOString();
clusterState.workers[sdl_id].status = 'active';
// Update resources if provided
if (telemetry.msg.resources) {
clusterState.workers[sdl_id].resources = telemetry.msg.resources;
// ✅ MERGE resources instead of replacing
if (telemetry.msg.resources) {
// Merge each resource type
if (telemetry.msg.resources.cpus) {
clusterState.workers[sdl_id].resources.cpus = {
...clusterState.workers[sdl_id].resources.cpus,
...telemetry.msg.resources.cpus
};
}
if (telemetry.msg.resources.memory) {
clusterState.workers[sdl_id].resources.memory = {
...clusterState.workers[sdl_id].resources.memory,
...telemetry.msg.resources.memory
};
}
if (telemetry.msg.resources.gpus) {
clusterState.workers[sdl_id].resources.gpus = {
...clusterState.workers[sdl_id].resources.gpus,
...telemetry.msg.resources.gpus
};
}
clusterState = computeStats(clusterState);
saveClusterState(config, clusterState);
}
} catch (err) {
log(`${module}: failed to process telemetry: ${err}`);
clusterState = computeStats(clusterState);
saveClusterState(config, clusterState);
}
});
} catch (err) {
log(`${module}: failed to process telemetry: ${err}`);
}
});
client.on('error', err => {
log(`${module}: telemetry listener MQTT error: ${err}`);

View File

@ -1,6 +1,6 @@
{
"name": "sdl-mgr",
"version": "0.3.6",
"version": "0.3.7",
"version_date": "2026-02-01",
"description": "Software Defined Laboratory: Manager (sdl-mgr)",
"main": "index.js",

View File

@ -5,14 +5,23 @@
| **Author** | John Haverlack |
| **Copyright** | 2026 John Haverlack |
| **License** | MIT |
| **Version** | 0.3.6 |
| **Version** | 0.3.7 |
| **Date** | 2026-02-01 |
## v0.3.7 - 2026-02-01 (ALPHA)
**Summary**
sdl-wkr Telemetry
- Fixing sdl-wkr RAM detection
- Start v0.3.7
## v0.3.6 - 2026-02-01 (ALPHA)
**Summary**
Light/Dark Mode, Wkr Install, Cluster Stats
- v0.3.6
- Adding Cluster Telemetry
- WIP: Worker Display
- Tweaks

View File

@ -12,6 +12,7 @@ log('===========================================================================
log(config.package.name + ': STARTING: ' + config.package.description + ' v' + config.package.version);
// log(JSON.stringify(config, null, 2));
// log(JSON.stringify(config.dirs, null, 2), false);
log(JSON.stringify(config.host, null, 2), false);
for (let m in config.modules) {
// log(`Loading module: ${m}`);

View File

@ -309,7 +309,12 @@ function startTelemetry() {
function publishTelemetry(topic) {
if (!mqttClient || !authorized) return;
const gpuCount = Array.isArray(config.host.gpu) ? config.host.gpu.length : 0; // ✅ Fixed
const gpuCount = Array.isArray(config.host.gpu) ? config.host.gpu.length : 0;
// ✅ Convert GB to bytes
const memoryBytes = config.host.memory.total_gb
? config.host.memory.total_gb * 1024 * 1024 * 1024
: 0;
const telemetry = {
ts: new Date().toISOString(),
@ -328,8 +333,8 @@ function publishTelemetry(topic) {
used: 0
},
memory: {
allocated: config.host.memory.total_bytes,
available: config.host.memory.total_bytes,
allocated: memoryBytes, // ✅ Fixed
available: memoryBytes, // ✅ Fixed
used: 0
},
gpus: {

View File

@ -1,7 +1,7 @@
{
"name": "sdl-wkr",
"description": "Software Defined Laboratory: Worker (sdl-wkr)",
"version": "0.3.6",
"version": "0.3.7",
"version_date": "2026-02-01",
"main": "index.js",
"type": "module",