Skip to content
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
77 commits
Select commit Hold shift + click to select a range
74fb97e
Change test port
j-rafique Sep 24, 2025
cf7f877
Async events (#190)
mateeullahmalik Sep 24, 2025
1f524bf
Add profile script
j-rafique Sep 24, 2025
1310df6
Merge pull request #191 from LumeraProtocol/ProfileScript
j-rafique Sep 24, 2025
b123dce
Change test port
mateeullahmalik Sep 24, 2025
3c66950
Disable Metrics
j-rafique Sep 25, 2025
4dd2bca
Merge pull request #192 from LumeraProtocol/DisableMetric
j-rafique Sep 25, 2025
c53d7c3
Silence all logs
mateeullahmalik Sep 29, 2025
6bd2b9c
high-signal logs
mateeullahmalik Sep 30, 2025
8346283
Add datadog logs
mateeullahmalik Sep 30, 2025
0e35cf6
TxResponse
mateeullahmalik Sep 30, 2025
3d8386a
skip check for public field
mateeullahmalik Sep 30, 2025
d32a5c7
peers+balance (#196)
mateeullahmalik Sep 30, 2025
7b85f4d
Tx mode block
mateeullahmalik Oct 1, 2025
34dfc95
fix :tx Broadcst method cleanup
mateeullahmalik Oct 2, 2025
7bd1a03
Logs
mateeullahmalik Oct 2, 2025
ee927a0
High Signal Logs
mateeullahmalik Oct 2, 2025
18c2a70
enhance tracing
mateeullahmalik Oct 2, 2025
cae661d
Metrics Cleanup
mateeullahmalik Oct 3, 2025
57c92f5
Increase raptorq memory
mateeullahmalik Oct 3, 2025
6d3f03e
Add cascadekit; refactor services, e2e, docs
mateeullahmalik Oct 3, 2025
fa9195f
remove stake
mateeullahmalik Oct 3, 2025
3e13e1f
Use lume in genesis
mateeullahmalik Oct 3, 2025
1269fcd
Clean up task from supernode and sn manager
mateeullahmalik Oct 3, 2025
233d074
Consolidate p2p logic in adapter
mateeullahmalik Oct 3, 2025
d115fe6
Cleanup
mateeullahmalik Oct 3, 2025
90b89d6
Fixes
mateeullahmalik Oct 4, 2025
2647c37
FileName
mateeullahmalik Oct 4, 2025
9e1360e
go fmt
mateeullahmalik Oct 4, 2025
c27161d
SDK changes
mateeullahmalik Oct 4, 2025
4967020
fixes : sdk , format files
mateeullahmalik Oct 6, 2025
c853fa5
Merge pull request #198 from LumeraProtocol/action-sdk-update
a-ok123 Oct 6, 2025
028179e
sn-manager update
mateeullahmalik Oct 7, 2025
d11dda7
remove unused vars
mateeullahmalik Oct 8, 2025
6b073a4
batch size
mateeullahmalik Oct 8, 2025
5b93c20
Add logs for meta files
mateeullahmalik Oct 8, 2025
2ddda94
Add pprof routing via swagger
j-rafique Oct 8, 2025
b433567
Merge pull request #201 from LumeraProtocol/pprofRoutingSwagger
j-rafique Oct 8, 2025
ba79a79
Route pprof via swagger endpoints
j-rafique Oct 9, 2025
b43dd13
Merge pull request #202 from LumeraProtocol/pprRouteViaSwagger
j-rafique Oct 9, 2025
d8c9a88
fix : go mod; regenrate proto
mateeullahmalik Oct 9, 2025
662f237
resolve do mod issues
mateeullahmalik Oct 9, 2025
92e557a
tighten stable release check
mateeullahmalik Oct 10, 2025
1184a54
Task tracking + Supernode deterministic selection In SDK (#203)
mateeullahmalik Oct 10, 2025
f6035f8
Add active filter in Supernode Block Query
mateeullahmalik Oct 10, 2025
f5d9e65
fix : Dont call unregister ALTS on connection close
mateeullahmalik Oct 10, 2025
cd7f498
improve suernode selection and discovery
mateeullahmalik Oct 10, 2025
82d6271
Improve task tracking
mateeullahmalik Oct 10, 2025
2e5e879
Move adapters to outside cascade
mateeullahmalik Oct 13, 2025
0604508
Add version gating in dht
mateeullahmalik Oct 13, 2025
fda3eae
Add snapshot capture timeouts in status api
mateeullahmalik Oct 13, 2025
33b6184
Rq-8-GB-Logs
mateeullahmalik Oct 13, 2025
ae0b6c1
Migrate github client to main pkg
mateeullahmalik Oct 14, 2025
4891e24
Enforce version check in sdk
mateeullahmalik Oct 14, 2025
ad82259
Add cache for supernode info calls in sdk
mateeullahmalik Oct 17, 2025
2938b5c
Enhancements in cascadekit, supenrode (#205)
mateeullahmalik Oct 20, 2025
c2372e8
Optionally enforce min supernode version (#206)
mateeullahmalik Oct 20, 2025
6a2e43e
Merge origin/master into supernode-refactor: keep refactor deletions …
mateeullahmalik Oct 21, 2025
c5b142a
Optimize supernode symbol fetch
j-rafique Oct 22, 2025
e322576
log fix
j-rafique Oct 22, 2025
5789526
Rank supernodes by free ram (#207)
mateeullahmalik Oct 22, 2025
ffdd516
Merge pull request #210 from LumeraProtocol/OptimizeFetchUpdates
j-rafique Oct 22, 2025
f40a187
Relax hard equality check on action fee (#213)
mateeullahmalik Oct 22, 2025
89c4abb
Rank supernodes; xor, ram,storage (#214)
mateeullahmalik Oct 23, 2025
4e1a726
exclude sn free resource check in sdk
mateeullahmalik Oct 23, 2025
87d5d49
Merge pull request #199 from LumeraProtocol/supernode-refactor
mateeullahmalik Oct 23, 2025
8004ae5
enhance supernode discovery (#217)
mateeullahmalik Oct 23, 2025
7a83904
Lumera 1.8.0 (#216)
mateeullahmalik Oct 23, 2025
0ef6403
blake3 hashing code optimization (#219)
akobrin1 Oct 24, 2025
185c199
Optional min version enforcement via build flag (#218)
mateeullahmalik Oct 24, 2025
5a38f0f
Accept all req params in top sn query
mateeullahmalik Oct 24, 2025
7459657
fix: github CI error after retaggin lumera v1.8.0
mateeullahmalik Oct 24, 2025
0f7d5e0
Use ADR36 signautres (#222)
mateeullahmalik Nov 3, 2025
4e4664e
fx
mateeullahmalik Oct 3, 2025
c8f66f3
Optimize Symbol Fetch
j-rafique Oct 21, 2025
98c732d
Optimize write
j-rafique Oct 22, 2025
62300fa
Only count success writes
j-rafique Oct 27, 2025
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
18 changes: 17 additions & 1 deletion .github/actions/setup-env/action.yml
Original file line number Diff line number Diff line change
@@ -1,7 +1,11 @@
name: Setup Environment
description: Sets up Go (dynamically from go.mod) and installs system dependencies

inputs: {}
inputs:
bust_lumera_retag:
description: "One-time: remove lumera v1.8.0 sums after retag"
required: false
default: 'false'
outputs:
go-version:
description: "Go version parsed from go.mod"
Expand Down Expand Up @@ -29,6 +33,18 @@ runs:
sudo apt-get update
sudo apt-get install -y libwebp-dev make

- name: One-time reset retagged lumera checksums
if: ${{ inputs.bust_lumera_retag == 'true' }}
shell: bash
run: |
echo "Busting go.sum entries for github.com/LumeraProtocol/lumera v1.8.0 (one-time)"
# Remove stale checksums in all local modules
find . -name 'go.sum' -maxdepth 3 -print0 | xargs -0 -I{} sed -i \
'/github.com\/LumeraProtocol\/lumera v1.8.0/d' {}
# Clear module/build caches to avoid cached zips
go clean -modcache || true
rm -rf "$(go env GOCACHE)" || true

- name: Set Go Private Modules
shell: bash
run: |
Expand Down
20 changes: 19 additions & 1 deletion .github/workflows/build&release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -27,14 +27,20 @@ jobs:

- name: Setup Go and dependencies
uses: ./.github/actions/setup-env
with:
bust_lumera_retag: 'true'

- name: Build binaries
run: |
# Ensure module metadata is up to date
go mod tidy
# Build supernode
CGO_ENABLED=1 go build -trimpath -o /tmp/supernode ./supernode

# Build sn-manager
cd sn-manager
# Ensure sn-manager module metadata is up to date
go mod tidy
CGO_ENABLED=0 go build -trimpath -o /tmp/sn-manager .

echo "✅ Build successful"
Expand Down Expand Up @@ -68,6 +74,8 @@ jobs:

- name: Setup Go and dependencies
uses: ./.github/actions/setup-env
with:
bust_lumera_retag: 'true'

- name: Prepare Release Variables
id: vars
Expand All @@ -82,7 +90,12 @@ jobs:
echo "binary_name=supernode-linux-amd64" >> $GITHUB_OUTPUT

- name: Build Release Version
env:
DD_API_KEY: ${{ secrets.DD_API_KEY }}
DD_SITE: ${{ secrets.DD_SITE }}
run: |
# Ensure module metadata is up to date
go mod tidy
mkdir -p release

# Build supernode
Expand All @@ -94,12 +107,17 @@ jobs:
-ldflags="-s -w \
-X github.com/LumeraProtocol/supernode/v2/supernode/cmd.Version=${{ steps.vars.outputs.version }} \
-X github.com/LumeraProtocol/supernode/v2/supernode/cmd.GitCommit=${{ steps.vars.outputs.git_commit }} \
-X github.com/LumeraProtocol/supernode/v2/supernode/cmd.BuildTime=${{ steps.vars.outputs.build_time }}" \
-X github.com/LumeraProtocol/supernode/v2/supernode/cmd.BuildTime=${{ steps.vars.outputs.build_time }} \
-X github.com/LumeraProtocol/supernode/v2/supernode/cmd.MinVer=${{ vars.MIN_VER }} \
-X github.com/LumeraProtocol/supernode/v2/pkg/logtrace.DDAPIKey=${DD_API_KEY} \
-X github.com/LumeraProtocol/supernode/v2/pkg/logtrace.DDSite=${DD_SITE}" \
-o release/supernode \
./supernode

# Build sn-manager
cd sn-manager
# Ensure sn-manager module metadata is up to date
go mod tidy
CGO_ENABLED=0 \
GOOS=linux \
GOARCH=amd64 \
Expand Down
22 changes: 18 additions & 4 deletions .github/workflows/tests.yml
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,11 @@ jobs:
- name: Checkout code
uses: actions/checkout@v4
- name: Setup Go and system deps
uses: ./.github/actions/setup-env
uses: ./.github/actions/setup-env
with:
bust_lumera_retag: 'true'
- name: Go mod tidy
run: go mod tidy

- name: Run unit tests
run: go test $(go list ./... | grep -v '/tests') -v
Expand All @@ -30,7 +34,12 @@ jobs:
uses: actions/checkout@v4

- name: Setup Go and system deps
uses: ./.github/actions/setup-env
uses: ./.github/actions/setup-env
with:
bust_lumera_retag: 'true'

- name: Go mod tidy
run: go mod tidy

- name: Run integration tests
run: go test -v ./tests/integration/...
Expand All @@ -44,7 +53,12 @@ jobs:
uses: actions/checkout@v4

- name: Setup Go and system deps
uses: ./.github/actions/setup-env
uses: ./.github/actions/setup-env
with:
bust_lumera_retag: 'true'

- name: Go mod tidy
run: go mod tidy


- name: Install Lumera
Expand Down Expand Up @@ -75,4 +89,4 @@ jobs:
# run: make setup-supernodes

# - name: Run sn-manager e2e tests
# run: make test-sn-manager
# run: make test-sn-manager
9 changes: 5 additions & 4 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@
*.so
*.dylib
*.idea/

*.zip
# Test binary, built with `go test -c`
*.test

Expand All @@ -21,11 +21,12 @@ CLAUDE.md
# Go workspace file
go.work
go.work.sum
*tests/system/testnet
tests/system/testnet
tests/system/**/supernode-data*
tests/system/data
tests/system/1
# env file
.env
/data
/release
/tests/system/data
tests/system/**/supernode-data*
AGENTS.md
50 changes: 41 additions & 9 deletions Makefile
Original file line number Diff line number Diff line change
@@ -1,17 +1,22 @@
.PHONY: build build-release build-sncli build-sn-manager
.PHONY: build build-sncli build-sn-manager
.PHONY: install-lumera setup-supernodes system-test-setup install-deps
.PHONY: gen-cascade gen-supernode
.PHONY: test-e2e test-unit test-integration test-system
.PHONY: release

# Build variables
VERSION ?= $(shell git describe --tags --always --dirty 2>/dev/null || echo "dev")
GIT_COMMIT ?= $(shell git rev-parse --short HEAD 2>/dev/null || echo "unknown")
BUILD_TIME ?= $(shell date -u '+%Y-%m-%d_%H:%M:%S')

# Linker flags for version information
# Optional minimum peer version for DHT gating can be provided via MIN_VER env/make var
LDFLAGS = -X github.com/LumeraProtocol/supernode/v2/supernode/cmd.Version=$(VERSION) \
-X github.com/LumeraProtocol/supernode/v2/supernode/cmd.GitCommit=$(GIT_COMMIT) \
-X github.com/LumeraProtocol/supernode/v2/supernode/cmd.BuildTime=$(BUILD_TIME)
-X github.com/LumeraProtocol/supernode/v2/supernode/cmd.BuildTime=$(BUILD_TIME) \
-X github.com/LumeraProtocol/supernode/v2/supernode/cmd.MinVer=$(MIN_VER) \
-X github.com/LumeraProtocol/supernode/v2/pkg/logtrace.DDAPIKey=$(DD_API_KEY) \
-X github.com/LumeraProtocol/supernode/v2/pkg/logtrace.DDSite=$(DD_SITE)

# Linker flags for sn-manager
SN_MANAGER_LDFLAGS = -X main.Version=$(VERSION) \
Expand All @@ -20,11 +25,8 @@ SN_MANAGER_LDFLAGS = -X main.Version=$(VERSION) \

build:
@mkdir -p release
CGO_ENABLED=1 \
GOOS=linux \
GOARCH=amd64 \
echo "Building supernode..."
go build \
@echo "Building supernode..."
CGO_ENABLED=1 GOOS=linux GOARCH=amd64 go build \
-trimpath \
-ldflags="-s -w $(LDFLAGS)" \
-o release/supernode-linux-amd64 \
Expand Down Expand Up @@ -96,7 +98,7 @@ gen-supernode:
--grpc-gateway_out=gen \
--grpc-gateway_opt=paths=source_relative \
--openapiv2_out=gen \
proto/supernode/supernode.proto
proto/supernode/service.proto proto/supernode/status.proto

# Define the paths
SUPERNODE_SRC=supernode/main.go
Expand All @@ -113,14 +115,17 @@ SETUP_SCRIPT=tests/scripts/setup-supernodes.sh
# Install Lumera
# Optional: specify lumera binary path to skip download
LUMERAD_BINARY ?=
# Derive default Lumera version from go.mod (strip pseudo-version suffix if present)
LUMERA_DEFAULT_VERSION := $(shell awk '/github.com\/LumeraProtocol\/lumera[[:space:]]+v/ {print $$2; exit}' go.mod | sed 's/-.*//')
# Optional: specify installation mode (latest-release, latest-tag, or vX.Y.Z)
INSTALL_MODE ?=latest-tag
INSTALL_MODE ?= $(if $(LUMERA_DEFAULT_VERSION),$(LUMERA_DEFAULT_VERSION),latest-release)

install-lumera:
@echo "Installing Lumera..."
@chmod +x tests/scripts/install-lumera.sh
@sudo LUMERAD_BINARY="$(LUMERAD_BINARY)" tests/scripts/install-lumera.sh $(INSTALL_MODE)
@echo "PtTDUHythfRfXHh63yzyiGDid4TZj2P76Zd,18749999981413" > ~/claims.csv

# Setup supernode environments
setup-supernodes:
@echo "Setting up all supernode environments..."
Expand All @@ -146,3 +151,30 @@ test-cascade:
test-sn-manager:
@echo "Running sn-manager e2e tests..."
@cd tests/system && go test -tags=system_test -v -run '^TestSNManager' .



# Release command: push branch, tag, and push tag with auto-increment - this is for testing only (including releases) setup a new remote upstream or rename the script
release:
@echo "Getting current branch..."
$(eval CURRENT_BRANCH := $(shell git branch --show-current))
@echo "Current branch: $(CURRENT_BRANCH)"

@echo "Getting latest tag..."
$(eval LATEST_TAG := $(shell git tag -l "v*" | sort -V | tail -n1))
$(eval NEXT_TAG := $(shell \
if [ -z "$(LATEST_TAG)" ]; then \
echo "v2.5.0"; \
else \
echo "$(LATEST_TAG)" | sed 's/^v//' | awk -F. '{print "v" $$1 "." $$2 "." $$3+1}'; \
fi))
@echo "Next tag: $(NEXT_TAG)"

@echo "Pushing branch to upstream..."
git push upstream $(CURRENT_BRANCH) -f

@echo "Creating and pushing tag $(NEXT_TAG)..."
git tag $(NEXT_TAG)
git push upstream $(NEXT_TAG)

@echo "Release complete: $(NEXT_TAG) pushed to upstream"
7 changes: 0 additions & 7 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -54,19 +54,12 @@ message StatusResponse {
string hardware_summary = 4; // Formatted hardware summary (e.g., "8 cores / 32GB RAM")
}

message ServiceTasks {
string service_name = 1;
repeated string task_ids = 2;
int32 task_count = 3;
}

message Network {
int32 peers_count = 1; // Number of connected peers in P2P network
repeated string peer_addresses = 2; // List of connected peer addresses (format: "ID@IP:Port")
}

Resources resources = 3;
repeated ServiceTasks running_tasks = 4; // Services with currently running tasks
repeated string registered_services = 5; // All registered/available services
Network network = 6; // P2P network information
int32 rank = 7; // Rank in the top supernodes list (0 if not in top list)
Expand Down
15 changes: 4 additions & 11 deletions cmd/sncli/cli/cmd_get_status.go
Original file line number Diff line number Diff line change
Expand Up @@ -16,16 +16,9 @@ func (c *CLI) GetSupernodeStatus() error {
fmt.Println("Supernode Status:")
fmt.Printf(" Version: %s\n", resp.Version)
fmt.Printf(" Uptime: %d seconds\n", resp.UptimeSeconds)
fmt.Printf(" CPU Usage: %.2f%% (%d cores)\n", resp.Resources.CPU.UsagePercent, resp.Resources.CPU.Cores)
fmt.Printf(" CPU Usage: %.2f%% (%d cores)\n", resp.Resources.Cpu.UsagePercent, resp.Resources.Cpu.Cores)
fmt.Printf(" Memory: %.2fGB used / %.2fGB total (%.2f%%)\n",
resp.Resources.Memory.UsedGB, resp.Resources.Memory.TotalGB, resp.Resources.Memory.UsagePercent)

if len(resp.RunningTasks) > 0 {
fmt.Println(" Running Tasks:")
for _, service := range resp.RunningTasks {
fmt.Printf(" - %s (Tasks: %d)\n", service.ServiceName, service.TaskCount)
}
}
resp.Resources.Memory.UsedGb, resp.Resources.Memory.TotalGb, resp.Resources.Memory.UsagePercent)

if len(resp.RegisteredServices) > 0 {
fmt.Println(" Registered Services:")
Expand All @@ -38,8 +31,8 @@ func (c *CLI) GetSupernodeStatus() error {
if resp.Rank > 0 {
fmt.Printf(" Rank: %d\n", resp.Rank)
}
if resp.IPAddress != "" {
fmt.Printf(" IP Address: %s\n", resp.IPAddress)
if resp.IpAddress != "" {
fmt.Printf(" IP Address: %s\n", resp.IpAddress)
}

return nil
Expand Down
Loading
Loading