I finished working on the webserver for tonight.. i spent almost the entire day on it. I have a logging system designed and half coded to replace the cheesy println stuff in there now. Right now it only logs the client ip, date/time (in java format), and the INTERNAL uri that the file was requested on. (another words the path to the files on the physical file system and not the virtual root).
The code i wrote tonight isn't quite right, but its a start. Basically I am trying to create an object factory to make loggers.. the idea is to support multiple logging formats in an OO style. Until recently, I didn't even know for sure what an object factory did (other than the obvious).
If anyone is following me so far, the reason I am going to so much trouble is the fact that I want to support a large number of websites eventually.. like say 500+. For 50 sites, it would make sense to have a seperate log going for each one.. by using the factory I can do this. Now 500, that would be plain stupid.. most large hosting companies create one long and then parse it to seperate the different customers. I will probably create a special class to log large sites eventually. Maybe i could even create a utility program with the distro to seperate them?
On another front, I want to create a class for the http headers.. the current system is fast, but very confusing... also I have to repeat code in a number of places.. its not OO at all.
I am thinking about creating an object cache in the server like Jigsaw has (well sort of). It caches documents in memory for the entire website.. my plan is to simply cache recent documents or documents that are frequently accessed (user configurable).
I also need to add CGI capabilities.