Fog Creek Software
Discussion Board




Definitions Needed...

I'm having trouble getting hold of definitions for the following terms:

- Object graph
- Course-grained object
- Fine-grained object

I have a feel for what the terms mean but would like more precise definitions. Thanks in anticipation.

Newbie
Tuesday, May 06, 2003

http://www.google.co.uk

Ged Byrne
Tuesday, May 06, 2003

Or, perhaps more precisely:

http://www.google.com/search?q=homework+help

Ged Byrne
Tuesday, May 06, 2003

Thanks Ged, you've been no help whatsoever.

Newbie
Tuesday, May 06, 2003

I didn't know what an object graph was, so I googled and found this:

Object Graph
An object is said to reference the objects held in its fields. This collection of objects forms an object graph. The memory manager actually migrates the object graphs held in static variables; that is, it migrates not only the objects held in static fields, but the objects that those objects reference, and so on.

from: http://www.csis.gvsu.edu/GeneralInfo/Oracle/java.920/a96656/glossary.htm

nathan
Tuesday, May 06, 2003

Thanks Nathan. I did have a look on Google but had trouble finding good definitions for these terms. That's helpful.

Newbie
Tuesday, May 06, 2003

Fine-grained vs. course-grained:

http://www.theserverside.com/discussion/thread.jsp?thread_id=706

Nick
Tuesday, May 06, 2003

Ged,
        I think you need to do penance. I've just searched Google for 'object graph',  'object graph + definition', 'definition of object graph' and '"object graph" definition'. I have also done a search on computer dictionaries and like Newbie have spent about ten minutes to come up with nothing useful.

        Perhaps we ought to start presuming that when people ask they have already tried Google and it hasn't helped straight off.

Stephen Jones
Tuesday, May 06, 2003

In fairness, I could have made clear at the start that I'd already spent a while searching Google. Thanks to everyone who replied, anyway.

And for the record, it's not a homework assignment - I'm a J2EE newbie!

Newbie
Tuesday, May 06, 2003


"Object graph" seems particularly vague. The first useful-looking thing I found was

http://www.inf.fu-berlin.de/inst/pubs/tr-b-99-11.abstract.html

I didn't spent too much time, thought.

Leonardo Herrera
Tuesday, May 06, 2003

My apologies newbie.

I get a little sick of people who cut an paste there homework assignments.  Sometimes they even leave in stuff like the deadline and grading schemes.  I was too quick to judge and blinded by one of my pet hates.  I did try the google search just now, and there really is nothing.

Fine grained and course grained objects are  all about the 'size' of the data items being passed.  I think the metaphor is grains of rice.  A few big chunky grains that sit in the palm of your hand, or lots of tiny ones that spill all over the place. 

This is especially important with J2EE because your making remote calls across a network.  A coarse grained objects will have a few accessors that return larger objects.  This reduces the number of network calls being made. 

The fine grained objects are best used just locallly.  The finegrained method will have more accessors that give small, detailed results.  If you used them remotely you'd have to make each call seperately with lots of overhead.
( see http://c2.com/cgi/wiki?FineGrainedDistributedObjects and http://c2.com/cgi/wiki?CoarseGrainedEntityBean )

Consider this example from Sun:

http://java.sun.com/blueprints/patterns/CompositeEntity.html

Figure 1 is how I always imagine an object graph.  It s probably something more specific than that, but I've got by so far with that type of thing.

The Customer object is Coarse Grained.  It has a limited number of calls that return objects such as account and profile.

The Address object is fine grained, it returns small values such as state, zip, streetname.

Is that enough penance?

Ged Byrne
Wednesday, May 07, 2003

That's great, Ged - thanks a lot! :-)

Newbie
Wednesday, May 07, 2003

*  Recent Topics

*  Fog Creek Home