[Opensim-dev] further db thoughts

Sean Dague sean at dague.net
Mon Jan 14 17:07:34 UTC 2008


On Mon, Jan 14, 2008 at 11:31:50AM +0100, Stefan Andersson wrote:
> 
>  
> ---
> Stefan, It would be motivating if you could provide a sample about how the TribalMedia data framework should work. Could that be done by implementing the very simple asset server as an example ? I propose we would make it work, make tests, comment and try to improve it, then it may serve as a baseline for the other db stuff ?
> --- 
>  
> *doh*
>  
> I'll just post the code; but beware, it doesn't work, it's just to show you how stuff would interact
>  
> (Also, the code could probably be cleaner...)
>  
> What to look for:
> * how the Schema is created and populated
> * how the m_keyFieldMapper (that is used to extract primary key from queries) is initialized
> * how the FromReader passes on to FillObject() - the function that will use the Schema to populate the RowMapper (and the PrimitiveBaseShape)
> * How the CRUD and CreateRowMapper functions are really just there to
> get a cleaner interface for the caller.

I'm a bit concerned about the ability to get SQL injection through the
process (unless I missed something).  We need to either put in filter
for that, or use the parametrized SQL for the base drivers to let them
filter that.

I'm still wrapping my head around all of it, but I like much of what I'm
seeing so far.  More later.

    -Sean

-- 
__________________________________________________________________

Sean Dague                                       Mid-Hudson Valley
sean at dague dot net                            Linux Users Group
http://dague.net                                 http://mhvlug.org

There is no silver bullet.  Plus, werewolves make better neighbors
than zombies, and they tend to keep the vampire population down.
__________________________________________________________________
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 189 bytes
Desc: Digital signature
URL: <http://opensimulator.org/pipermail/opensim-dev/attachments/20080114/545482c5/attachment-0001.pgp>


More information about the Opensim-dev mailing list