-
-
Notifications
You must be signed in to change notification settings - Fork 4.2k
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
Add missing instrumentation for compilation/lookup phase #15085
Add missing instrumentation for compilation/lookup phase #15085
Conversation
52628b3
to
99cca3e
Compare
…efined definition
return this._definitionCache.get({ name, source, owner }); | ||
let definition = this._definitionCache.get({ name, source, owner }); | ||
if (definition) { | ||
definition.finalizer = finalizer; |
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.
@mixonic notes that this may not work as expected if the same component is used multiple times.
definition.finalizer = finalizer; | ||
} else { | ||
finalizer(); | ||
} |
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.
It's not clear that two control flows (with and without definition
) are being weighed the same way. @rwjblue suggests always calling the finalizer at the end of the is method, and changing the instrumentation identifier to something more specific like 'render.getComponentDefinition'
and then add other separate instrumentations for other parts of the code.
Just pushed changes based on feedback from Merge Party at EmberConf |
@mmun are you good with the improvements? |
@mmun @stefanpenner awesome, thanks! |
Opening this for further discussion and feedback. Aims to fix #14974
cc: @paddyobrien @ghedamat