Actually I think it's good idea to have two types of logs
Actually I think it's good idea to have two types of logs
Posted Nov 20, 2011 23:43 UTC (Sun) by khim (subscriber, #9252)In reply to: Interesting idea, but... by Cyberax
Parent article: That newfangled Journal thing
I think Google does it right. They have two separate types of logs:
1) Binary structured logs which are moved to centralized storage, kept for a long time and are used for a lot of things.
2) Debug free-text logs which are only kept around till server is restarted.
Sometimes messages generated in logs of second type are deemed valuable enough and are "promoted": at this point unique message type should be added, message should be documented, etc. Adding unique UUID is trivial in comparison :-)
I doubt it makes much sense to force structure on all log messages which program can ever generate. If log record is supposed to be analyzed exclusively by humans then it's Ok to use free-form text for it. If it can be used by other software then it's time to organize and document it.
