Hi Jerry, To explain it shortly:
1. In OpenJPA NamedQuery are directly attached to the POJO being persited, here AbstractJPAMailboxMessage 2. Using these annotations (named query) openjpa plugin enhance code upon compilation 3. Then the magic happens Here because openjpa do not load correctly persisted objects, it then fails at executing related queries. Why OpenJPA fails loading related metadata? - the log is missing explanation... And of course... - What is the exact James version? - JDBC mysql driver version? - MySQL version? This would enable us to be testing this locally, see if we can reproduce it with basic setup... Cheers, Benoit On 17/09/2019 10:36, Jerry Malcolm wrote: > Something that might be relevant to this problem, but the messages make > no more sense than the other one... A little earlier in the log, I have > a bunch of these messages: > > 174 James INFO [main] openjpa.Runtime - Starting OpenJPA 3.0.0 > 207 James INFO [main] openjpa.jdbc.JDBC - Using dictionary class > "org.apache.openjpa.jdbc.sql.MySQLDictionary". > 552 James INFO [main] openjpa.jdbc.JDBC - Connected to MySQL version > 5.5 using JDBC driver MySQL Connector Java version > mysql-connector-java-5.1.34 ( Revision: > jess.bal...@oracle.com-20141014163213-wqbwpf1ok2kvo1om ). > 586 James WARN [main] openjpa.MetaData - The class > "org.apache.james.mailbox.jpa.mail.model.openjpa.JPAMessage" listed in > the openjpa.MetaDataFactory configuration property could not be loaded > by sun.misc.Launcher$AppClassLoader@764c12b6; ignoring. > 587 James WARN [main] openjpa.MetaData - The class > "org.apache.james.mailbox.jpa.mail.model.openjpa.AbstractJPAMessage" > listed in the openjpa.MetaDataFactory configuration property could not > be loaded by sun.misc.Launcher$AppClassLoader@764c12b6; ignoring. > 688 James INFO [main] openjpa.MetaData - The class > "org.apache.james.mailbox.jpa.mail.model.openjpa.JPAMessage" listed in > the openjpa.MetaDataFactory configuration property could not be loaded > by sun.misc.Launcher$AppClassLoader@764c12b6; ignoring. > 689 James INFO [main] openjpa.MetaData - The class > "org.apache.james.mailbox.jpa.mail.model.openjpa.AbstractJPAMessage" > listed in the openjpa.MetaDataFactory configuration property could not > be loaded by sun.misc.Launcher$AppClassLoader@764c12b6; ignoring. > 702 James INFO [main] openjpa.MetaData - The class > "org.apache.james.mailbox.jpa.mail.model.openjpa.JPAMessage" listed in > the openjpa.MetaDataFactory configuration property could not be loaded > by sun.misc.Launcher$AppClassLoader@764c12b6; ignoring. > > On 9/16/2019 10:28 PM, Jerry Malcolm wrote: >> The fun just keeps happening.... I was finally able to bring up the >> new installation of James 3.3.0 with a sandbox copy of my real >> database. I created a new test email account in James and configured >> it in my local Thunderbird instance. So far, so good. But now every >> time Thunderbird contacts James for an IMAP update, I get the error >> below in the James log. I'm not really familiar with jpa. I searched >> through the source and found quite a few places that the >> "findMessagesInMailbox" name is referenced. So not really sure why it >> says it isn't defined. Any ideas? This is with the downloaded >> binaries, not a re-built version. >> >> <openjpa-3.0.0-r422266:1833209 fatal user error> >> org.apache.openjpa.persistence.ArgumentException: There is no query >> with the name "findMessagesInMailbox" defined for any of the known >> persistent classes: >> [org.apache.james.mailbox.jpa.mail.model.JPAMailbox, >> org.apache.james.mailbox.jpa.mail.model.openjpa.JPAMessage, >> org.apache.james.mailbox.jpa.mail.model.JPAUserFlag, >> org.apache.james.mailbox.jpa.mail.model.openjpa.AbstractJPAMessage, >> org.apache.james.domainlist.jpa.model.JPADomain, >> org.apache.james.user.jpa.model.JPAUser, >> org.apache.james.mailbox.jpa.mail.model.JPAProperty, >> org.apache.james.mailbox.jpa.user.model.JPASubscription, >> org.apache.james.rrt.jpa.model.JPARecipientRewrite]. >> >> >> --------------------------------------------------------------------- >> To unsubscribe, e-mail: server-user-unsubscr...@james.apache.org >> For additional commands, e-mail: server-user-h...@james.apache.org >> > > --------------------------------------------------------------------- > To unsubscribe, e-mail: server-user-unsubscr...@james.apache.org > For additional commands, e-mail: server-user-h...@james.apache.org > --------------------------------------------------------------------- To unsubscribe, e-mail: server-user-unsubscr...@james.apache.org For additional commands, e-mail: server-user-h...@james.apache.org