probe-lab / zikade

A Go implementation of the libp2p Kademlia DHT specification
Other
12 stars 3 forks source link

Query stats not updating #29

Open iand opened 1 year ago

iand commented 1 year ago

Migrated from https://github.com/libp2p/go-libp2p-kad-dht/issues/944

The EventQueryProgressed event received by waitForQuery doesn't have accurate stats. For example the following query does not have an accurate start time and the number of requests is unchanged over time:

2023-09-27T15:56:17.932+0100    DEBUG   query made progress {"query_id": "0000000000000005", "peer_id": "QmbLHAnMoJPWSCR5Zhtx6BHJX9KiKNN6tpvbUcqanj75Nb", "elapsed": 9223372036.854776, "requests": 0, "failures": 0}
2023-09-27T15:56:18.058+0100    DEBUG   query made progress {"query_id": "0000000000000005", "peer_id": "QmNnooDu7bfjPFoTZYxMNLWUQJyrVwtbZg5gBMjTezGAJN", "elapsed": 9223372036.854776, "requests": 0, "failures": 0}
2023-09-27T15:56:18.228+0100    DEBUG   query made progress {"query_id": "0000000000000005", "peer_id": "12D3KooWDXvBTyoFtdh3WZt18oQs9rEgBVVgoo2YPW9WFsgvbF1Z", "elapsed": 9223372036.854776, "requests": 0, "failures": 0}
2023-09-27T15:56:18.305+0100    DEBUG   query made progress {"query_id": "0000000000000005", "peer_id": "12D3KooWQSmp7ij4nDx6Z1y8myBhZgaKYf9PmX8RJXvHKxf63tXf", "elapsed": 9223372036.854776, "requests": 0, "failures": 0}
2023-09-27T15:56:18.344+0100    DEBUG   query made progress {"query_id": "0000000000000005", "peer_id": "12D3KooWAXJgmkWuYjmGsRfcLcw712Xo2gL94BgR2dV7dGfFdpBz", "elapsed": 9223372036.854776, "requests": 0, "failures": 0}
2023-09-27T15:56:18.479+0100    DEBUG   query made progress {"query_id": "0000000000000005", "peer_id": "12D3KooWE5WcfiAG8NbZoGETDFStgnG9X9D628whJmEPKw3qWutz", "elapsed": 9223372036.854776, "requests": 0, "failures": 0}
2023-09-27T15:56:18.637+0100    DEBUG   query made progress {"query_id": "0000000000000005", "peer_id": "12D3KooWK4x8Azr4Tj5TsVpeDxzxRpUpFVSwT7zGU5x1LTYCYz6c", "elapsed": 9223372036.854776, "requests": 0, "failures": 0}
2023-09-27T15:56:18.745+0100    DEBUG   query made progress {"query_id": "0000000000000005", "peer_id": "12D3KooWQ4BzSdQ9fABqJfUgPEYd9Xwg6ztUW7kvSJxePs5Bmo9H", "elapsed": 9223372036.854776, "requests": 0, "failures": 0}
2023-09-27T15:56:18.759+0100    DEBUG   query made progress {"query_id": "0000000000000005", "peer_id": "12D3KooWHQZJxV5KRix1uUCy6N1ExAZpN557Kxc9t1HwZocp5N2T", "elapsed": 9223372036.854776, "requests": 0, "failures": 0}
2023-09-27T15:56:19.056+0100    DEBUG   query made progress {"query_id": "0000000000000005", "peer_id": "12D3KooWMVwrvy9mtKp2vTyGbqy6wWWFWd2zAuJf39UWNCYtfWGU", "elapsed": 9223372036.854776, "requests": 0, "failures": 0}