You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Replace if-elif chain with dictionary lookup for scheduling policy
determination. This change eliminates repeated string comparisons
during scheduler initialization and improves code maintainability
by centralizing policy mapping logic.
Changes:
- Add _POLICY_MAPPING class attribute for O(1) policy lookup
- Replace conditional chain with single dictionary access
- Maintain identical error handling for unknown policies
Performance impact: Reduces scheduler initialization overhead,
especially beneficial in multi-engine scenarios.
0 commit comments