peeringdb / peeringdb-py

PeeringDB python client
BSD 2-Clause "Simplified" License
89 stars 22 forks source link

with --fetch-private ixlan is not being cached #92

Open ccaputo opened 3 months ago

ccaputo commented 3 months ago

ixlan is apparently not being cached when --fetch-private is used:

$ peeringdb --version
peeringdb 2.0.0

$ django-admin --version
5.0.6

$ time peeringdb sync --fetch-private
Syncing to https://www.peeringdb.com/api
[org] Fetching from API 
[org] Processing 0 objects
[campus] Fetching from API 
[campus] Processing 0 objects
[fac] Fetching from API 
[fac] Processing 0 objects
[net] Fetching from API 
[net] Processing 0 objects
[ix] Fetching from API 
[ix] Processing 0 objects
[carrier] Fetching from API 
[carrier] Processing 0 objects
[carrierfac] Fetching from API 
[carrierfac] Processing 0 objects
[ixfac] Fetching from API 
[ixfac] Processing 0 objects
[ixlan] Fetching from API (private)
[ixlan] Processing 1197 objects
[ixpfx] Fetching from API 
[ixpfx] Processing 0 objects
[netfac] Fetching from API 
[netfac] Processing 0 objects
[netixlan] Fetching from API 
[netixlan] Processing 0 objects
[poc] Fetching from API (private)
[poc] Processing 0 objects

real    0m19.632s
user    0m9.774s
sys     0m1.151s

$ time peeringdb sync --fetch-private
Syncing to https://www.peeringdb.com/api
[org] Fetching from API 
[org] Processing 0 objects
[campus] Fetching from API 
[campus] Processing 0 objects
[fac] Fetching from API 
[fac] Processing 0 objects
[net] Fetching from API 
[net] Processing 0 objects
[ix] Fetching from API 
[ix] Processing 0 objects
[carrier] Fetching from API 
[carrier] Processing 0 objects
[carrierfac] Fetching from API 
[carrierfac] Processing 0 objects
[ixfac] Fetching from API 
[ixfac] Processing 0 objects
[ixlan] Fetching from API (private)
[ixlan] Processing 1197 objects
[ixpfx] Fetching from API 
[ixpfx] Processing 0 objects
[netfac] Fetching from API 
[netfac] Processing 0 objects
[netixlan] Fetching from API 
[netixlan] Processing 0 objects
[poc] Fetching from API (private)
[poc] Processing 0 objects

real    0m20.466s
user    0m9.058s
sys     0m0.739s

Recommend this be figured out. I can reproduce this, but @vegu was not able to yet. sqlite3 file is available from me if helpful.