[Seaside] my fear of database design and Seaside

Norbert Hartl norbert at hartl.name
Fri May 16 07:17:30 UTC 2008


Hi,

that is exactly the question that drove me over a year ago. I started my
project using GOODS. Than I discovered magma and developed the very
first prototype. And then there was doubt. I haven't dealt much with
OODBs until then. Letting the fear win I changed the code to use Glorp
instead. And I must confess that this was the biggest fault I've done 
in this project. Don't get me wrong it is not Glorp. Glorp is a wonder-
ful piece of software. It is just ORM that doesn't fit well in a lot
of scenarios you might develop. You can't do arbitrary references 
between objects. Inheritance is also not easy to use. ...In the end you 
deal a lot with the ORM mapping tool and even SQL. The optimization
isn't done automatically by the ORM tool. You have to know how to get
the ORM tool to work in an optimized way. If your model isn't that 
complex and interconnected you have a chance to get it right with Glorp.
In my case I had to spent a lot of work on using Glorp and my stuff is
still incredibly slow. The benefits I get from using portgres is that
you get a fulltext retrieval engine and a geo database for free.
If I would start all over again taking my experience and the changed 
situation that there is now gemstone with seaside I would give it a try.
On the other side I would recommend that you start simple. Don't think
about zillions of request you surely will have in a few months :). 
Changing the persistence layer isn't that difficult. You could start
developing without a database (the squeak image is one). Then if you 
need extra stuff change it. At the time you want to met certain feature,
concurrency or speed requirements I guess you'll know what to use.

Norbert

On Thu, 2008-05-15 at 17:27 -0700, Chris Dawson wrote:
> Hi all,
> 
> I'm plugging away and enjoying learning about Seaside.  From my
> limited reading so far I gather that there are massive benefits to
> using something like Magma or GemStone/S over traditional ORM into
> RDBMSs.  If I understand from attending Randal Schwartz's great talk
> at BarCamp here in Portland a few weeks back that Seaside can take
> complicated object structures and just stick them into a object
> database as-is without the overhead of mapping that structure into
> SQL, and that this is powerful and fast.  My concern as I design my
> application is, however, that I despite knowing the basics of database
> design and simple normalization that I will do something stupid and
> create structures that are not scalable or searchable.  When I use a
> traditional database I assume that the database designers have thought
> of a lot of the details of implementation and are forcing me into
> making choices about how to store the data so that it is at least
> moderately searchable.  I'm not saying that most of the people on this
> list could not build the right structures as Smalltalk objects.  I'm
> saying I question my own ability to do so, and Seaside seems to enable
> me to do this, which might be a great joy for you all, but which might
> be for the worst in my case.  If this is true, perhaps I should use
> GLORP over Postgres, yet I worry I will lose some of the magic pixie
> dust that made Seaside seem so different.  Or, should I not worry
> about this, as it will always be faster and more scalable to drop in a
> cluster of GemStones and do a dictionary lookup in my code than it
> will be to do a join in a MySQL database?
> 
> I do love learning about Seaside, it is stretching my brain is such
> nice ways.  Thanks in advance for your comments.
> 
> Chris
> _______________________________________________
> seaside mailing list
> seaside at lists.squeakfoundation.org
> http://lists.squeakfoundation.org/cgi-bin/mailman/listinfo/seaside



More information about the seaside mailing list