-->
These old forums are deprecated now and set to read-only. We are waiting for you on our new forums!
More modern, Discourse-based and with GitHub/Google/Twitter authentication built-in.

All times are UTC - 5 hours [ DST ]



Forum locked This topic is locked, you cannot edit posts or make further replies.  [ 2 posts ] 
Author Message
 Post subject: Hibernate Validation Problem (Verständnisfrage)
PostPosted: Mon Nov 05, 2007 3:24 pm 
Newbie

Joined: Mon Nov 05, 2007 3:18 pm
Posts: 2
Hi,

ich bin mir nicht sicher in welches Forum ist dieses Topic posten soll (seam oder hibernate), aber ich denke aufgrund der fehlenden Antworten im Seam forum probier ich es mal hier.

Ich habe ein EntityBean mit einer eigenen Validation geschrieben.
Die Validation überprüft ob es den eingetragenden Wert in der DB gibt.

Soweit so gut. Das Feld in dem EntityBean verweist auf sich selbst (quasi eine Folder struktur).

Hier der Code:

Validator:

Code:
package com.ccm30.validators;

import java.util.List;

import javax.persistence.NoResultException;

import org.hibernate.mapping.Property;
import org.hibernate.validator.PropertyConstraint;
import org.hibernate.validator.Validator;
import org.jboss.seam.Component;
import org.jboss.seam.annotations.Name;
import org.jboss.seam.framework.EntityController;

import com.ccms30.entities.CcmsProductline;
import com.ccms30.entities.CcmsProductlineController;

@Name("myProductlineListValidator")
public class MyProductlineListValidator extends EntityController implements
      Validator<MyProductlineList>, PropertyConstraint  {


   
   // part of the Validator<Annotation> contract,
   // allows to get and use the annotation values
   public void initialize(MyProductlineList parameters) {

   }

   // part of the property constraint contract
   public boolean isValid(Object value) {
      
      if (value == null){
         System.out.println("Value is null");
         return true;
      }
         
      if (!(value instanceof String))
      {
         System.out.println("Value is not a string");
         return false;
      }
         
      String string = (String) value;
      String trimmed = string.trim();
      
      try{
         CcmsProductline cpl = (CcmsProductline) createQuery(
         "select cpl from CcmsProductline cpl where cpl.name=:name")
         .setParameter("name", trimmed).getSingleResult();

         System.out.println("Value is in List");
         return true;
      }catch(NoResultException e)
      {
         System.out.println("Value is not in List");
         return false;
      }

   }

   public void apply(Property arg0) {

   }

}
   


Entity:
Code:
package com.ccms30.entities;
// Generated 16.10.2007 13:32:22 by Hibernate Tools 3.2.0.b9

import java.util.Date;
import java.util.HashMap;
import java.util.HashSet;
import java.util.Set;

import javax.persistence.CascadeType;
import javax.persistence.Column;
import javax.persistence.Entity;
import javax.persistence.FetchType;
import javax.persistence.GeneratedValue;
import javax.persistence.GenerationType;
import javax.persistence.Id;
import javax.persistence.JoinColumn;
import javax.persistence.JoinTable;
import javax.persistence.ManyToMany;
import javax.persistence.ManyToOne;
import javax.persistence.OneToMany;
import javax.persistence.SequenceGenerator;
import javax.persistence.Table;
import javax.persistence.Temporal;
import javax.persistence.TemporalType;
import javax.persistence.Transient;

import org.hibernate.validator.Length;
import org.hibernate.validator.NotNull;
import org.richfaces.model.TreeNode;

import com.ccm30.validators.MyProductlineList;
import com.ccms30.treenodes.CcmsTree;
/**
* CcmsProductline generated by hbm2java
*/
@Entity
@Table(name = "CCMS_PRODUCTLINE", schema = "CCMSDB")
public class CcmsProductline extends CcmsTree implements java.io.Serializable {

   private static final long serialVersionUID = 1L;
   
   private Integer id;
   private CcmsProductline ccmsProductline;
   private CcmsUser ccmsUser;
   private String name;
   private String description;
   private Date modified;
   private Set<CcmsProductline> ccmsProductlines = new HashSet<CcmsProductline>(
         0);
   private Set<CcmsProduct> ccmsProducts = new HashSet<CcmsProduct>(0);
   private Set<CcmsPolicy> ccmsPolicies = new HashSet<CcmsPolicy>(0);
   
