def parse_record(self, record_line):
    fields = record_line.split(',')
    if fields[0]:
        key = codecs.decode(codecs.encode(fields[0], 'ascii'), 'base64')
    else:
        key = None
    if fields[1]:
        value = codecs.decode(codecs.encode(fields[1], 'ascii'), 'base64')
    else:
        value = None
    offset = int(fields[2])
    if fields[3]:
        timestamp = int(fields[3])
    else:
        timestamp = None
    return (key, value, offset, timestamp)
def parse_record(self, record_line):
    fields = record_line.split(',')
    if fields[0]:
        key = codecs.decode(codecs.encode(fields[0], 'ascii'), 'base64')
    else:
        key = None
    if fields[1]:
        value = codecs.decode(codecs.encode(fields[1], 'ascii'), 'base64')
    else:
        value = None
    offset = int(fields[2])
    if fields[3]:
        timestamp = int(fields[3])
    else:
        timestamp = None
    return (key, value, offset, timestamp)