• Petr Špaček's avatar
    msgdiff: read answers from LMDB environment · 7c8fc998
    Petr Špaček authored
    Answers are stored in LMDB sub-database 'answers'.
    
    One key in the DB is one set of anwers, key is internal query ID
    (not the same as in the DNS message).
    
    Value of the key are binary data in Python pickle format.
    Unpickling it produces dictionary with structure
    {'name of the resolver': <answer in wire format>}
    
    Wire format is used instead of DNS message objects for two reasons:
    1. it allows us to store invalid answers as received from the resolver
    2. to save storage space
    7c8fc998