   @Transient
   private String ccmsParentProductlineName = initCcmsParentProductlineName();

   public CcmsProductline() {
   }

   public CcmsProductline(Integer id, String name) {
      this.id = id;
      this.name = name;
   }
   public CcmsProductline(Integer id, CcmsProductline ccmsProductline,
         CcmsUser ccmsUser, String name, String description, Date modified,
         Set<CcmsProductline> ccmsProductlines,
         Set<CcmsProduct> ccmsProducts, Set<CcmsPolicy> ccmsPolicies) {
      this.id = id;
      this.ccmsProductline = ccmsProductline;
      this.ccmsUser = ccmsUser;
      this.name = name;
      this.description = description;
      this.modified = modified;
      this.ccmsProductlines = ccmsProductlines;
      this.ccmsProducts = ccmsProducts;
      this.ccmsPolicies = ccmsPolicies;
   }

   @Id @SequenceGenerator(name = "generator", sequenceName = "ID_SEQUENCE")  @GeneratedValue(strategy = GenerationType.SEQUENCE, generator = "generator")
   @Column(name = "ID", unique = true, nullable = false, precision = 22, scale = 0)
   @NotNull
   public Integer getId() {
      return this.id;
   }

   public void setId(Integer id) {
      this.id = id;
   }
   @ManyToOne(fetch = FetchType.LAZY)
   @JoinColumn(name = "PARENT_PRODUCTLINE_ID")
   public CcmsProductline getCcmsProductline() {
      return this.ccmsProductline;
   }

   public void setCcmsProductline(CcmsProductline ccmsProductline) {
      this.ccmsProductline = ccmsProductline;
   }
   @ManyToOne(fetch = FetchType.LAZY)
   @JoinColumn(name = "CREATOR")
   public CcmsUser getCcmsUser() {
      return this.ccmsUser;
   }

   public void setCcmsUser(CcmsUser ccmsUser) {
      this.ccmsUser = ccmsUser;
   }

   @Column(name = "NAME", nullable = false, length = 200)
   @NotNull
   @Length(max = 200)
   public String getName() {
      return this.name;
   }

   public void setName(String name) {
      this.name = name;
   }

   @Column(name = "DESCRIPTION", length = 4000)
   @Length(max = 4000)
   public String getDescription() {
      return this.description;
   }

   public void setDescription(String description) {
      this.description = description;
   }
   @Temporal(TemporalType.DATE)
   @Column(name = "MODIFIED", length = 7)
   public Date getModified() {
      return this.modified;
   }

   public void setModified(Date modified) {
      this.modified = modified;
   }
   @OneToMany(cascade = CascadeType.ALL, fetch = FetchType.LAZY, mappedBy = "ccmsProductline")
   public Set<CcmsProductline> getCcmsProductlines() {
      return this.ccmsProductlines;
   }

   public void setCcmsProductlines(Set<CcmsProductline> ccmsProductlines) {
      this.ccmsProductlines = ccmsProductlines;
   }
   @OneToMany(cascade = CascadeType.ALL, fetch = FetchType.LAZY, mappedBy = "ccmsProductline")
   public Set<CcmsProduct> getCcmsProducts() {
      return this.ccmsProducts;
   }

   public void setCcmsProducts(Set<CcmsProduct> ccmsProducts) {
      this.ccmsProducts = ccmsProducts;
   }
   @ManyToMany(cascade = CascadeType.ALL, fetch = FetchType.LAZY)
   @JoinTable(name = "CCMS_POLICY_PRODUCTLINE_Z", joinColumns = @JoinColumn(name = "policy_id"), inverseJoinColumns = @JoinColumn(name = "productline_id"))
   public Set<CcmsPolicy> getCcmsPolicies() {
      return this.ccmsPolicies;
   }

   public void setCcmsPolicies(Set<CcmsPolicy> ccmsPolicies) {
      this.ccmsPolicies = ccmsPolicies;
   }
   
   public String initCcmsParentProductlineName()
   {
      if(ccmsProductline!=null)
         return ccmsProductline.getName();
      else
         return "";
   }
   

   @Transient
   @MyProductlineList
   public String getCcmsParentProductlineName() {
      System.out.println("operation called");
      return ccmsParentProductlineName;
   }
   
