Martin,
The OpenJPAEntityManagerSPI interface provides a method to access the
underlying JDBC connection used by the em. You can use that connection to
get db metadata information. Depending on whether your application uses a
container or application managed em, you may need to call em.getDelega
Hi Annette,
It looks like OpenJPA tried to lookup java:comp/jdbc/selektionendb and
failed. I think the usual namespace is java:comp/*env*/. You might just be
missing 'env' in persistence.xml.
hope this helps,
-mike
On Thu, Jul 9, 2009 at 7:56 AM, Scherer, Annette <
annette.sche...@huk-coburg.de
Simon -
I started looking at the patch you attached to OPENJPA-250 today and I'm
wondering if you had to make any additional changes to get it working
properly in your environment? I applied the patch and I ran a fairly simple
scenario with a number of threads going and I ran into some issues whe
Thank you! Yes, you have; I went right by it.
Thanks again.
Best,
Laird
On Thu, Jul 9, 2009 at 2:36 PM, Michael Dick (via Nabble) <
ml-user+17961-1519918...@n2.nabble.com
> wrote:
> Hi Laird
>
> I forgot to add this bit, it *is* in the manual, but it's easier to find
> once you know what you'
Hi Laird
I forgot to add this bit, it *is* in the manual, but it's easier to find
once you know what you're looking for.
Link to the relevant section :
http://openjpa.apache.org/builds/latest/docs/manual/manual.html#ref_guide_mapping_jpa_constraints
It's something we can expand on though, maybe
I think you're looking for the org.apache.openjpa.persistence.jdbc.Index
annotation :
ex :
import org.apache.openjpa.persistence.jdbc.Index;
@Entity
public class Person {
. . .
@Index
private int myint;
. . .
}
SQL generation (DB2) :
3786 laird TRACE [main] openjpa.jdbc.SQL -
Hi Martin
Unfortunately there isn't an easy way (at least not one that I'm aware of).
If you're specifying the connection info in properties in your
persistence.xml file then we can retrieve those values.
If you're using a WebSphere datasource then it's trickier, all we have
access to is the cont
I hit this problem a couple of months ago and discovered it happens if you
serialize the object because the serialize/deserialize process seems to lose
track of null values. There is an openjpa setting which fixes this but my
problem was that I mistakenly had a remote interface to my ejb instead
Is it possible to define a non-unique index in OpenJPA? Hibernate offers
the @Index annotation to do this as part of its DDL generation machinery.
My apologies if this was mentioned; I didn't see it in
http://openjpa.apache.org/builds/latest/docs/manual/manual.html.
Thanks,
Laird
Hello Yann,
this seems to be a flaw in the OpenJPA mapping source indeed. I
just got the same error here with the 2.0.0-M2 version (its line
1473 in org.apache.openjpa.jdbc.meta.MappingInfo.java there).
The error occurred after introducing a trivial change in the domain
model.
Looking at the sou
Hello again,
We are still trying to trouble shoot our memory leak. It seems that other
users have had the same issue.
https://issues.apache.org/jira/browse/OPENJPA-746?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
JIRA-746
Are there any updates on this issue that could hel
Hi,
Is there an easy way to dynamically find the database name and schema name
being used by an EntityManager at runtime?
We are using OpenJpa 1.0.4 on Websphere and an Oracle datasource.
We would like to make the information accessible on an application screen
because we have so many environme
Hi Annette,
I think on-demand is the default value for ConnectionRetainMode, so you
*shouldn't* need to set the property. I don't see how it could hurt though.
Making sure you close the em before it goes out of scope is definitely a
good idea (same would go for the EntityManagerFactory, but that
I've just deployed by first OpenJPA to a live production system. I'm getting
an occasional error:
InvalidStateException: Encountered unmanaged object in persistent field
> "blah.MyEntity.addedBy" during flush. However, this field does not allow
> cascade persist. Set the cascade attribute for thi
Hello Michael,
Thank you for your tip.
I think, I do not use em.close() after very each operation on DB
Should I additionally configure the ConnectionRetainMode property in my
persistence.xml (Suppose not, for on-demand is the default configuration for
ConnectionRetainMode)
Actual version
Hello,
I have a problem, when trying to create an EntityManager.
I'm using the persistence.xml beneath, which indicates to use managed
transactions and managed ConnectionFactoryMode (see below).
http://java.sun.com/xml/ns/persistence";
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instan
16 matches
Mail list logo