/*
-tofuproxy -- flexible HTTP/WARC proxy with TLS certificates management
+tofuproxy -- flexible HTTP proxy, TLS terminator, X.509 certificates
+ manager, WARC/Gemini browser
Copyright (C) 2021 Sergey Matveev <stargrave@stargrave.org>
This program is free software: you can redistribute it and/or modify
}
warc.WARCsM.RLock()
for warcPath, uris := range warc.WARCs {
- fmt.Fprintf(fd, "%s\t%d\n", warcPath, len(uris))
+ fmt.Fprintf(
+ fd, "%s\t%d\t%d\n",
+ warcPath, len(uris), len(warc.WARCs[warcPath]),
+ )
}
warc.WARCsM.RUnlock()
fd.Close()
log.Printf("%s: can not open %s: %+v\n", p, warcPath, err)
break
}
- log.Printf("%s: %s: added %d URIs\n", p, warcPath, len(warc.WARCs[warcPath]))
+ log.Printf(
+ "%s: %s: added %d URIs %d segments\n",
+ p, warcPath,
+ len(warc.WARCs[warcPath]),
+ len(warc.WARCsOffsets[warcPath]),
+ )
}
}
}