   @Transient
   public void setCcmsParentProductlineName(String ccmsParentProductlineName) {
      this.ccmsParentProductlineName = ccmsParentProductlineName;
   }

   @Override
   public String receiveType() {
      // TODO Auto-generated method stub
      return "CcmsProduct/CcmsProductline";
   }
   
}   


Exception:
Code:
Exception during request processing:
Caused by javax.servlet.ServletException with message: "#{ccmsProductlineHome.persist}: java.lang.reflect.UndeclaredThrowableException"

javax.faces.webapp.FacesServlet.service(FacesServlet.java:256)
org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:290)
org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)
org.jboss.seam.servlet.SeamFilter$FilterChainImpl.doFilter(SeamFilter.java:83)
org.jboss.seam.debug.hot.HotDeployFilter.doFilter(HotDeployFilter.java:68)
org.jboss.seam.servlet.SeamFilter$FilterChainImpl.doFilter(SeamFilter.java:69)
org.jboss.seam.web.MultipartFilter.doFilter(MultipartFilter.java:85)
org.jboss.seam.servlet.SeamFilter$FilterChainImpl.doFilter(SeamFilter.java:69)
org.jboss.seam.web.ExceptionFilter.doFilter(ExceptionFilter.java:64)
org.jboss.seam.servlet.SeamFilter$FilterChainImpl.doFilter(SeamFilter.java:69)
org.jboss.seam.web.RedirectFilter.doFilter(RedirectFilter.java:44)
org.jboss.seam.servlet.SeamFilter$FilterChainImpl.doFilter(SeamFilter.java:69)
org.ajax4jsf.webapp.BaseXMLFilter.doXmlFilter(BaseXMLFilter.java:141)
org.ajax4jsf.webapp.BaseFilter.doFilter(BaseFilter.java:281)
org.jboss.seam.web.Ajax4jsfFilter.doFilter(Ajax4jsfFilter.java:60)
org.jboss.seam.servlet.SeamFilter$FilterChainImpl.doFilter(SeamFilter.java:69)
org.jboss.seam.web.LoggingFilter.doFilter(LoggingFilter.java:58)
org.jboss.seam.servlet.SeamFilter$FilterChainImpl.doFilter(SeamFilter.java:69)
org.jboss.seam.servlet.SeamFilter.doFilter(SeamFilter.java:150)
org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:235)
org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)
com.ccms30.auth.filter.UserAuthentication.doFilter(UserAuthentication.java:37)
org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:235)
org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)
org.jboss.web.tomcat.filters.ReplyHeaderFilter.doFilter(ReplyHeaderFilter.java:96)
org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:235)
org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)
org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:230)
org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:175)
org.jboss.web.tomcat.security.SecurityAssociationValve.invoke(SecurityAssociationValve.java:179)
org.apache.catalina.authenticator.AuthenticatorBase.invoke(AuthenticatorBase.java:433)
org.jboss.web.tomcat.security.JaccContextValve.invoke(JaccContextValve.java:84)
org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:128)
org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:104)
org.jboss.web.tomcat.service.jca.CachedConnectionValve.invoke(CachedConnectionValve.java:157)
org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:109)
org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:241)
org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:844)
org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.process(Http11Protocol.java:580)
org.apache.tomcat.util.net.JIoEndpoint$Worker.run(JIoEndpoint.java:447)
java.lang.Thread.run(Thread.java:595)

Caused by javax.faces.FacesException with message: "#{ccmsProductlineHome.persist}: java.lang.reflect.UndeclaredThrowableException"

