0 Replies Latest reply on Mar 14, 2018 9:05 AM by Hans-Michael Rupp

    JSF Web Application Wildfly 10 Unknown entity

    Hans-Michael Rupp Novice



      I am trying to build a simple JSF application which saves data entered by the user

      I inject a bean which has been instantiated by a jsf page into a controller and try to persist it from the controller.

      I get a

      2018-03-14 13:41:04,129 ERROR [org.jboss.as.ejb3.invocation] (default task-13) WFLYEJB0034: EJB Invocation failed on component NewsletterDAOBean for method public java.lang.Object de.rupp.persistence.AbstractDAOBean.save(java.lang.Object): javax.ejb.EJBException: java.lang.IllegalArgumentException: Unknown entity: de.rupp.newsletter.NewsletterData$Proxy$_$$_WeldClientProxy




      public class NewsletterData implements Serializable {
          private Long id;
          private String email;
          private boolean agbChecked;
          public String getEmail() {
              return email;
          public void setEmail(String email) {
              this.email = email;
          public boolean isAgbChecked() {
              return agbChecked;
          public void setAgbChecked(boolean agbChecked) {
              this.agbChecked = agbChecked;
          public String toString() {
              return "NewsletterData [id=" + id + ", email=" + email + ", agbChecked=" + agbChecked + "]";


      public class NewsletterController implements Serializable {
          private NewsletterData newsletterData;
          private NewsletterDAOBean newsletterDAOBean;
          public String checkAGBs() {
              if (this.newsletterData.isAgbChecked()) {
                  return "lastPage";
              FacesContext.getCurrentInstance().addMessage(null, new FacesMessage("Bitte akzeptieren Sie die AGBs"));
              return null;




      -> NewsletterData [id=null, email=h.rupp@bla.de, agbChecked=true]


      My persistence DAO works. I have written an Arquillian Test which saves a new NewsletterData.

      I use em.persist


      Any ideas would be greatly appreciated.