[MUD-Dev] Introduction

Chris Gray cg at ami-cg.GraySage.Edmonton.AB.CA
Mon May 12 19:21:38 CEST 1997


[Ling:]
:What's a cycle?  When I mean disk based, I was thinking along the lines of
:how present LPs work, load in object, hang around in memory until swapped
:out due to lack of activity (including everyone leaving an area) or
:destroyed.  Basically, I don't know of another method of doing it.  I
:wanna keep the ability in LPs to play around objects whilst online and
:crash the place. :)

I too would like to know what a 'cycle' is in this context.

Another way to have a disk-based system is to have a cache much like
CPU's use for memory, OS's use for pages, traditional DB's use for
records, etc. When a record/whatever is needed, look for it in the
in-memory cache. If found, use and move to the head of the LRU list. If
not found, you have to read it from disk. If your cache is full (most
will have a configured maximum), then go punt the least recently used
entry, so that it will have to be re-read from disk if referenced.

You can also chose between write-though and non-write-through, just
like some CPUs let you (?). With a write-though cache, all changes are
written to disk right away. With non-write-through, the changes are just
made in the cache, and the cache entry must be written to disk before
it can be purged and the space re-used. This purging can also be going
on as a background activity. I use non-write-through, and don't have
a background writer-to-disk.

LP's system sounds like more of a custom setup. It *ought* to be able
to work better, but it's also likely harder to implement properly.

--
Chris Gray   cg at ami-cg.GraySage.Edmonton.AB.CA



More information about the mud-dev-archive mailing list