1. A method by a computer comprising: for each of a plurality of log records received as part of a log stream from a host machine node; identifying a template identifier within a template repository for a template string matching an invariant string of the log record; identifying an attribute identifier in an attribute repository for an attribute string matching a variant string of the log record; partitioning the log records into batches, each of the batches defined by a data structure comprising the template identifier and the attribute identifier for each of the log records within the batch; and storing the data structures for each of the batches into a log repository.