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
Add thread-safe static cache for ConfigFile instances
- Introduced a static list `AllConfigFiles` to cache all `ConfigFile` instances created during runtime.
- Exposed a read-only `AllConfigFilesReadOnly` property of type `IReadOnlyList<ConfigFile>` for external read-only access.
- Synchronized all access to `AllConfigFiles` using a dedicated `lock` object (`LockObject`) to ensure thread safety.
- Ensured consistent access to the `AllConfigFiles` collection, preventing race conditions and concurrent modification issues.
- Updated XML documentation to reflect changes and provide additional usage guidelines for `AllConfigFilesReadOnly`.
/// This property is thread-safe for read access. Any modifications to the internal collection should be done through the <see cref="AllConfigFiles"/> field.
0 commit comments