I went to the documentation (http://docs.jboss.org/envers/docs/#revisionlog) there it was written that if we annonate an entity with @RevisionEntity then Hibernate will not create default revinfo table by its own instead it will map the entity which is annotated with @RevisionEntity. I tried still its createing default table named as revinfo and not custom named table as RevisionTable. Following is the code :
import javax.persistence.GeneratedValue;
import javax.persistence.Id;
import org.hibernate.envers.RevisionEntity;
import org.hibernate.envers.RevisionNumber;
import org.hibernate.envers.RevisionTimestamp;
@RevisionEntity
public class RevisionTable {
@Id
@GeneratedValue
@RevisionNumber
private int id;
@RevisionTimestamp
private long timestamp;
public int getId() {
return id;
}
public void setId(int id) {
this.id = id;
}
public long getTimestamp() {
return timestamp;
}
public void setTimestamp(long timestamp) {
this.timestamp = timestamp;
}
}
I am not understanding where i am going wrong. As i am new to Hibernate Envers, it will be helpfull if explain the solution in detail.