Mailing List Archive: 49091 messages
  • Home
  • Script library
  • AltME Archive
  • Mailing list
  • Articles Index
  • Site search

[REBOL] Re: possible data format ... Re: Re: dbms3.r 01

From: greggirwin:mindspring at: 15-Jan-2002 23:59

Hi Pekr, << a) now I am not sure if locking should happen on index level (dangerous if someone will not use any index), or in database itself ... b) if we have no db server and our app fails, record would stay locked forever, so we would have to complicate things with some time-stamps or so ...>> If we don't have a central server script, there has to be some kind of lock publishing mechanism. The easiest way, perhaps the only feasible way, is to use a persistent marker as you suggest. In order to unlock a frozen lock you need a manual unlock feature, or a timeout specified for each lock. If you go the timeout route, you may want to implement some kind of time-extension callback feature so you can be notified if a lock you hold is going to expire, with the option to hold on to it. The manual unlock approach is probably simpler, but not nearly as slick and not suitable for unattended use. << - record-numbers - I hope it is clear enough, that 'pack-ing the database will reassign record numbers to remove holes caused by record deletion ... >> I thought the intent was to assign a UUID to each record, which it would use forever, so location was not important. << - variable record size - a block. OK - how will we map it to any rebol structure/object? I just hope that at least that number of columns are the same thru all records or I can't imagine it in other way than duplicating column names in each record, e.g. [name: "pekr" lastname: "krenzelok"], which is not good aproach to follow imo? >> I don't like wasting space any more than the next guy, but I *love* self-describing data. Since we're targeting small to moderate size data stores, I wouldn't be opposed to blocks of name/value pairs. If we load a large block of records which share common words as their column names, REBOL should handle that very efficiently, correct? --Gregg