Sometimes you want to use one ember controller from another, This simply can be done by “asking” ember access to the other controller:

App.PostController = Ember.ArrayController.extend({
    ...
})

App.CommentsController = Ember.ArrayController.extend({
  needs: "post"
});

Then you can simply use the Post controller in Comments’s template:

{% raw %}

<!-- use comments template -->
{{ controllers.post }}

{% endraw %}

This works pretty nice, especially when you have nested routes (you surely want to display some data of the post when you are in the post’s comments context.),

But what if you need to access a controller outside of Ember’s scope?

For instance, you may have a websocket listening to a certain top level event and would like to update a certian controller when data is pushed,

You can use the container lookup to retrieve a controller instance:

// Somewhere out of Ember`s scope
ss.event.on('incomingComment', function(comment) {
    commentsController = App.__container__.lookup('controller:Comments')
    commentsController.pushObject(comment)
})