com.sun.faces.application.ActionListenerImpl.processAction(ActionListenerImpl.java:107)
javax.faces.component.UICommand.broadcast(UICommand.java:383)
org.ajax4jsf.component.AjaxViewRoot.processEvents(AjaxViewRoot.java:186)
org.ajax4jsf.component.AjaxViewRoot.broadcastEvents(AjaxViewRoot.java:164)
org.ajax4jsf.component.AjaxViewRoot.processApplication(AjaxViewRoot.java:352)
com.sun.faces.lifecycle.InvokeApplicationPhase.execute(InvokeApplicationPhase.java:97)
com.sun.faces.lifecycle.LifecycleImpl.phase(LifecycleImpl.java:251)
com.sun.faces.lifecycle.LifecycleImpl.execute(LifecycleImpl.java:117)
javax.faces.webapp.FacesServlet.service(FacesServlet.java:244)
org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:290)
org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)
org.jboss.seam.servlet.SeamFilter$FilterChainImpl.doFilter(SeamFilter.java:83)
org.jboss.seam.debug.hot.HotDeployFilter.doFilter(HotDeployFilter.java:68)
org.jboss.seam.servlet.SeamFilter$FilterChainImpl.doFilter(SeamFilter.java:69)
org.jboss.seam.web.MultipartFilter.doFilter(MultipartFilter.java:85)
org.jboss.seam.servlet.SeamFilter$FilterChainImpl.doFilter(SeamFilter.java:69)
org.jboss.seam.web.ExceptionFilter.doFilter(ExceptionFilter.java:64)
org.jboss.seam.servlet.SeamFilter$FilterChainImpl.doFilter(SeamFilter.java:69)
org.jboss.seam.web.RedirectFilter.doFilter(RedirectFilter.java:44)
org.jboss.seam.servlet.SeamFilter$FilterChainImpl.doFilter(SeamFilter.java:69)
org.ajax4jsf.webapp.BaseXMLFilter.doXmlFilter(BaseXMLFilter.java:141)
org.ajax4jsf.webapp.BaseFilter.doFilter(BaseFilter.java:281)
org.jboss.seam.web.Ajax4jsfFilter.doFilter(Ajax4jsfFilter.java:60)
org.jboss.seam.servlet.SeamFilter$FilterChainImpl.doFilter(SeamFilter.java:69)
org.jboss.seam.web.LoggingFilter.doFilter(LoggingFilter.java:58)
org.jboss.seam.servlet.SeamFilter$FilterChainImpl.doFilter(SeamFilter.java:69)
org.jboss.seam.servlet.SeamFilter.doFilter(SeamFilter.java:150)
org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:235)
org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)
com.ccms30.auth.filter.UserAuthentication.doFilter(UserAuthentication.java:37)
org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:235)
org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)
org.jboss.web.tomcat.filters.ReplyHeaderFilter.doFilter(ReplyHeaderFilter.java:96)
org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:235)
org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)
org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:230)
org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:175)
org.jboss.web.tomcat.security.SecurityAssociationValve.invoke(SecurityAssociationValve.java:179)
org.apache.catalina.authenticator.AuthenticatorBase.invoke(AuthenticatorBase.java:433)
org.jboss.web.tomcat.security.JaccContextValve.invoke(JaccContextValve.java:84)
org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:128)
org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:104)
org.jboss.web.tomcat.service.jca.CachedConnectionValve.invoke(CachedConnectionValve.java:157)
org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:109)
org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:241)
org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:844)
org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.process(Http11Protocol.java:580)
org.apache.tomcat.util.net.JIoEndpoint$Worker.run(JIoEndpoint.java:447)
java.lang.Thread.run(Thread.java:595)

Caused by javax.faces.el.EvaluationException with message: "java.lang.reflect.UndeclaredThrowableException"

