salesforce / p4-fusion

A fast Perforce to Git conversion tool written in C++ using Perforce Helix Core C++ API and Libgit2
BSD 3-Clause "New" or "Revised" License
78 stars 17 forks source link

Optionally display a flag saying the file came from a proxy cache #39

Open twarit-waikar opened 2 years ago

twarit-waikar commented 2 years ago

When using p4-fusion with a Perforce proxy server, it is sometimes beneficial for performance debugging purposes to know the proxy cache hit/miss rate while downloading files through p4 print

This is usually done by adding a -Zproxyverbose tag in the p4 CLI:

p4 -Zproxyverbose sync

We can specify the same tag when we create the P4API contexts. https://github.com/salesforce/p4-fusion/blob/6746b6065719517b10739d5eda87a2c906822fcd/p4-fusion/p4_api.cc#L50

And then we should be able to log that information through p4-fusion, either simply to stdout or add it in the commit message