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

_debugContainerKey should be a hash that has more contextual data #10742

Closed
igorT opened this issue Mar 28, 2015 · 11 comments
Closed

_debugContainerKey should be a hash that has more contextual data #10742

igorT opened this issue Mar 28, 2015 · 11 comments

Comments

@igorT
Copy link
Member

igorT commented Mar 28, 2015

Something like

{ namespace: ...,
  type: ....
  name: ....
}

This would enable ED to get rid of typeKey and just look up the modelName through the _debugContainerKey

cc @stefanpenner @fivetanley

@stefanpenner
Copy link
Member

someone should flesh this out as an RFC

@teddyzeenny
Copy link
Contributor

The Ember Inspector uses this. It's a breaking change, I should update it to support the new format before/when we commit this change. The inspector would also benefit from this since we're currently parsing the value ourselves 👍

@rwjblue
Copy link
Member

rwjblue commented Mar 28, 2015

I am also in favor, but it will need to be done behind a feature flag to help us ensure that all tooling is ready to go.

I do not think this needs to be an RFC, since it will still be considered private API (and is underscored as such already).

@igorT
Copy link
Member Author

igorT commented Mar 30, 2015

Private but used by ED

@hemp
Copy link

hemp commented Mar 31, 2015

I know this property is internal but it has been so handy to leverage for two items in the app I work on:

  1. Tracking user actions and analytic events for any route, controller, or component as an injected service. The _debugContainerKey turns into a really good category in Google Analytics events. We also reopen Ember.ActionHandler and add the record analytic event into send.
  2. Logging client side errors/warns to something like Logstash/SumoLogic via an API call. We have a logging mixin that provides this.logger.warn()/this.logger.error() and the container will be leveraged there. Ember.Logger is also decorated so log/debug/warn/error methods assume a "general" value for the container key.

In both of these cases the extra data in the hash might be useful 👍

@rwjblue
Copy link
Member

rwjblue commented Aug 10, 2015

I agree, @teddyzeenny / @wycats / any objections to this?

@wycats
Copy link
Member

wycats commented Aug 10, 2015

I am in favor and do not mind making this a public API if fleshed out.

@teddyzeenny
Copy link
Contributor

👍

@fpauser
Copy link
Contributor

fpauser commented Feb 16, 2016

Any news on this?

@rwjblue
Copy link
Member

rwjblue commented Feb 16, 2016

@fpauser - Not really, I think we all generally agree that there is a public API we could make out of this, but it needs to be fleshed out in an RFC and I don't think anyone has had time...

@rwjblue
Copy link
Member

rwjblue commented Apr 13, 2016

Features are generally discussed in the https://github.com/emberjs/rfcs/ repository. You can create an issue there for feature requests or a pull request to propose a new feature. I'm closing this issue (this isn't really a bug in the framework). If someone has the time please follow up with an RFC issue/PR.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

7 participants