Skip to content

feat: Add slot number and tray index for switch machine from RMS#807

Merged
chet merged 1 commit intoNVIDIA:mainfrom
vinodchitraliNVIDIA:vc/physical
Apr 13, 2026
Merged

feat: Add slot number and tray index for switch machine from RMS#807
chet merged 1 commit intoNVIDIA:mainfrom
vinodchitraliNVIDIA:vc/physical

Conversation

@vinodchitraliNVIDIA
Copy link
Copy Markdown
Contributor

@vinodchitraliNVIDIA vinodchitraliNVIDIA commented Apr 3, 2026

Added location field to Machine, Switch, PowerShelf, and Rack — dedicated VARCHAR(256) columns in DB tables

Site explorer wires location from config to entity from RMS

Description

Type of Change

  • Add - New feature or capability
  • Change - Changes in existing functionality
  • Fix - Bug fixes
  • Remove - Removed features or deprecated functionality
  • Internal - Internal changes (refactoring, tests, docs, etc.)

Related Issues (Optional)

Breaking Changes

  • This PR contains breaking changes

Testing

  • Unit tests added/updated
  • Integration tests added/updated
  • Manual testing performed
  • No testing required (docs, internal refactor, etc.)

Additional Notes

@vinodchitraliNVIDIA vinodchitraliNVIDIA requested a review from a team as a code owner April 3, 2026 20:35
@github-actions
Copy link
Copy Markdown

github-actions Bot commented Apr 3, 2026

🔐 TruffleHog Secret Scan

No secrets or credentials found!

Your code has been scanned for 700+ types of secrets and credentials. All clear! 🎉

🔗 View scan details

🕐 Last updated: 2026-04-03 20:37:17 UTC | Commit: 2248bb7

@Matthias247
Copy link
Copy Markdown
Contributor

we should clarify what location is. Because by just looking at the code, its unclear whether this is a slot_id or something like "datahall 5 row 10 place 4".
Ideally we give it a more descriptive name, based on what we want to do with it. E.g. if we want to check traying ordering against what is encoded in expected-machines, it should probably be the slot-id/tray-index/etc

@zhaozhongn
Copy link
Copy Markdown

Core will not get these data via RMS only. In the long-term it will be via the component manager API interface so ANY plugins to Core could be able to provide such info. In the short-term, if it is not done this way, it will be by Core accessing NVOS and BMC directly as happened in endpoint exploration today for other similar info.

@vinodchitraliNVIDIA vinodchitraliNVIDIA force-pushed the vc/physical branch 6 times, most recently from ace0336 to e9ca46a Compare April 9, 2026 18:33
@vinodchitraliNVIDIA vinodchitraliNVIDIA changed the title feat: Add tray location for switch machine powershelf from RMS feat: Add slot number and tray index for switch machine from RMS Apr 9, 2026
@vinodchitraliNVIDIA vinodchitraliNVIDIA force-pushed the vc/physical branch 2 times, most recently from 1e451e0 to 3532604 Compare April 10, 2026 14:50
@vinodchitraliNVIDIA vinodchitraliNVIDIA requested a review from a team as a code owner April 10, 2026 14:50
Comment thread .github/workflows/ci.yaml Outdated
Comment thread crates/api-db/migrations/20260403132222_add_location.sql
Comment thread crates/api-db/migrations/20260403132222_add_location.sql
let machine_data = expected_machine.map(|em| &em.data);
let mut managed_host = ManagedHost::init(explored_host);

let bmc_credentials = if let Some(expected) = expected_machine
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.

There's a lot of boilerplate here, e.g. in order to use the RMS client we need to look up the BMC credentials manually for each call at callsite.

It would be much nicer if it internally loads credentials just as the libredfish integration does.

Comment thread crates/rpc/proto/forge.proto
@vinodchitraliNVIDIA vinodchitraliNVIDIA force-pushed the vc/physical branch 8 times, most recently from 749c12d to e234db6 Compare April 13, 2026 11:19
Signed-off-by: Vinod Chitrali <vchitrali@nvidia.com>
@chet chet merged commit 45dbc25 into NVIDIA:main Apr 13, 2026
44 checks passed
<tr>
<th>Location</th>
<td>{{ location }}</td>
<th>Slot Number</th>
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.

we can create a sub-template for this that renders things consistently across types. Similar to how @chet did it with metadata_details.html.

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.

4 participants