Add inline comment to prevent confusion

This commit is contained in:
Simon Willnauer 2014-09-11 11:06:55 +02:00
parent 2bc58d5f77
commit 8618d3624a
1 changed files with 5 additions and 0 deletions

View File

@ -135,6 +135,11 @@ public class LocalIndexShardGateway extends AbstractIndexShardComponent implemen
if (si != null) {
if (indexShouldExists) {
version = si.getVersion();
/**
* We generate the translog ID before each lucene commit to ensure that
* we can read the current translog ID safely when we recover. The commits metadata
* therefor contains always the current / active translog ID.
*/
if (si.getUserData().containsKey(Translog.TRANSLOG_ID_KEY)) {
translogId = Long.parseLong(si.getUserData().get(Translog.TRANSLOG_ID_KEY));
} else {