Ich aktualisiere eine alte Spring 3 -App auf den Frühling. 6. Ich habe eine Reihe von Problemen mit derselben Nachricht gefunden, aber sie verwenden meist tatsächlich Annotationen. Diejenige, die nicht: Java/Hibernate -Ausnahme: Erwartung von Idclass -Mapping hat keine Antwort.
Ich aktualisiere eine alte Spring 3 -App auf den Frühling. 6. Ich habe eine Reihe von Problemen mit derselben Nachricht gefunden, aber sie verwenden meist tatsächlich Annotationen. Diejenige, die nicht: Java/Hibernate -Ausnahme: Erwartung von Idclass -Mapping hat keine Antwort.[code]
mappings/appearance.hbm.xml mappings/appearMessage.hbm.xml ...lots of other mapping files
< /code> und ich erhalte einen Fehler, wenn ich meine App starte: < /p> ...long stack trace Caused by: org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'jxxSessionFactory' defined in ServletContext resource [/WEB-INF/conf/spring/dao.xml]: expecting IdClass mapping at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.initializeBean(AbstractAutowireCapableBeanFactory.java:1812) ~[spring-beans-6.2.5.jar:6.2.5] ...long stack trace < /code> Leider wird nicht angegeben, welche Zuordnung. < /p> Es gibt mehrere Entitäten, die Verbundtasten verwenden. Hier sind die Klassen: < /p> public class AppearanceKey implements Serializable{
/** * @return the dateAttended */ public Calendar getDateAttended() { return DateAttended; } /** * @param dateAttended the dateAttended to set */ public void setDateAttended(Calendar dateAttended) { DateAttended = dateAttended; } /** * @return the participantNumber */ public String getParticipantNumber() { return ParticipantNumber; } /** * @param participantNumber the participantNumber to set */ public void setParticipantNumber(String participantNumber) { ParticipantNumber = participantNumber; } } < /code> Wenn ich zur Annotation -Zuordnung wechseln muss, werde ich es aber versuchen, wenn möglich zu vermeiden. < /p> public class Appearance {
/** * @return the dateAttended */ public Calendar getDateAttended() { return DateAttended; } /** * @param dateAttended the dateAttended to set */ public void setDateAttended(Calendar dateAttended) { DateAttended = dateAttended; } /** * @return the participantNumber */ public String getParticipantNumber() { return ParticipantNumber; } /** * @param participantNumber the participantNumber to set */ public void setParticipantNumber(String participantNumber) { ParticipantNumber = participantNumber; } /** * @return the paymentAmount */ public Float getPaymentAmount() { if(PaymentAmount==null){ PaymentAmount=0.0f; } return PaymentAmount; } /** * @param paymentAmount the paymentAmount to set */ public void setPaymentAmount(Float paymentAmount) { PaymentAmount = paymentAmount; }
/** * @return the courtLocation */ public Courthouse getCourtLocation() { return CourtLocation; }
/** * @param courtLocation the courtLocation to set */ public void setCourtLocation(Courthouse courtLocation) { CourtLocation = courtLocation; } } [/code]
Ich aktualisiere eine alte Spring 3 -App auf den Frühling. 6. Ich habe eine Reihe von Problemen mit derselben Nachricht gefunden, aber sie verwenden meist tatsächlich Annotationen. Diejenige, die...
Ich aktualisiere ein Java -Projekt von Spirng 2 & Hibenate 3 auf Spring 5.2.21.Release und Hibernate 5.6.9.Error Creating bean with name demo.sessionFactory defined in...