[vworld-tech] Re: Database usage

Richard richard at ccpgames.com
Sat Feb 14 02:12:51 PST 2004


Brian Hook wrote:
>
> - how do others use the database?  How frequently is the DB hit?  I'm 
> currently caching query results to minimize the traffic to the DB 
> server.  Do people actually query the DB at run-time or do they try to 
> only do it at load time?
> 

We cache as much as we can and where we aren't currently caching
data, we keep an eye out for stuff that needs to be.  Database load
is a big concern for us and caching makes all the difference.
The database administrator emails out a list of the heaviest
database uses on a frequent basis which we try to address.

The database is hit as infrequently as possible.  Keeping it from
becoming a bottleneck is a big concern and where we identify stored
procedures that are called frequently we try and reduce the number
of calls as much as we can.

We do most of our querying at load times.  Most of the static
data is loaded when the servers come up and where data applies to
a solarsystem it is loaded when the solarsystem is and flushed
when the solarsystem isn't.  Although there is talk to keep that
data cached as well.

> - what kind of performance issues should I start stressing about?
>

Well, I'm not the database administrator, but the impression I
have gotten from being around our game from alpha to live is that
you can address the database performance issues as you go.  Theres
no need to get stressed (completely unprofessional opinion).

However, while writing this I have thought about how having
cached data affects me when writing game logic code in Python.
If I have to do a database read (which is non-blocking of course)
then it gives the chance for other code to execute on the server
and the state of things has to be validated again afterwards.
But if the data is cached, then the game logic can just go about
its business. Often it makes things a lot easier just by the
convenience of having cacheable data cached.  But thats unrelated
to your question.


More information about the vworld-tech mailing list