Skip to content

Replace deprecated getBuffLength() with getSize() in CfsAppBridge - #21

Merged
LeStarch merged 3 commits into
fprime-community:develfrom
JPL-Devin:devin/1754358000-cfs-tlm-stripper
Aug 5, 2026
Merged

LeStarch merged 3 commits into
fprime-community:develfrom
JPL-Devin:devin/1754358000-cfs-tlm-stripper

Conversation

@lestarch-autobot

@lestarch-autobot lestarch-autobot commented Aug 5, 2026 •

Copy link
Copy Markdown
Contributor

Change Description

Replaces the deprecated Fw::Buffer::getBuffLength() call with getSize() in CfsAppBridge, fixing a -Werror=deprecated-declarations build failure against current F Prime devel.

Note: this PR originally added CfsTlmStripper. Per review discussion, that component is only needed when bridging to F Prime ground operations, so it has moved to fprime-community/fprime_gds#7 (with SDD requirements and requirements-traced UTs).

Rationale

Building the reference against current F Prime devel fails on the deprecated API.

Testing/Review Recommendations

Build fprime_cfs_reference against F Prime devel; verified locally with a full reference build and GDS round trip.

Future Work

None.

…d bridges; replace deprecated getBuffLength()

Co-Authored-By: michael.d.starch <michael.d.starch@jpl.nasa.gov>

@LeStarch LeStarch left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

  1. No UTs, nor requirements. Please add UTs that trace requirements.
  2. This seems to do a reallocate and copy. Just move the data pointer and skip the allocate.

Was this designed with the component development process? If not, please check that process and ensure it is retrofitted in here.

Co-Authored-By: michael.d.starch <michael.d.starch@jpl.nasa.gov>
@lestarch-autobot

Copy link
Copy Markdown
Contributor Author

Review feedback addressed:

  • In-place strip, no allocate/copy: CfsTlmStripper now rebuilds the primary header over the trailing secondary-header bytes and advances the buffer data pointer; the bufferAllocate/bufferDeallocate ports were removed.
  • Requirements + UTs: added a requirements section to the SDD (FPRIMECFS-CFSTLMSTRIPPER-001..007) and requirements-traced unit tests (register_fprime_ut, 6 tests, all passing) covering strip, header rebuild, in-place pointer behavior, command/no-sec-hdr passthrough, malformed drop, buffer return, and com status passthrough.
  • Component process: retrofitted per the component development process (FPP model, SDD with requirements, UTs with REQUIREMENT() tracing).

Revalidated end to end against the reference deployment: telemetry/events decode in the GDS and a CMD_NO_OP round trip completes.

…dges

Co-Authored-By: michael.d.starch <michael.d.starch@jpl.nasa.gov>
@lestarch-autobot lestarch-autobot changed the title Add CfsTlmStripper for ground bridges; replace deprecated getBuffLength() Replace deprecated getBuffLength() with getSize() in CfsAppBridge Aug 5, 2026
@lestarch-autobot

Copy link
Copy Markdown
Contributor Author

Per the review direction, CfsTlmStripper has been moved out of this library into the GDS bridge repo (fprime-community/fprime_gds#7), since it is only needed when bridging to F Prime ground operations. This PR now contains only the deprecated getBuffLength() -> getSize() fix.

@LeStarch
LeStarch merged commit b5ca703 into fprime-community:devel Aug 5, 2026
1 of 2 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants