def format(self, record):
data = record._raw.copy()<EOL>data['<STR_LIT:time>'] = data['<STR_LIT:time>'].isoformat()<EOL>if data.get('<STR_LIT>'):<EOL><INDENT>data['<STR_LIT>'] = self.formatException(data['<STR_LIT>'])<EOL><DEDENT>return json.dumps(data)<EOL>
JSON-encode a record for serializing through redis.

Convert date to iso format, and stringify any exceptions.