javax.faces.component.MethodBindingMethodExpressionAdapter.invoke(MethodBindingMethodExpressionAdapt
er.java:91)
com.sun.faces.application.ActionListenerImpl.processAction(ActionListenerImpl.java:91)
javax.faces.component.UICommand.broadcast(UICommand.java:383)
org.ajax4jsf.component.AjaxViewRoot.processEvents(AjaxViewRoot.java:186)
org.ajax4jsf.component.AjaxViewRoot.broadcastEvents(AjaxViewRoot.java:164)
org.ajax4jsf.component.AjaxViewRoot.processApplication(AjaxViewRoot.java:352)
com.sun.faces.lifecycle.InvokeApplicationPhase.execute(InvokeApplicationPhase.java:97)
com.sun.faces.lifecycle.LifecycleImpl.phase(LifecycleImpl.java:251)
com.sun.faces.lifecycle.LifecycleImpl.execute(LifecycleImpl.java:117)
javax.faces.webapp.FacesServlet.service(FacesServlet.java:244)
org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:290)
org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)
org.jboss.seam.servlet.SeamFilter$FilterChainImpl.doFilter(SeamFilter.java:83)
org.jboss.seam.debug.hot.HotDeployFilter.doFilter(HotDeployFilter.java:68)
org.jboss.seam.servlet.SeamFilter$FilterChainImpl.doFilter(SeamFilter.java:69)
org.jboss.seam.web.MultipartFilter.doFilter(MultipartFilter.java:85)
org.jboss.seam.servlet.SeamFilter$FilterChainImpl.doFilter(SeamFilter.java:69)
org.jboss.seam.web.ExceptionFilter.doFilter(ExceptionFilter.java:64)
org.jboss.seam.servlet.SeamFilter$FilterChainImpl.doFilter(SeamFilter.java:69)
org.jboss.seam.web.RedirectFilter.doFilter(RedirectFilter.java:44)
org.jboss.seam.servlet.SeamFilter$FilterChainImpl.doFilter(SeamFilter.java:69)
org.ajax4jsf.webapp.BaseXMLFilter.doXmlFilter(BaseXMLFilter.java:141)
org.ajax4jsf.webapp.BaseFilter.doFilter(BaseFilter.java:281)
org.jboss.seam.web.Ajax4jsfFilter.doFilter(Ajax4jsfFilter.java:60)
org.jboss.seam.servlet.SeamFilter$FilterChainImpl.doFilter(SeamFilter.java:69)
org.jboss.seam.web.LoggingFilter.doFilter(LoggingFilter.java:58)
org.jboss.seam.servlet.SeamFilter$FilterChainImpl.doFilter(SeamFilter.java:69)
org.jboss.seam.servlet.SeamFilter.doFilter(SeamFilter.java:150)
org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:235)
org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)
com.ccms30.auth.filter.UserAuthentication.doFilter(UserAuthentication.java:37)
org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:235)
org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)
org.jboss.web.tomcat.filters.ReplyHeaderFilter.doFilter(ReplyHeaderFilter.java:96)
org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:235)
org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)
org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:230)
org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:175)
org.jboss.web.tomcat.security.SecurityAssociationValve.invoke(SecurityAssociationValve.java:179)
org.apache.catalina.authenticator.AuthenticatorBase.invoke(AuthenticatorBase.java:433)
org.jboss.web.tomcat.security.JaccContextValve.invoke(JaccContextValve.java:84)
org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:128)
org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:104)
org.jboss.web.tomcat.service.jca.CachedConnectionValve.invoke(CachedConnectionValve.java:157)
org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:109)
org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:241)
org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:844)
org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.process(Http11Protocol.java:580)
org.apache.tomcat.util.net.JIoEndpoint$Worker.run(JIoEndpoint.java:447)
java.lang.Thread.run(Thread.java:595)

Caused by java.lang.reflect.UndeclaredThrowableException with message: ""

