Skip to content
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

Do not require static registration #85

Closed
jbogard opened this issue Sep 2, 2011 · 2 comments
Closed

Do not require static registration #85

jbogard opened this issue Sep 2, 2011 · 2 comments

Comments

@jbogard
Copy link
Member

jbogard commented Sep 2, 2011

evoskuil[CodePlex]
It appears that there is no way to register mappings without providing a reference to the static MapperRegistry. While a static wrapper around non-static registration, as a helper, would be fine, the requirement for static registration is problematic - even if the implementation is actually thread safe. When unit testing static state in general is bad as it spans individual tests, corrupting those tests. Additionally, while the self-test method on AutoMapper is cool, it is also a static method (which in turn relies on static registration). This is also bad in that unit tests executing concurrently are sharing state, and thread safety doesn't resolve the resulting cross-test corruption. It would be *much* better for AutoMapper to be fully non-static apart from optional helpers.

@jbogard
Copy link
Member Author

jbogard commented Nov 4, 2011

Not required any more.

@jbogard jbogard closed this as completed Nov 4, 2011
@lock
Copy link

lock bot commented May 8, 2019

This thread has been automatically locked since there has not been any recent activity after it was closed. Please open a new issue for related bugs.

@lock lock bot locked as resolved and limited conversation to collaborators May 8, 2019
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant