I have some Entity beans which are aggregate like Order and it's detais line items are modelled as one single entity bean.
The problem is the ejbStore method issues a lot of SQL's to the database. I should issue SQL's for changed fields only.
I'm using BMP and Weblogic 5.1 server.
I optimize a little by using the isModified method but still for change in only one line item it issues Update SQL for all the 1000(for example) line items.
Save me or give me some hints or references.
-
Aggregate Pattern- What is the Best Design Practice (5 messages)
- Posted by: Iftear Zahid
- Posted on: September 09 2000 06:36 EDT
Threaded Messages (5)
- Aggregate Pattern- What is the Best Design Practice by Floyd Marinescu on September 10 2000 01:31 EDT
- Aggregate Pattern- What is the Best Design Practice by mickey hsieh on September 11 2000 15:32 EDT
- Aggregate Pattern- What is the Best Design Practice by Raul Fuentes on September 12 2000 11:08 EDT
- Aggregate Pattern- What is the Best Design Practice by Vijay Shrivastava on September 15 2000 06:33 EDT
- Aggregate Pattern- What is the Best Design Practice by Raul Fuentes on September 12 2000 11:08 EDT
- Aggregate Pattern- What is the Best Design Practice by Damian Guy on September 12 2000 00:48 EDT
-
Aggregate Pattern- What is the Best Design Practice[ Go to top ]
- Posted by: Floyd Marinescu
- Posted on: September 10 2000 01:31 EDT
- in response to Iftear Zahid
Why not have a separate vector in your order for line items that get changed? Once ejbStore is called, only save those line items to the database, then clear the "changed items" vector.
Floyd -
Aggregate Pattern- What is the Best Design Practice[ Go to top ]
- Posted by: mickey hsieh
- Posted on: September 11 2000 15:32 EDT
- in response to Iftear Zahid
How about use CachedRowset to aggreate your lineitems. It will propage back only the changes (include insert, edit and delete) you make.
Mickey Hsieh
CAM Commerce Solutions -
Aggregate Pattern- What is the Best Design Practice[ Go to top ]
- Posted by: Raul Fuentes
- Posted on: September 12 2000 11:08 EDT
- in response to mickey hsieh
Hi!
What´s CachedRowset?
Thanks -
Aggregate Pattern- What is the Best Design Practice[ Go to top ]
- Posted by: Vijay Shrivastava
- Posted on: September 15 2000 18:33 EDT
- in response to Raul Fuentes
CachedRowSet is a disconnected, serializable, scroabble container for tabular data.
It is for sending data to the thin clients. Sun will be providing three classes CachedRowSet, JDBCRowSet and WebRowSet for disconnected tabular data. These classes implements RowSet interface.
I it is available through JDC at java.sun.com, and will be released soon.
Hope it helps,
Vijay Shrivastava
-
Aggregate Pattern- What is the Best Design Practice[ Go to top ]
- Posted by: Damian Guy
- Posted on: September 12 2000 00:48 EDT
- in response to Iftear Zahid
Why not model this as two Entity Beans? Just store a reference to the home of the Order lines inside Order.