org.apache.commons.logging.impl.Log4jProxy.log(Log4jProxy.java:309)
org.apache.commons.logging.impl.Log4jProxy.debug(Log4jProxy.java:253)
org.apache.commons.logging.impl.Log4JLogger.debug(Log4JLogger.java:128)
org.hibernate.engine.Collections.processReachableCollection(Collections.java:176)
org.hibernate.event.def.FlushVisitor.processCollection(FlushVisitor.java:37)
org.hibernate.event.def.AbstractVisitor.processValue(AbstractVisitor.java:101)
org.hibernate.event.def.AbstractVisitor.processValue(AbstractVisitor.java:61)
org.hibernate.event.def.AbstractVisitor.processEntityPropertyValues(AbstractVisitor.java:55)
org.hibernate.event.def.DefaultFlushEntityEventListener.onFlushEntity(DefaultFlushEntityEventListene
r.java:138)
org.hibernate.event.def.AbstractFlushingEventListener.flushEntities(AbstractFlushingEventListener.ja
va:196)
org.hibernate.event.def.AbstractFlushingEventListener.flushEverythingToExecutions(AbstractFlushingEv
entListener.java:76)
org.hibernate.event.def.DefaultAutoFlushEventListener.onAutoFlush(DefaultAutoFlushEventListener.java
:35)
org.hibernate.impl.SessionImpl.autoFlushIfRequired(SessionImpl.java:969)
org.hibernate.impl.SessionImpl.list(SessionImpl.java:1114)
org.hibernate.impl.QueryImpl.list(QueryImpl.java:79)
org.hibernate.ejb.QueryImpl.getResultList(QueryImpl.java:64)
com.ccm30.validators.MyProductlineListValidator.isValid(MyProductlineListValidator.java:48)
org.hibernate.validator.ClassValidator.getInvalidValues(ClassValidator.java:341)
org.hibernate.validator.ClassValidator.getInvalidValues(ClassValidator.java:307)
org.hibernate.validator.event.ValidateEventListener.validate(ValidateEventListener.java:134)
org.hibernate.validator.event.ValidateEventListener.onPreInsert(ValidateEventListener.java:167)
org.hibernate.action.EntityInsertAction.preInsert(EntityInsertAction.java:156)
org.hibernate.action.EntityInsertAction.execute(EntityInsertAction.java:49)
org.hibernate.engine.ActionQueue.execute(ActionQueue.java:250)
org.hibernate.engine.ActionQueue.executeActions(ActionQueue.java:234)
org.hibernate.engine.ActionQueue.executeActions(ActionQueue.java:141)
org.hibernate.event.def.AbstractFlushingEventListener.performExecutions(AbstractFlushingEventListene
r.java:298)
org.hibernate.event.def.DefaultAutoFlushEventListener.onAutoFlush(DefaultAutoFlushEventListener.java
:41)
org.hibernate.impl.SessionImpl.autoFlushIfRequired(SessionImpl.java:969)
org.hibernate.impl.SessionImpl.list(SessionImpl.java:1114)
org.hibernate.impl.QueryImpl.list(QueryImpl.java:79)
org.hibernate.ejb.QueryImpl.getResultList(QueryImpl.java:64)
com.ccm30.validators.MyProductlineListValidator.isValid(MyProductlineListValidator.java:48)
org.hibernate.validator.ClassValidator.getInvalidValues(ClassValidator.java:341)
org.hibernate.validator.ClassValidator.getInvalidValues(ClassValidator.java:307)
org.hibernate.validator.event.ValidateEventListener.validate(ValidateEventListener.java:134)
org.hibernate.validator.event.ValidateEventListener.onPreInsert(ValidateEventListener.java:167)
org.hibernate.action.EntityInsertAction.preInsert(EntityInsertAction.java:156)
org.hibernate.action.EntityInsertAction.execute(EntityInsertAction.java:49)
org.hibernate.engine.ActionQueue.execute(ActionQueue.java:250)
org.hibernate.engine.ActionQueue.executeActions(ActionQueue.java:234)
org.hibernate.engine.ActionQueue.executeActions(ActionQueue.java:141)
org.hibernate.event.def.AbstractFlushingEventListener.performExecutions(AbstractFlushingEventListene
r.java:298)
org.hibernate.event.def.DefaultAutoFlushEventListener.onAutoFlush(DefaultAutoFlushEventListener.java
:41)
org.hibernate.impl.SessionImpl.autoFlushIfRequired(SessionImpl.java:969)
org.hibernate.impl.SessionImpl.list(SessionImpl.java:1114)
org.hibernate.impl.QueryImpl.list(QueryImpl.java:79)
org.hibernate.ejb.QueryImpl.getResultList(QueryImpl.java:64)
com.ccm30.validators.MyProductlineListValidator.isValid(MyProductlineListValidator.java:48)
...   



Ich hab das Gefühl dass der Validator, beim persistieren, in einer Art endlosschleife aufgerufen wird, hab aber ka wieso.

Viele Grüße, sry falls ich im falschen forum bin


Top
 Profile  
 
 Post subject:
PostPosted: Tue Nov 13, 2007 4:03 pm 
Expert
Expert

Joined: Tue Nov 23, 2004 7:00 pm
Posts: 570
Location: mostly Frankfurt Germany
JSF Exception sind immer "ekelig" und lügen oft. Im Seam Forum kann Dir vielleicht jemand helfen. www.jboss.org

_________________
Best Regards
Sebastian
---
Training for Hibernate and Java Persistence
Tutorials for Hibernate, Spring, EJB, JSF...
eBook: Hibernate 3 - DeveloperGuide
Paper book: Hibernate 3 - Das Praxisbuch
http://www.laliluna.de


Top
 Profile  
 
Display posts from previous:  Sort by  
Forum locked This topic is locked, you cannot edit posts or make further replies.  [ 2 posts ] 

All times are UTC - 5 hours [ DST ]


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum

Search for:
© Copyright 2014, Red Hat Inc. All rights reserved. JBoss and Hibernate are registered trademarks and servicemarks of Red Hat, Inc.