Compact logging of failed messages