Re: WebCAT has the devil in it!
This WebDNA talk-list message is from 2003
It keeps the original formatting.
numero = 54067
interpreted = N
texte = >Sounds great Scott, but one hanging question... If I do turn it off,>which I>may not, what ultimately am I losing in functionality?Well, the engine will revert to pre 4.5.1 behavior. Meaning that if theserver or WebDNA crashes during a database write, you will lose thosedatabase records that were not yet written to disk.>PS... I would wager that any developer in my position would have>probably>rather WebCAT stop duplicating the files after a certain number(perhaps>a>pref setting). The uncontrollable nature of this scared me...jmhoThat was one of the improvements to the 5.0 version of the 'Safe Write'code. It will roll the index of the tmp filename after 10. So, there willnever be more than 10 tmp files for any given database. Preferably, ofcourse, we would never want to see any tmp db files left on disk. Havingre-visited the code today, I can see where we can improve on the existingalgorithm to 'recover' from a dangling '...-oRiGiNaL-' file. Yet another'to-do' for the 5.2 release.-----Original Message-----From: Alex McCombie [mailto:alex@newworldmedia.com]Sent: Thursday, November 13, 2003 10:45 AMTo: WebDNA TalkSubject: Re: WebCAT has the devil in it!On 11/13/03 1:34 PM, "Scott Anderson"
wrote:>> It appears that when WebCAT went to do a safe write, that it saw a>> tempDB>> already there and as such created a new one with an incrementednumber.> This is correct.>> However, this time, instead of deleting the tmp file after the safe>> write it>> left it.> What is supposed to happen is that the original db file gets renamedto> something like "my.db-oRiGiNaL-". If the rename succeeds, then thenew temp> db file is renamed to the original db name. And if that renamesucceeds,> the "my.db-oRiGiNaL-" is deleted.Bingo, there was a file created by WebCAT in there with the original inthename... Causing the continuing failure.> I suspect that an 'very' untimely crash occurred during the renameprocess> (which would be pretty rare) and left a dangling "...-oRiGiNaL-" file.This> would prevent the first rename step from completing, and would lead tothe> new incremented tmp file being left in place. IF this happens, deletethe> '...-oRiGiNaL-' file, backup your original db file, and replace itwith the> tmp db file with the largest increment.Interestingly enough, the true original file (something.db) had all theupdated data as the largest increment. Which would be slightly differentthan you mention but still worked for us.> If this happens fairly frequently on your server, the only option thatI see> would be for you to turn off that Safe Write feature. I would alsomake> sure that error logging is enabled, and check the error logs to trackand> fix templates bugs. You can also enable the 'Technical SupportInformation'> pref. This will log every hit that comes into the server to a filecalled> WebCatalog.debug. Using this file, you have a good chance of trackingthe> last template requested before each crash. You can then examine that> template code for any errors. That debug log can get pretty big, veryfast,> so only enable it when you are able to spend some time examining the> entries. If resolving template bugs improves engine stability, thenyou can> try re-enabling the SafeWrite pref.This assumes that the 'crash' had anything to do with webcat, which I donotbelieve it did. Certainly untimely and for the record the one and onlyoccurrence of this I have ever seen!> Also, it is always a good idea to perform frequent backups of your dbfiles.We do, and thankfully I coded those backups by exact name and not bydirectory. Imagine that ..lol> We will continue to improve the 'Safe Write' code for future releases,as it> is a beneficial feature.Sounds great Scott, but one hanging question... If I do turn it off,which Imay not, what ultimately am I losing in functionality?PS... I would wager that any developer in my position would haveprobablyrather WebCAT stop duplicating the files after a certain number(perhapsapref setting). The uncontrollable nature of this scared me...jmhoAlex J McCombie New World MediaChief Information Officer Box 124888/892.6379 MartVille, NY 13111Alex@NewWorldMedia.com http://OurClients.comInterface Designer WebDNA Programmer Database Designer-------------------------------------------------------------This message is sent to you because you are subscribed to the mailing list .To unsubscribe, E-mail to: To switch to the DIGEST mode, E-mail toWeb Archive of this list is at: http://webdna.smithmicro.com/-------------------------------------------------------------This message is sent to you because you are subscribed to the mailing list .To unsubscribe, E-mail to: To switch to the DIGEST mode, E-mail to Web Archive of this list is at: http://webdna.smithmicro.com/
Associated Messages, from the most recent to the oldest:
>Sounds great Scott, but one hanging question... If I do turn it off,>which I>may not, what ultimately am I losing in functionality?Well, the engine will revert to pre 4.5.1 behavior. Meaning that if theserver or WebDNA crashes during a database write, you will lose thosedatabase records that were not yet written to disk.>PS... I would wager that any developer in my position would have>probably>rather WebCAT stop duplicating the files after a certain number(perhaps>a>pref setting). The uncontrollable nature of this scared me...jmhoThat was one of the improvements to the 5.0 version of the 'Safe Write'code. It will roll the index of the tmp filename after 10. So, there willnever be more than 10 tmp files for any given database. Preferably, ofcourse, we would never want to see any tmp db files left on disk. Havingre-visited the code today, I can see where we can improve on the existingalgorithm to 'recover' from a dangling '...-oRiGiNaL-' file. Yet another'to-do' for the 5.2 release.-----Original Message-----From: Alex McCombie [mailto:alex@newworldmedia.com]Sent: Thursday, November 13, 2003 10:45 AMTo: WebDNA TalkSubject: Re: WebCAT has the devil in it!On 11/13/03 1:34 PM, "Scott Anderson" wrote:>> It appears that when WebCAT went to do a safe write, that it saw a>> tempDB>> already there and as such created a new one with an incrementednumber.> This is correct.>> However, this time, instead of deleting the tmp file after the safe>> write it>> left it.> What is supposed to happen is that the original db file gets renamedto> something like "my.db-oRiGiNaL-". If the rename succeeds, then thenew temp> db file is renamed to the original db name. And if that renamesucceeds,> the "my.db-oRiGiNaL-" is deleted.Bingo, there was a file created by WebCAT in there with the original inthename... Causing the continuing failure.> I suspect that an 'very' untimely crash occurred during the renameprocess> (which would be pretty rare) and left a dangling "...-oRiGiNaL-" file.This> would prevent the first rename step from completing, and would lead tothe> new incremented tmp file being left in place. IF this happens, deletethe> '...-oRiGiNaL-' file, backup your original db file, and replace itwith the> tmp db file with the largest increment.Interestingly enough, the true original file (something.db) had all theupdated data as the largest increment. Which would be slightly differentthan you mention but still worked for us.> If this happens fairly frequently on your server, the only option thatI see> would be for you to turn off that Safe Write feature. I would alsomake> sure that error logging is enabled, and check the error logs to trackand> fix templates bugs. You can also enable the 'Technical SupportInformation'> pref. This will log every hit that comes into the server to a filecalled> WebCatalog.debug. Using this file, you have a good chance of trackingthe> last template requested before each crash. You can then examine that> template code for any errors. That debug log can get pretty big, veryfast,> so only enable it when you are able to spend some time examining the> entries. If resolving template bugs improves engine stability, thenyou can> try re-enabling the SafeWrite pref.This assumes that the 'crash' had anything to do with webcat, which I donotbelieve it did. Certainly untimely and for the record the one and onlyoccurrence of this I have ever seen!> Also, it is always a good idea to perform frequent backups of your dbfiles.We do, and thankfully I coded those backups by exact name and not bydirectory. Imagine that ..lol> We will continue to improve the 'Safe Write' code for future releases,as it> is a beneficial feature.Sounds great Scott, but one hanging question... If I do turn it off,which Imay not, what ultimately am I losing in functionality?PS... I would wager that any developer in my position would haveprobablyrather WebCAT stop duplicating the files after a certain number(perhapsapref setting). The uncontrollable nature of this scared me...jmhoAlex J McCombie New World MediaChief Information Officer Box 124888/892.6379 MartVille, NY 13111Alex@NewWorldMedia.com http://OurClients.comInterface Designer WebDNA Programmer Database Designer-------------------------------------------------------------This message is sent to you because you are subscribed to the mailing list .To unsubscribe, E-mail to: To switch to the DIGEST mode, E-mail toWeb Archive of this list is at: http://webdna.smithmicro.com/-------------------------------------------------------------This message is sent to you because you are subscribed to the mailing list .To unsubscribe, E-mail to: To switch to the DIGEST mode, E-mail to Web Archive of this list is at: http://webdna.smithmicro.com/
"Scott Anderson"
DOWNLOAD WEBDNA NOW!
Top Articles:
Talk List
The WebDNA community talk-list is the best place to get some help: several hundred extremely proficient programmers with an excellent knowledge of WebDNA and an excellent spirit will deliver all the tips and tricks you can imagine...
Related Readings:
[WebDNA] Google like search (2016)
SetHeader not Working (2006)
WebCatalog for guestbook ? (1997)
Problems getting parameters passed into email. (1997)
Email Formatting (1998)
Major bug report on rootbeer (1997)
Re:WebCatalog f2 Installation (1997)
[OT] Test - THE ANSWER (2003)
grouped fields? (1999)
WebCat2b14MacPlugIn - [include] doesn't hide the search string (1997)
[isfile] ? (1997)
textarea data entry and display (2000)
Bit off subject -- Faxing orders (1997)
Dumb Question about Docs (1997)
[shell] (2002)
Protecting webdelivery (1997)
search results through frames (2000)
WebCat editing, SiteGuard WAS:SiteAssociative lookup style? (1997)
Protecting databases (1999)
[OT] Who's got a cool link (2002)