Skip to content

RDKEMW-14887 : Update Stats.memoryUsage api to return value in bytes#82

Open
swethasukumarr wants to merge 2 commits into
developfrom
feature/RDKEMW-14887
Open

RDKEMW-14887 : Update Stats.memoryUsage api to return value in bytes#82
swethasukumarr wants to merge 2 commits into
developfrom
feature/RDKEMW-14887

Conversation

@swethasukumarr

Copy link
Copy Markdown
Contributor

No description provided.

Copilot AI 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.

Pull request overview

Updates the Stats.memoryUsage API surface to report memory values in bytes (instead of KiB), aligning the C++ types, JSON parsing, tests, and OpenRPC specs/examples with the new contract.

Changes:

  • Switched Firebolt::Stats::MemoryInfo fields from uint32_t to uint64_t and updated JSON deserialization to read byte-based field names.
  • Updated unit/component tests and the API demo app to validate/display byte-based values and updated field names.
  • Updated OpenRPC specifications (core, legacy, and app schemas) to reflect byte units, new property names, and updated examples.

Reviewed changes

Copilot reviewed 9 out of 9 changed files in this pull request and generated no comments.

Show a summary per file
File Description
test/unit/statsTest.cpp Updates unit assertions to use byte-field names and uint64_t expectations.
test/component/statsTest.cpp Updates component assertions to use byte-field names and uint64_t expectations.
test/api_test_app/apis/statsDemo.cpp Updates demo output strings to explicitly label values as bytes.
src/json_types/stats.h Updates required JSON fields and parsing to userMemoryUsed/userMemoryLimit/gpuMemoryUsed/gpuMemoryLimit as uint64_t.
include/firebolt/stats.h Updates public API struct field types to uint64_t and clarifies bytes in the doc comment.
docs/openrpc/the-spec/firebolt-open-rpc.json Updates Stats.memoryUsage summary, example payload, and schema property names/descriptions to bytes.
docs/openrpc/the-spec/firebolt-open-rpc--legacy.json Mirrors the same bytes/property-name updates for the legacy spec.
docs/openrpc/the-spec/firebolt-app-open-rpc.json Updates the app-facing MemoryInfo schema to byte-based property names and constraints.
docs/openrpc/openrpc/stats.json Updates the module OpenRPC definition (summary, examples, schema) to byte-based fields.

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.

3 participants