title: JMSSerializerBundle how serializer data , Call to a member function get() on a non-object
body: <p>I try use JMSSerializerBundle I updated my composer, added bundle in my AppKernel. 
  And I writed this</p>
  
  <pre><code>namespace Surgery\PatientBundle\Controller;
  
  use Symfony\Bundle\FrameworkBundle\Controller\Controller;
  
  
  class VisitsController extends Controller{
  
      public function testAction()
      {       
          $arr = array ('a'=&gt;1,'b'=&gt;2,'c'=&gt;3,'d'=&gt;4,'e'=&gt;5);
          $serializer = $container-&gt;get('jms_serializer');
          $serializer-&gt;serialize($arr, 'json');
  </code></pre>
  
  <p>And i get this </p>
  
  <pre><code>Call to a member function get() on a non-object
  </code></pre>
  
  <p>Any idea what I did wrong or I did't ?</p>