We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? # for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “#”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? # to your account
SingleChronicleQueueStore handles writing an EOF when a cycle rolls.
The implementation has a tryReserve check, and either uses the already mapped wire (if reserve ok), or remaps a temporary wire (if reserve not ok).
tryReserve
The temporary wire differs in at least 2 important respects vs the already-mapped wire, which leads to inconsistent EOF behaviour. Specifically:
public boolean writeEOF(@NotNull Wire wire, long timeoutMS) { throwExceptionIfClosed(); String fileName = mappedFile.file().getAbsolutePath(); // just in case we are about to release this if (wire.bytes().tryReserve(this)) { try { return writeEOFAndShrink(wire, timeoutMS); } finally { wire.bytes().release(this); } } try (MappedBytes bytes = MappedBytes.mappedBytes(mappedFile.file(), mappedFile.chunkSize())) { Wire wire0 = WireType.valueOf(wire).apply(bytes); return writeEOFAndShrink(wire0, timeoutMS); } catch (Exception e) { Jvm.warn().on(getClass(), "unable to write the EOF file=" + fileName, e); return false; } }
The text was updated successfully, but these errors were encountered:
rogersimmons
No branches or pull requests
SingleChronicleQueueStore handles writing an EOF when a cycle rolls.
The implementation has a
tryReserve
check, and either uses the already mapped wire (if reserve ok), or remaps a temporary wire (if reserve not ok).The temporary wire differs in at least 2 important respects vs the already-mapped wire, which leads to inconsistent EOF behaviour. Specifically:
The text was updated successfully, but these errors were encountered: