Re: The wisdom of the object mentors (Was: Searching OO Associations with RDBMS Persistence Models)

From: Robert Martin <>
Date: Fri, 2 Jun 2006 07:27:39 -0500
Message-ID: <2006060207273975249-unclebob_at_objectmentorcom>

On 2006-05-31 12:24:44 -0500, Joe Van Dyk <> said:

> Mikito Harakiri wrote:

>> Robert Martin wrote:
>>> Application developers get into trouble when they DONT treat the
>>> database as a detail.

>> Robert, you claim 35 years of application programming experience. Have
>> you ever come across a performance problem when database is accessed
>> via API
>> getItemIdList
>> getItemDetail
>> so that a single jsp page issued a hundred SQL statements instead of a
>> single one? Come on, this one is so common that it surfaces on every
>> performance meeting.

Have I come accross it? Sure. Do I think it's good design? No. The JSP page shouldn't be making low level service calls like that. The JSP page should make a few high level calls to the application, and the application should set up the data structures that the JSP needs to display. Then the JSP can make very simple accessor calls into that data and display it as needed.

> This problem is easily solved via caching.

I would not have the JSP repeat the SQL many times, either directly or through calls to simple minded accessors.

Robert C. Martin (Uncle Bob)  | email:
Object Mentor Inc.            | blog:
The Agile Transition Experts  | web:
800-338-6716                  |
Received on Fri Jun 02 2006 - 14:27:39 CEST

Original text of this message