-->
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.  [ 1 post ] 
Author Message
 Post subject: PrePersist not running
PostPosted: Wed Dec 05, 2007 11:39 am 
Newbie

Joined: Tue Dec 04, 2007 2:48 pm
Posts: 6
Hi,

Some of my PrePersist methods aren't running and I dont know why. Code:

Hibernate version: 3.2.4.sp1, JPA

Mapping documents:

Code:
@Embeddable
@MappedSuperClass
public class BasicPerson {

  @PrePersist
  @PreUpdate
  private void processData() {
    // not running
    ...
  }
}

@Embeddable
@MappedSuperClass
public class BasicCitizen extends BasicPerson {
  ...
}

@Embeddable
@MappedSuperClass
public class BasicCitizenRequest extends BasicCitizen {
  ...
}

@Entity
@Table(name = "WebRequest")
@Name("webrequest")
public class CitizenRequestForm {
  private BasicCitizenRequest requestData;
  ...

  @Embedded
  public BasicCitizenRequest getData() {
  }

  @PrePersist
  @PreUpdate
  private void processData() {
    // running ok
    ...
  }
}


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

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.