Revert from usage of forgerock-util module to equivalent classes from SDK
in order to fix build after switch back from OpenDJ SDK 3.0.0-SNAPSHOT
to 2.6.10-SNAPSHOT
| | |
| | | */ |
| | | package org.opends.server.replication.server.changelog.file; |
| | | |
| | | import static com.forgerock.opendj.util.Validator.*; |
| | | |
| | | import static org.opends.messages.ReplicationMessages.*; |
| | | import static org.opends.server.replication.server.changelog.api.DBCursor.KeyMatchingStrategy.*; |
| | | import static org.opends.server.replication.server.changelog.api.DBCursor.PositionStrategy.*; |
| | |
| | | import java.io.IOException; |
| | | import java.io.RandomAccessFile; |
| | | |
| | | import org.forgerock.util.Reject; |
| | | import org.opends.server.replication.server.changelog.api.ChangelogException; |
| | | import org.opends.server.replication.server.changelog.api.DBCursor.KeyMatchingStrategy; |
| | | import org.opends.server.replication.server.changelog.api.DBCursor.PositionStrategy; |
| | |
| | | final PositionStrategy positionStrategy) |
| | | throws ChangelogException |
| | | { |
| | | Reject.checkNotNull(key); |
| | | ensureNotNull(key); |
| | | final long markerPosition = searchClosestBlockStartToKey(key); |
| | | if (markerPosition >= 0) |
| | | { |
| | |
| | | */ |
| | | package org.opends.server.replication.server.changelog.file; |
| | | |
| | | import static com.forgerock.opendj.util.Validator.*; |
| | | |
| | | import static org.opends.messages.ReplicationMessages.*; |
| | | import static org.opends.server.replication.server.changelog.file.BlockLogReader.*; |
| | | |
| | |
| | | import java.io.IOException; |
| | | import java.io.SyncFailedException; |
| | | |
| | | import org.forgerock.util.Reject; |
| | | import org.opends.server.replication.server.changelog.api.ChangelogException; |
| | | import org.opends.server.types.ByteString; |
| | | import org.opends.server.types.ByteStringBuilder; |
| | |
| | | */ |
| | | private BlockLogWriter(LogWriter writer, RecordParser<K, V> parser, int blockSize) |
| | | { |
| | | Reject.ifNull(writer, parser); |
| | | ensureNotNull(writer, parser); |
| | | this.writer = writer; |
| | | this.parser = parser; |
| | | this.blockSize = blockSize; |
| | |
| | | */ |
| | | package org.opends.server.replication.server.changelog.file; |
| | | |
| | | import static com.forgerock.opendj.util.Validator.*; |
| | | |
| | | import static org.opends.messages.ReplicationMessages.*; |
| | | import static org.opends.server.replication.server.changelog.api.DBCursor.KeyMatchingStrategy.*; |
| | | import static org.opends.server.util.StaticUtils.*; |
| | |
| | | import java.util.concurrent.locks.ReadWriteLock; |
| | | import java.util.concurrent.locks.ReentrantReadWriteLock; |
| | | |
| | | import org.forgerock.util.Reject; |
| | | import org.opends.messages.Category; |
| | | import org.opends.messages.Message; |
| | | import org.opends.messages.Severity; |
| | |
| | | static synchronized <K extends Comparable<K>, V> Log<K, V> openLog(final File logPath, |
| | | final RecordParser<K, V> parser, final long sizeLimitPerFileInBytes) throws ChangelogException |
| | | { |
| | | Reject.ifNull(logPath, parser); |
| | | ensureNotNull(logPath, parser); |
| | | @SuppressWarnings("unchecked") |
| | | Log<K, V> log = (Log<K, V>) logsCache.get(logPath); |
| | | if (log == null) |
| | |
| | | */ |
| | | package org.opends.server.replication.server.changelog.file; |
| | | |
| | | import static com.forgerock.opendj.util.Validator.*; |
| | | |
| | | import static org.opends.messages.ReplicationMessages.*; |
| | | import static org.opends.server.loggers.ErrorLogger.*; |
| | | import static org.opends.server.loggers.debug.DebugLogger.*; |
| | |
| | | import java.io.IOException; |
| | | import java.io.RandomAccessFile; |
| | | |
| | | import org.forgerock.util.Reject; |
| | | import org.opends.messages.Message; |
| | | import org.opends.server.loggers.debug.DebugTracer; |
| | | import org.opends.server.replication.server.changelog.api.ChangelogException; |
| | |
| | | private LogFile(final File logFilePath, final RecordParser<K, V> parser, boolean isWriteEnabled) |
| | | throws ChangelogException |
| | | { |
| | | Reject.ifNull(logFilePath, parser); |
| | | ensureNotNull(logFilePath, parser); |
| | | this.logfile = logFilePath; |
| | | this.isWriteEnabled = isWriteEnabled; |
| | | |