Issue Details (XML | Word | Printable)

Key: CORE-3358
Type: Improvement Improvement
Status: Closed Closed
Resolution: Won't Fix
Priority: Minor Minor
Assignee: Unassigned
Reporter: Benoit Delagarde
Votes: 0
Watchers: 0
Operations

If you were logged in you would be able to see more operations.
JPOX Core (ARCHIVED)

Slow makePersistent

Created: 23/Aug/07 11:27 AM   Updated: 26/May/10 07:32 PM   Resolved: 10/Jan/09 09:03 PM
Component/s: JDO
Affects Version/s: 1.1.8, 1.2.0-beta-3
Fix Version/s: None

File Attachments: 1. Zip Archive TestCase.zip (42 kB)
2. Zip Archive testCase.zip (56 kB)
3. Zip Archive testCase.zip (59 kB)

Environment: Java 1.5, Mysql 5.0.41, windows xp

Forum Thread URL: http://www.jpox.org/servlet/forum/viewthread?thread=4554
Datastore: MySQL


 Description  « Hide
Following the discussion referenced below, I provide a test case.
The makePersistent is slow when it is called on an detached object containing a "big" collection.

To give an exemple when the collection contain 300 objects, the make persistent take 15s to finish.

THere is 3 part in this test case :
+ the persistent capable object (entites)
+ A tool to populate a db, because we need many objects
+ The test case itself



Sort Order: Ascending order - Click to sort in descending order
Andy Jefferson added a comment - 24/Aug/07 07:51 AM
Nice testcase ;-)
No wonder it runs slow, I can't even find it!

Benoit Delagarde added a comment - 24/Aug/07 08:15 AM
I have attached the testCase.
Sorry.

Andy Jefferson added a comment - 24/Aug/07 08:51 AM
Thanks for the testcase, but you really need to read http://www.jpox.org/docs/bug_reporting.html since we won't be touching what you provided

Benoit Delagarde added a comment - 24/Aug/07 01:56 PM
Corrected testCase to match test case definition/

Benoit Delagarde added a comment - 24/Aug/07 02:01 PM
Well,

I have corrected my testcase to match the specification.
Be patient during the population of DB (about 1mn).

Andy Jefferson added a comment - 24/Aug/07 02:38 PM
Thx for the updated "testcase". I took a look but just don't have the time to load up someone's application (in this case 37 classes). Using someone's testcase means having to understand their data. Suggest that you define something smaller and more meaningful or it just won't be looked at (or as the Problem Reporting guide puts it "Your test case should have at most 4 or 5 classes"). You say it is "too slow" but you don't define what precise thing is "too slow". Is it retrieval of a collection doing too many SQLs? or something else.

Benoit Delagarde added a comment - 27/Aug/07 09:48 AM
Ok...
Thank you for the time you spend. I start this report because erik suggest me to do that.

I know that "the Problem Reporting guide" says no more than 4 or 5 classes. I have remove some other classes (I really can't do less now :-) ) and I have renamed some classes to be more comprehensive (I hope), but the schema is still enormous, I know that. This is perhaps why the makePersistent is slow.

I explain what "slow" mean for me: My Order class is holding a collection of OrderComposition (with a big schema). When the collection contain 400 objects, it take about 10s to be persisted after a "detach".