0

Reading message from chronicle queue does not move the current index to the next cycle automatically. I get the following logs messages: 697917 [SCHEDULER#4] INFO net.openhft.chronicle.queue.impl.single.SingleChronicleQueueExcerpts - Rolled 2 times to find the next cycle file. This can occur if you appenders have not written anything for a while, leaving the cycle files with a gap.

What does this means?

My queue files are : 20160824.cq4 20160826.cq4 20160829.cq4 20160830.cq4. The 20160825.cq4 file does not exist, because there was no data added to the queue.

Peter Lawrey
  • 525,659
  • 79
  • 751
  • 1,130
Hui Li
  • 51
  • 2

2 Answers2

0

Can you clarify what the error is you are getting?.

We have tests which show skipping missing cycles works both forwards and backwards.

What does this means?

You have explained it here

"The 20160825.cq4 file does not exist, because there was no data added to the queue."

which is why a cycle is skipped and you see

"Rolled 2 times to find the next cycle file. This can occur if you appenders have not written anything for a while, leaving the cycle files with a gap."

Peter Lawrey
  • 525,659
  • 79
  • 751
  • 1,130
  • Thanks! I mean I have new data on 20160824, no data on 20160825 and new data on 20160826. After a restart, the tailer starts from the first index of the first cycle which is 20160824.cq4. And after reading to the end of 20160824.cq4, the tailer does not move to the 20160826.cq4 automatically. – Hui Li Sep 02 '16 at 02:16
  • It should do as we have tests which demostrate this. Do you have the latest version? http://search.maven.org/#search%7Cga%7C1%7CChronicle%20queue if you are using this version can you post a unit test which reproduces this problem? – Peter Lawrey Sep 02 '16 at 02:32
0

This is just FYI since I can't comment as I just signed up. I was seeing a similar issue however not with the empty journals between days, just multiple days. I was getting a false return from ExcerptTailer.readDocument and noticed that the index hopped by a number greater than 2^32 between my last index and my first indicating a cycle shift. I only switched versions from

  • compile 'net.openhft:chronicle-queue:4.5.5'
  • compile 'net.openhft:chronicle-queue:4.5.27'

And the issue was resolved. As I am just in a prototyping phase I have not had a need to keep up so was quite far behind. I hope this helps and it does indeed look to be resolved for my case anyway.