gear
gear copied to clipboard
refactor(gtest): make gtest thread safe
the arch of gtest was forced to be synchronous since gear_lazy_pages should only be initialized for once ( if I'm not mistaken ), however since we have already checked the re-init problem at System::new, we actually can replace the lifetimes in the ExtManager related stuffs with smart pointers + locks to make gtest thread safe and more modular, for use case, see #4016
API Changes
since
std::sync::RwLockwill introduce error handling logic, so this PR usesparking_lot::RwLockinstead so there's no api changes in the instance methods
- lifetimes are removed
@gear-tech/dev