Ember - How to share singletons between controllers
===

I have a service which fetch urls and needs to be created as a singleton with an application specific configuration.

Several of my controllers need to use this service.

How can I create this service in one place, preferably in the application and share it between controllers so they can use it directly?

My modules are divided into different files, using requirejs.


URLService.js

    var urlService = URLService.create({config: {...} })

SomeController.js

    var SomeController = Em.Controller.extend({ 
      service: null
    })

Application:

    App = Em.Application.create({
      SomeController: SomeController  <-- inject the urlService into SomeController.service
    })


Is there a built in way or a best practice of doing this? or am I missing something in the architecture?

Thanks!