_______ .__ .__ .__ .__ \ \ ____ __ __ _______ |__|| | | | |__| ____ ____ / | \ _/ __ \ | | \\_ __ \| || | | | | | / _ \ / \ / | \\ ___/ | | / | | \/| || |__| |__| |( <_> )| | \ \____|__ / \___ >|____/ |__| |__||____/|____/|__| \____/ |___| / =========\/======\/=================================================\/== v0.01 04/JUL/2007 (C) Copyright 2007-2007 Scott D. Yelich SOME RIGHTS RESERVED .,-*~'`^`'~*-,._.,-*~'`^`'~*-,._.,-*~'`^`'~*-,._.-*~'`^`'~*-,._.,-*~'`^`'~*-,. This is the "README" for the Neurillion free web page counter "bug" v1 http://www.neurillion.com/p/33/counters/bug/v1/README The software is released under Creative Commons - Attribution 3.0 unported see: http://creativecommons.org/licenses/by/3.0/legalcode See "LICENSE" for text, URL above for latest version. See "INSTALL" for information on installation (and usage). There are a few helper programs to set and get hits. In exec, there is a small shell script to get the current hits value and output in an HTTP compatible way. There are also helper programs "hit" and "hits" ... These will need to be edited to point to your database. See "TODO" for ideas about what could be done in a next version. WARNING: Any file that can be opened for reading may be accessed via the image path feature of this counter. The idea with this counter is get a quick and dirty web page counter going as fast as possible. In fact, this counter doesn't even display the count, it only records the hit. What's the deal with sqlite3? Two things, first, I've seen counters that just read a file to get a count, increase the count and then write back out to the file. It seems to me that this would "lose" hits if multiple came in at a time. What if two (or more) hits came in at the same time, where both read the same value from the file before the updated value was writte back out? In any case, the use of the database is intended to be an exercise with sqlite3 and also to try to address this issue of concurrency. Although sqlite3 doesn't support client/server concurrency, it does lock the file for writing, thus with simple checks (that aren't in v1), the system should be able to pause and retry until it's able to write. Also, the increasing of the counter needs to be done with an SQL statement, not by taking the count out, incrementing and writing back into the database -- or this is no different than writing to a file and brings back the issue described above. Enjoy! Scott