Bonoir,
Je crée une application google app engine actuellement. Mais je n'arrive pas a persister mes données. Je n'est pas de remonter d'erreurs
voici mon jdoconfig.xml
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15
| <jdoconfig xmlns="http://java.sun.com/xml/ns/jdo/jdoconfig"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:noNamespaceSchemaLocation="http://java.sun.com/xml/ns/jdo/jdoconfig">
<persistence-manager-factory name="SupEvent-PU">
<property name="javax.jdo.PersistenceManagerFactoryClass"
value="org.datanucleus.api.jdo.JDOPersistenceManagerFactory"/>
<property name="javax.jdo.option.ConnectionURL" value="appengine"/>
<property name="javax.jdo.option.NontransactionalRead" value="true"/>
<property name="javax.jdo.option.NontransactionalWrite" value="true"/>
<property name="javax.jdo.option.RetainValues" value="true"/>
<property name="datanucleus.appengine.autoCreateDatastoreTxns" value="true"/>
<property name="datanucleus.appengine.singletonPMFForName" value="true"/>
</persistence-manager-factory>
</jdoconfig> |
et une de mes entity
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50
| @PersistenceCapable
@SuppressWarnings("serial")
public class Attendee implements Serializable{
@PrimaryKey
@Persistent(valueStrategy=IdGeneratorStrategy.IDENTITY)
private Long id;
@Persistent
private String firstName;
@Persistent
private String lastName;
@Persistent
private String email;
@Persistent
private Long event;
public Attendee(){}
public Long getId() {
return id;
}
public void setId(Long id) {
this.id = id;
}
public String getFirstName() {
return firstName;
}
public void setFirstName(String firstName) {
this.firstName = firstName;
}
public String getLastName() {
return lastName;
}
public void setLastName(String lastName) {
this.lastName = lastName;
}
public String getEmail() {
return email;
}
public void setEmail(String email) {
this.email = email;
}
public Long getEvent() {
return event;
}
public void setEvent(Long event) {
this.event = event;
}
} |
j'aimerais bien savoir ou peut être mon erreurs
Cordialement
Maj
Suite a de nombreux échec je me suis tourné vers jpa.
voici le log que je léve maintenant
org.datanucleus.metadata.MetaDataManager loadPersistenceUnit: Class com.supinfo.supevent.servlet.ListEventServlet was specified in persistence-unit transactions-optional but not annotated, so ignoring
je ne comprend pas trop des idées ??
Partager