Skip to content

Commit 5d4acf4

Browse files
Zainullin DamirZainullin Damir
authored andcommitted
++
1 parent 2e320f9 commit 5d4acf4

1 file changed

Lines changed: 4 additions & 3 deletions

File tree

tests/performance/outputStorage/dummyReader.hpp

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -25,16 +25,17 @@ class DummyReader {
2525
std::size_t readContainers() noexcept
2626
{
2727
// m_storage.registerReader(m_readerGroupIndex);
28+
std::size_t printCounter{};
2829
ipxp::output::OutputStorage::ReadHandler readHandler
2930
= m_readerGroupHandler.getReaderHandler();
3031
while (!readHandler.finished()) {
3132
while (readHandler.getFlowRecord() != nullptr) {
32-
if (std::chrono::steady_clock::now() - m_lastPrintTime > std::chrono::seconds(20)) {
33+
if (counter++ % (1ULL << 35)) {
3334
const std::string message = "Reader "
3435
+ std::to_string(readHandler.getReaderIndex()) + " read "
3536
+ std::to_string(readHandler.readContainers()) + " containers so far.";
3637
std::cout << message << std::endl;
37-
m_lastPrintTime = std::chrono::steady_clock::now();
38+
// m_lastPrintTime = std::chrono::steady_clock::now();
3839
}
3940
}
4041
}
@@ -46,5 +47,5 @@ class DummyReader {
4647
// std::size_t m_readerGroupIndex;
4748
ipxp::output::OutputStorage::ReaderGroupHandler& m_readerGroupHandler;
4849
bool m_immitateWork;
49-
std::chrono::steady_clock::time_point m_lastPrintTime = std::chrono::steady_clock::now();
50+
//std::chrono::steady_clock::time_point m_lastPrintTime = std::chrono::steady_clock::now();
5051
};

0 commit comments

Comments
 (0)