title: jsf2 inherited controller with cdi not working - Target Unreachable
body: <p>I have some common properties and functionality in controllers which are sessionscoped like following </p>
  
  <pre><code>@Named
  @SessionScoped
  public class DemoController implements Serializable {
  
   ...
  }
  </code></pre>
  
  <p>This works properly, in the jsf where I do</p>
  
  <pre><code>&lt;f:viewParam name="lang" vlaue="#{demoController.language}" /&gt;
  </code></pre>
  
  <p>But when I move some common properties to a BaseBase controller .. and do like this </p>
  
  <pre><code>@Named
  @SessionScoped
  public class DemoController extends BaseController {
  
   ...
  }
  </code></pre>
  
  <p>I immediately get </p>
  
  <pre><code>javax.el.PropertyNotFoundException: Target Unreachable, identifier 'demoController' resolved to null
  </code></pre>
  
  <p>Is it not possible to inherit ManagedBeans like this ? I have other cdi beans which are inherited and @injected, they work properly. </p>
  
  <p><em>EDIT</em></p>
  
  <p>Here is the code for BaseController</p>
  
  <pre><code>public class BaseController implements Serializable {
  
      private static final long serialVersionUID = -7581824370592944659L;
  
      protected String language;
  
      @Inject
      protected SessionsUtil sessionsUtil;
  
      public String getLanguage () {
  
          return language;
      }
  
      public void setLanguage (String language) {
  
          this.language = language;
      }
  
      public void init() {
  
          if (null != language) {
  
              sessionsUtil.switchLanguage(language.toUpperCase());
          }
      }
  }
  </code></pre>
  
  <p>PS: The app is deployed in glassfish 4</p>