Skip to content

Commit

Permalink
Print access statistics for top level info file in file block mode.
Browse files Browse the repository at this point in the history
  • Loading branch information
alja committed Jul 6, 2016
1 parent 148aef6 commit 6d37e03
Showing 1 changed file with 12 additions and 12 deletions.
24 changes: 12 additions & 12 deletions src/XrdFileCache/XrdFileCachePrint.cc
Original file line number Diff line number Diff line change
Expand Up @@ -109,19 +109,19 @@ void Print::printFile(const std::string& path)
}
printf("\n");
}

int n_da = 0;
{ int x = cfi.GetAccessCnt(); while (x) { x /= 10; ++n_da; } }
for (int i = 0; i < cfi.GetAccessCnt(); ++i)
{
printf("access %*d: ", n_da, i);
Info::AStat& a = statv[i];
char s[1000];
struct tm * p = localtime(&a.DetachTime);
strftime(s, 1000, "%c", p);
printf("[%s], bytesDisk=%lld, bytesRAM=%lld, bytesMissed=%lld\n", s, a.BytesDisk, a.BytesRam, a.BytesMissed);
}
}
int n_da = 0;
{ int x = cfi.GetAccessCnt(); while (x) { x /= 10; ++n_da; } }
for (int i = 0; i < cfi.GetAccessCnt(); ++i)
{
printf("access %*d: ", n_da, i);
Info::AStat& a = statv[i];
char s[1000];
struct tm * p = localtime(&a.DetachTime);
strftime(s, 1000, "%c", p);
printf("[%s], bytesDisk=%lld, bytesRAM=%lld, bytesMissed=%lld\n", s, a.BytesDisk, a.BytesRam, a.BytesMissed);
}

delete fh;
printf("\n");
}
Expand Down

0 comments on commit 6d37e03

Please sign in to comment.