0
我在嘗試輪詢JPA實體Person時收到以下錯誤。代碼中沒有錯誤。所有的東西都編譯成mvn乾淨的安裝,而Person實體確實存在於net.lr.tutorial.karaf.camel.jpa2jms.model包中。我已經安裝了所有我認爲必要的功能,並且我知道它正確連接到數據庫,因爲它正在爲主鍵創建序列數據庫。Apache Camel - JpaConsumer失敗的輪詢端點
2014-01-30 21:33:59,848 | WARN | jms.model.Person | JpaConsumer |
125 - org.apache.camel.camel-core - 2.12.0 | Consumer
Consumer[jpa://net.lr.tutorial.karaf.camel.jpa2jms.model.Person?consumer.delay=3500]
failed polling endpoint:
Endpoint[jpa://net.lr.tutorial.karaf.camel.jpa2jms.model.Person?consumer.delay=3500].
Will try again at next poll. Caused by:
[org.apache.openjpa.persistence.ArgumentException - An error occurred while parsing the
query filter "select x from Person x". Error message: The name "Person" is not a
recognized entity or identifier. Perhaps you meant Person, which is a close match. Known
entity names: [Person]]
<openjpa-2.1.1-r422266:1148538 nonfatal user error>
org.apache.openjpa.persistence.ArgumentException: An error occurred while parsing the
query filter "select x from Person x". Error message: The name "Person" is not a
recognized entity or identifier. Perhaps you meant Person, which is a close match. Known
entity names: [Person]
任何想法?
肖恩
您是否重置了'Person'實體的名稱屬性,即'@Entity(name =「Person」)'? –
是的,我做到了。我的JPA類看起來像 - @Entity(name =「person」) [code] @XmlType @XmlRootElement public class Person {[/ code] –