Questions tagged [persistence.xml]

Used with the Java Persistence API, specifies names and database properties.

When used with the Java Persistence API, the persistence.xml file is usually placed in the META-INF folder; it's used to specify the persistence provider name, entity class names, and properties like the database connection URL, driver, user, password, and so on (taken from http://www.javaworld.com/javaworld/jw-01-2008/jw-01-jpa1.html?page=3).

519 questions
0
votes
0 answers

Persistence unit not resolved Maven project with Glassfish 4 and Netbeans 7.4

I created a Maven web project using Glassfish 4 and Netbeans 7.4. This is my pom.xml :
eento
  • 761
  • 4
  • 20
  • 53
0
votes
1 answer

Strange hibernate.hbm2ddl.auto behaviour

I have deployed an application with hibernate.hbm2ddl.auto = create and found that many of my tables were dropped! I used to do the same thing but using EclipseLink instead of Hibernate, the database return table already exists witch means that it…
Rachid
  • 165
  • 2
  • 5
  • 16
0
votes
1 answer

Tomcat, Logon denied for Oracle Database 11gR2

I am using JPA by connecting TOMCAT deployed webapp to a Oracle Database 11gR2. I am getting the following error. javax.persistence.PersistenceException: Exception [EclipseLink-4002] (Eclipse Persistence Services - 2.5.2.v20131113-a7346c6):…
hthomos
  • 297
  • 2
  • 8
  • 16
0
votes
2 answers

Switch from EclipseLink to Hibernate

We want to change the JPA Provider EclipseLink and use Hibernate for the future. The problem is that I didn't find all property equivalents. So the following are missing:
Rooky
  • 810
  • 3
  • 12
  • 20
0
votes
0 answers

Tomcat not deploying META-INF

I'm using Java persistence and deploying on Tomcat, but I get an error saying "No Persistence provider for EntityManager named WorxVaultWeb" when running application. Source of this problem is that Tomcat is not deploying META-INF folder and…
Xitac
  • 154
  • 3
  • 9
0
votes
1 answer

persistence.xml variable declaration

I am fairly new to JPA and in my project the applciation server is Glassfish 3.1.2 .So when i encountered persitence.xml in my project ,I have gone through http://en.wikibooks.org/wiki/Java_Persistence/Runtime to get basic idea of how it is used in…
chebus
  • 762
  • 1
  • 8
  • 26
0
votes
1 answer

Hibernate and Resin working together

I am new to resin and am trying to get Hibernate to work with it. I am running into some problems with the JNDI lookup of the data source. I keep getting "javax.naming.NameNotFoundException". I have a special case where I need to dynamically…
Jarad Duersch
  • 257
  • 1
  • 4
  • 15
0
votes
2 answers

EJB Project doesn't connect to the right Derby database/table

having a problem yesterday that i couldn't connect to the derby database (most likely due to persistence.xml issues) I have been guided to modify my persistence.xml so that it contains two additional poperties;
Adrian
  • 215
  • 1
  • 6
  • 14
0
votes
3 answers

How to connect a MySQL database in a java application in TomEE

I am developping a web application (Eclipse, TomEE) and I try to communicate with a MySQL database : I have created the database I have included EclipseLink and MySQL-Driver the connection is OK (I tried the ping and it is OK) When I try to…
federem
  • 299
  • 1
  • 6
  • 17
0
votes
1 answer

class listed in the persistence.xml file but not mapped

I have listed my class in persistence.xml but mapped class is not recognized inside. I tried false But no luck. My persistence.xml file
Inaccessible
  • 1,560
  • 3
  • 18
  • 42
0
votes
1 answer

why my project does not deploy?

i am using eclipselink and tomee for save data.. eclipselink 2.42 tomee+ 1.6.0 it occurs when try to use transaction-type="JTA" where am i missing ? thnks.. when i try to deploy my project i am getting starting tomcat at localhost has encountered…
user3080494
  • 23
  • 1
  • 7
0
votes
1 answer

Error kundera.client property is missing for persistence

I'm using Kundera with Spring. kundera version is 2.10, with other version I get different errors. I've tryed to declare Client class in kundera.properties, but it had no effect. With version 2.8 even examples from off website doesn't work. Error…
0
votes
1 answer

how to configure servers for reading and writing in persistence.xml (EJB 3.X APP)

I have EJB 3.0 application. It is run on Jboss 7.1 server. I have two persistence-unit in persistence.xml to work with two sql server. I use first server for writing and updating tables. The second SQL server is only for reading data. When I create…
grep
  • 5,465
  • 12
  • 60
  • 112
0
votes
1 answer

Problems with Maven when changing code?

I am trying to run a little Maven test program using NetBeans. Now the NetBeans-given code works perfectly fine with Maven. Compiling, running, all good. But when I change anything, like adding an FXML-File or adding JPA persistence, I then get…
Socrates
  • 8,724
  • 25
  • 66
  • 113
0
votes
2 answers

Problems building up Java project with JPA

I am trying to get a javax.persistence running, but I get erros. I built up a little project for testing, creating an entity class, the persistence.xml, and the running process: Entity class: package glasses; import java.io.Serializable; import…
Socrates
  • 8,724
  • 25
  • 66
  • 113