Spectranet demo#32
Closed
Ninjabippo1205 wants to merge 2 commits into
Closed
Conversation
…tranet-demo)
libe3's JSON encoder spoke snake_case keys with hex-string payloads
(dapp_identifier, protocol_data, ...), while the aerial dApp ecosystem
(NVIDIA aerial sample-apps and the spectranet dApps) speaks camelCase
with nested-JSON payloads (ranFunctionIdentifier, protocolData: {...}).
A JSON RAN agent built from main therefore could not interoperate with
those dApps.
Port the JSON encoder end-state from the spectranet-demo branch
(686ba11, 4ec3cb0, ea62ba9, af826b4, fc6284b, 5dbacba squashed; no
runtime dual-encoding, no core changes):
- camelCase keys + camelCase PDU type strings (PascalCase rejected)
- flat envelope: payload fields at root next to type/id/timestamp;
messages with a "data" wrapper are rejected
- JSON-object payloads carried inline; binary payloads as hex with a
sentinel; plain hex-string actionData accepted (aerial 19f9bd3 sends
that shape)
- string_to_pdu_type returns std::optional; unknown PDU types fail
decode instead of defaulting
types.hpp gains the optional wire fields the dialect carries:
SetupResponse.message, SubscriptionResponse{ran_function_identifier,
telemetry_granted_list, control_granted_list, periodicity_us, message},
IndicationMessage.subscription_id. All are optional/empty by default,
not populated by the core, and skipped on the wire when absent (the
aerial dApp reads them conditionally). Core construction sites all use
member assignment, so the layout change is source-compatible.
test_json_encoder.cpp ports the dialect's test suite (21 cases);
test_types.cpp aligns the encoder-default assertion with types.hpp's
ASN1-first precedence so the suite holds when both encoders are
compiled in.
Verified standalone: json_encoder TU compiles against these headers
(-std=c++17) and the 21-test suite passes; E3Config_defaults passes
with both LIBE3_ENABLE_ASN1 and LIBE3_ENABLE_JSON defined.
…-encoding lineage spectranet-demo now tracks main + the aerial JSON dialect (fa187a0), replacing the runtime dual-encoding lineage (old tip aa46f6b). Document what the old lineage contained — per-commit, with re-implementation notes — since its last six commits lose their ref with this rewrite (the rest stays reachable via aerial-oai-integration), and map the relation to the json-format branch.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Type of change
Linked issue
Closes #
Mandatory test checklist
These mirror what CI (
.github/workflows/pr-tests.yml) enforces. All boxes must be ticked before review../build_libe3 -c -d build -j $(nproc) -r -tpasses (Release build + tests)./build_libe3 -c -d build -j $(nproc) -g -tpasses (Debug build + tests)cd build && ctest --output-on-failureis clean./build/test_bench_mpmc_queue) shows no regression vsmainVERSIONbumped per SemVer if the public API or ABI changedinclude/were touched,./build_libe3 --docsrenders without new Doxygen warnings./build_libe3 -I(update the script if needed)libe3.pcinterface changed, downstream consumers (dApp-openairinterface5g) still link cleanlyCI checklist
Unit Testsworkflow is green (Debug + Release matrix onubuntu-latest)MPMC Queue Benchmarkjob has posted results to this PR with no regressionTwin-repo coordination
libe3 is paired with
dappsanddApp-openairinterface5g. We do not accept patches that break or reduce compatibility with the twin repositories.Paired PR(s):
Workflow confirmation
CONTRIBUTING.md§ Pull Request Process.)CONTRIBUTING.md.