-
Notifications
You must be signed in to change notification settings - Fork 248
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
[Core][MappingApplication] Make MapperFactory use Registry #12542
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Okay from my side, maybe we should wait for @philbucher approval
return std::string("mappers.all.mpi"); | ||
} | ||
return std::string("mappers.all"); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
those names are only internally used in the registry right? I.e. nothing the user has to deal with?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The users of MapperFactory should be able to continue interacting with it as usual. One could get the mappers directly form the registry using those paths, but this is not used at the moment.
Sorry, I forgot to remove some debug messages |
📝 Description
Refactoring the MapperFactory in order to use the Registry infrastructure instead of its internal registered_mappers list.
The motivation for the change is related to the new gtests and the need to load application dependencies dynamically. Consider a test suite that loads MappingApplication as a runtime dependency (because the tested application does not have compile-time dependencies to it and does not link to it)
3.1 Mappers registered in MapperFactory on each test start (when the test suite imports its dependencies in the kernel)
3.2 Test run
3.3 Applications de-registered
If the MapperFactory uses the registry instead, mappers are automatically registered when MapperApplication is de-registered in 3.3, so the deallocation in 5 is no longer a problem.
🆕 Changelog