Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

NAS-128546 / 24.10 / Improvements requested by UI team for new enclosure.dashboard #13622

Merged
merged 2 commits into from Apr 26, 2024

Conversation

yocalebo
Copy link
Contributor

The UI team is currently implementing the changes required to consume webui.enclosure.dashboard but they're missing some key items that make it awkward to deal with on their side. This does 3 primary things:

  1. add drive_bay_number key to webui.enclosure.dashboard
  2. add drive_bay_number and id keys to disk.get_unused
  3. use device.get_disks in disk.get_unused instead of querying the disk table. The reason why we don't query the database table is because we have seen various edge-cases where disks are updated in kernel but our database doesn't get updated. This is hard to predict and is even harder to properly handle. The kernel already "caches" the disk info that we need so device.get_disks goes directly to the source of truth. This method has been optimized tremendously and has been proven to perform tolerably compared to querying the db.

@yocalebo yocalebo requested a review from a team April 26, 2024 12:08
@bugclerk bugclerk changed the title Improvements requested by UI team for new enclosure.dashboard NAS-128546 / 24.10 / Improvements requested by UI team for new enclosure.dashboard Apr 26, 2024
@bugclerk
Copy link
Contributor

@yocalebo yocalebo merged commit 6bc1d37 into master Apr 26, 2024
2 checks passed
@yocalebo yocalebo deleted the NAS-128546 branch April 26, 2024 12:57
@bugclerk
Copy link
Contributor

This PR has been merged and conversations have been locked.
If you would like to discuss more about this issue please use our forums or raise a Jira ticket.

@truenas truenas locked as resolved and limited conversation to collaborators Apr 26, 2024
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
3 participants