[PR #2732] [CLOSED] Add NATURAL_ORDERING opt to disable natsort #12430

Closed
opened 2025-12-29 22:21:32 +01:00 by adam · 0 comments
Owner

📋 Pull Request Information

Original PR: https://github.com/netbox-community/netbox/pull/2732
Author: @aruhier
Created: 12/27/2018
Status: Closed

Base: developHead: opt_natural_ordering


📝 Commits (1)

  • 210ddde Add NATURAL_ORDERING opt to disable natsort

📊 Changes

4 files changed (+21 additions, -3 deletions)

View changed files

📝 docs/configuration/optional-settings.md (+9 -0)
📝 netbox/dcim/models.py (+6 -3)
📝 netbox/netbox/configuration.example.py (+5 -0)
📝 netbox/netbox/settings.py (+1 -0)

📄 Description

Fixes:

With a lot of objects, the sort query took more than 2s to complete, each time they were listed. Making the concession to disable natural ordering sort reduces this time to 0.1s, making the listing views and homepage snappier in our case.

Add an option to disable or not the natural ordering sort in Netbox for the DCIM models.


🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.

## 📋 Pull Request Information **Original PR:** https://github.com/netbox-community/netbox/pull/2732 **Author:** [@aruhier](https://github.com/aruhier) **Created:** 12/27/2018 **Status:** ❌ Closed **Base:** `develop` ← **Head:** `opt_natural_ordering` --- ### 📝 Commits (1) - [`210ddde`](https://github.com/netbox-community/netbox/commit/210ddde630b7df64fdebd44ee621f1c9733e2305) Add NATURAL_ORDERING opt to disable natsort ### 📊 Changes **4 files changed** (+21 additions, -3 deletions) <details> <summary>View changed files</summary> 📝 `docs/configuration/optional-settings.md` (+9 -0) 📝 `netbox/dcim/models.py` (+6 -3) 📝 `netbox/netbox/configuration.example.py` (+5 -0) 📝 `netbox/netbox/settings.py` (+1 -0) </details> ### 📄 Description ### Fixes: With a lot of objects, the sort query took more than 2s to complete, each time they were listed. Making the concession to disable natural ordering sort reduces this time to 0.1s, making the listing views and homepage snappier in our case. Add an option to disable or not the natural ordering sort in Netbox for the DCIM models. --- <sub>🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.</sub>
adam added the pull-request label 2025-12-29 22:21:32 +01:00
adam closed this issue 2025-12-29 22:21:32 +01:00
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: starred/netbox#12430