title: JSF Deploy Exception: Unsatisfied dependencies for type EntityManager
body: <p>I just followed the ticket-monster tutorial(<a href="http://www.jboss.org/jdf/examples/ticket-monster/tutorial/Introduction/" rel="noreferrer">http://www.jboss.org/jdf/examples/ticket-monster/tutorial/Introduction/</a>) and added a rest-service class to my solution.</p>
  
  <pre><code>package projectFoo.rest;
  import java.util.List;
  import javax.enterprise.context.RequestScoped;
  import javax.inject.Inject;
  import javax.persistence.EntityManager;
  import javax.ws.rs.GET;
  import javax.ws.rs.Path;
  import javax.ws.rs.Produces;
  import javax.ws.rs.core.MediaType;
  
  import projectFoo.model.party;
  
  
  @Path("/partys")
  @RequestScoped
  public class partyService {
  
  @Inject
  private EntityManager em;
  
  @GET
  @Produces(MediaType.APPLICATION_JSON)
   public List&lt;party&gt; getAllEvents() {
      @SuppressWarnings("unchecked")
      final List&lt;party&gt; results =
              em.createQuery(
              "select e from party e order by e.name").getResultList();
      return results;
  }
  }
  </code></pre>
  
  <p>@Inject is underlined, returning: <strong>"No bean is eligible for injection to the injection point [JSR-299 §5.2.1]"</strong></p>
  
  <p>When I try to deploy the package, the process will fail and return the following message:</p>
  
  <pre><code>Unsatisfied dependencies for type [EntityManager] with qualifiers [@Default] at injection point.
  </code></pre>
  
  <p>Do I have to add a bean for the Entity Manager? How should this one look like? The tutorial doesn't mention this. Actually I couldn't find any definition of beans in the final ticket-monster project.</p>