[
https://issues.apache.org/jira/browse/OPENJPA-51?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel#action_12491902
]
Catalina Wei commented on OPENJPA-51:
-
Abe,
I am working on issue OPENJPA-51 for David Wisneski.
I need some
Patrick Linskey wrote:
I think that if you do 1, 2, 3, 5, and 6, you should be in good shape.
This indeed seems to work!
BTW, Toplink just now also had its lazy loading issue solved: turns out
@MappedSuperclass classes must be listed in the persistence.xml. The
solution actually was
Have you tried to use Spring? I think you may be able to get that with
dependency injection. Not positive but thought I would throw in that suggestion
-Original Message-
From: tbee [mailto:[EMAIL PROTECTED]
Sent: April 26, 2007 5:10 AM
To: open-jpa-dev@incubator.apache.org
Subject:
Phill Moran wrote:
Have you tried to use Spring? I think you may be able to get that with
dependency injection. Not positive but thought I would throw in that
suggestion
You really want to give me a heart attack? ;-) I'm not a spring fan.
--
View this message in context:
Any thoughts about this patch? It changes how @Embeddable and
@MappedSuperclass classes are enhanced.
I'd be a little nervous about NPEs registering a null alias, but it
seems that it's been tested so apparently that's fine. The only
thing that might be missing is to put an if (alias !=
On Apr 26, 2007, at 2:10 AM, tbee wrote:
Is it possible to provide an actual JDBC connection instead of connect
parameters?
You can supply the datasource instance in a PersistenceUnitInfo, but
I certainly hope you can't provide a connection.
The business model I'm trying to construct
You can't provide a JDBC connection directly, but you can provide a
DataSource, which, in turn, can provide a connection.
-Patrick
--
Patrick Linskey
BEA Systems, Inc.
___
Notice: This email message, together with any
Patrick Linskey wrote:
FYI, once I commit a fix to OPENJPA-229, you'll be able to use the same
class names once again. Sorry about that bug.
Understood. Right now I'm in the connection debate: toplink cannot use less
than 2, so each of my fat clients will have 3 open (1 it already has).
djencks wrote:
You can supply the datasource instance in a PersistenceUnitInfo, but
I certainly hope you can't provide a connection.
Are you running inside a javaee app server? (not standalone tomcat)
If so there's a very good chance that all the connection handles
obtained
Is it possible to provide an actual JDBC connection instead
of connect
parameters?
You can supply the datasource instance in a
PersistenceUnitInfo, but I certainly hope you can't provide a
connection.
You can also specify a DataSource class name in the
openjpa.ConnectionFactory
Many thanks Patrick!
You're welcome.
FYI, once I commit a fix to OPENJPA-229, you'll be able to use the same
class names once again. Sorry about that bug.
-Patrick
--
Patrick Linskey
BEA Systems, Inc.
___
Notice: This
Community,
How does one go about debugging object retrieval/creation. I continue to have
exceptions and little to go on as far as the cause.
The named JPQL is good since I know it generates a good sql (can trace code and
see it) . I know the sql is good as I can copy/paste it into mysql query
Could you post the full NPE? Is results null, or is the NPE coming from
within OpenJPA somewhere? OpenJPA shouldn't be returning a null
collection in any situation, I don't think.
One way to fish for causes of suspicious problems is to set the default
log level to TRACE:
property
Phill-
The maximum verbosity of logging is obtained by specifying the
openjpa.Log property to DefaultLevel=TRACE.
What is the full exception stack trace? We might be able to help
identify the problem. In any case OpenJPA should never be throwing an
NPE, so we should at least probably fix
[
https://issues.apache.org/jira/browse/OPENJPA-229?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
]
Patrick Linskey resolved OPENJPA-229.
-
Resolution: Fixed
OpenJPA fails with MappedSuperclasses and Entities with the same
I did not mean it threw an NPE but I was left with a null result list.
I have setup trace already and I actually get nothing back. Here is the trace
across the execution point
13734 WARN [main] openjpa.MetaData - Found duplicate query
PersonFXLastFirst in class ca.BidSpec.emall.user.Person.
What is interesting is the line with a 1 (from
System.out.println(results.size())). What this represents is
the message that the result list is closed nothing else in
the trace.
So what causes the result list to be closed?
I don't follow -- I would assume that the '1' represents the
Some more information on this exception
Right after the execution the exception held inside the result is
com.sun.jdi.InvocationException occurred invoking method... Can't seem to get
more data out of it
Once the system.out is executed the exception changes to The result list has
been closed
I changed the print statement you asked about and got a
[EMAIL PROTECTED] It holds the exception I
mentioned in the last email (out of sync with this one)
Phill
-Original Message-
From: Patrick Linskey [mailto:[EMAIL PROTECTED]
Sent: April 26, 2007 4:35 PM
To:
Thanks for all the comments, I've learned a lot.
1. I have a classloader scanning strategy written and apparently
working, however it is rather slow at least in geronimo. Is anyone
interested in it, seeing as how its not an appropriate approach in a
app server according to Patrick's
So you're saying that the ResultList contains an Exception? Can you post
what you get if you do '((Exception) results.get(0)).printStackTrace()'?
-Patrick
--
Patrick Linskey
BEA Systems, Inc.
___
Notice: This email message,
Can't cast List to Exception
-Original Message-
From: Patrick Linskey [mailto:[EMAIL PROTECTED]
Sent: April 26, 2007 5:00 PM
To: open-jpa-dev@incubator.apache.org
Subject: RE: How to debug object retrieveal in JPA?
So you're saying that the ResultList contains an Exception? Can you
Can you post what you get if you do '((Exception)
results.get(0)).printStackTrace()'?
... so results.get(0) is returning a List? That's very odd. What if you
do:
System.out.println(results.get(0))?
If it is a List of Exceptions, what if you print out the stacks of the
exceptions in the list?
tbee wrote:
Patrick Linskey wrote:
I think that if you do 1, 2, 3, 5, and 6, you should be in good shape.
This indeed seems to work!
BTW, Toplink just now also had its lazy loading issue solved: turns out
@MappedSuperclass classes must be listed in the persistence.xml.
Run that config gives us this lovely message:
0|false|0.9.6-incubating org.apache.openjpa.persistence.PersistenceException:
null
at org.apache.openjpa.kernel.BrokerImpl.find(BrokerImpl.java:851)
at org.apache.openjpa.kernel.BrokerImpl.find(BrokerImpl.java:748)
at
Caused by: java.lang.NullPointerException
at java.util.Locale.toLowerCase(Locale.java:1060)
at java.util.Locale.convertOldISOCodes(Locale.java:1083)
at java.util.Locale.init(Locale.java:272)
at java.util.Locale.init(Locale.java:302)
at
I had suspected the Locale so I made a set/getLocale that communicate in String.
I figured that openJPA does not actually care how I implement.
But for this run I removed it completely and did a clean rebuild. Good news and
bad the exception changed:
java.util.NoSuchElementException: The
Can you pass a connection from em to the other side instead?
tbee wrote:
djencks wrote:
You can supply the datasource instance in a PersistenceUnitInfo, but
I certainly hope you can't provide a connection.
Are you running inside a javaee app server? (not standalone tomcat)
If so
I don't close it in anyway directly
-Original Message-
From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]
Sent: April 26, 2007 11:16 PM
To: open-jpa-dev@incubator.apache.org
Subject: Re: How to debug object retrieveal in JPA?
Can it be that there is a glue code that closes EM in
Marina Vatkina wrote:
Can you pass a connection from em to the other side instead?
That would be an option tool using EM as a pool. I have to experiment with
OpenJPA connection behaviour a bit.
--
View this message in context:
30 matches
Mail list logo