class ChecksumFSDataInputStream extends FSDataInputStream with Logging
An implementation of FSDataInputStream that calculates the checksum of the file that the client is reading (main file) incrementally, while it is being read. It then does checksum verification on close, to verify that the computed checksum matches the expected checksum in the checksum file.
Computing the checksum incrementally and doing the verification after file read is complete is for better performance, instead of first reading the entire file and doing verification before the client starts reading the file.
- Alphabetic
- By Inheritance
- ChecksumFSDataInputStream
- Logging
- FSDataInputStream
- IOStatisticsSource
- ByteBufferPositionedReadable
- StreamCapabilities
- CanUnbuffer
- HasEnhancedByteBufferAccess
- CanSetReadahead
- CanSetDropBehind
- HasFileDescriptor
- ByteBufferReadable
- PositionedReadable
- Seekable
- DataInputStream
- DataInput
- FilterInputStream
- InputStream
- Closeable
- AutoCloseable
- AnyRef
- Any
- Hide All
- Show All
- Public
- Protected
Instance Constructors
- new ChecksumFSDataInputStream(mainStream: FSDataInputStream, path: Path, expectedChecksumStream: FSDataInputStream, threadPool: ExecutionContext)
- mainStream
Input stream for the main file the client wants to read
- path
The path of the main file
- expectedChecksumStream
The input stream for the checksum file
- threadPool
Thread pool to use for concurrently operating on the main and checksum file
Type Members
- implicit class LogStringContext extends AnyRef
- Definition Classes
- Logging
Value Members
- final def !=(arg0: Any): Boolean
- Definition Classes
- AnyRef → Any
- final def ##: Int
- Definition Classes
- AnyRef → Any
- final def ==(arg0: Any): Boolean
- Definition Classes
- AnyRef → Any
- def MDC(key: LogKey, value: Any): MDC
- Attributes
- protected
- Definition Classes
- Logging
- final def asInstanceOf[T0]: T0
- Definition Classes
- Any
- def available(): Int
- Definition Classes
- FilterInputStream → InputStream
- Annotations
- @throws(classOf[java.io.IOException])
- def clone(): AnyRef
- Attributes
- protected[lang]
- Definition Classes
- AnyRef
- Annotations
- @throws(classOf[java.lang.CloneNotSupportedException]) @IntrinsicCandidate() @native()
- def close(): Unit
- Definition Classes
- ChecksumFSDataInputStream → FilterInputStream → InputStream → Closeable → AutoCloseable
- def closeWithoutChecksumVerification(): Unit
This is used to skip checksum verification on close.
This is used to skip checksum verification on close. Avoid using this, and it is only used for a situation where the file is opened, read, then closed multiple times, and we want to avoid doing verification each time and only want to do it once.
- final def eq(arg0: AnyRef): Boolean
- Definition Classes
- AnyRef
- def equals(arg0: AnyRef): Boolean
- Definition Classes
- AnyRef → Any
- final def getClass(): Class[_ <: AnyRef]
- Definition Classes
- AnyRef → Any
- Annotations
- @IntrinsicCandidate() @native()
- def getFileDescriptor(): FileDescriptor
- Definition Classes
- FSDataInputStream → HasFileDescriptor
- Annotations
- @throws(classOf[java.io.IOException])
- def getIOStatistics(): IOStatistics
- Definition Classes
- FSDataInputStream → IOStatisticsSource
- def getPos(): Long
- Definition Classes
- FSDataInputStream → Seekable
- Annotations
- @throws(classOf[java.io.IOException])
- def getWrappedStream(): InputStream
- Definition Classes
- FSDataInputStream
- Annotations
- @Public() @Stable()
- def hasCapability(arg0: String): Boolean
- Definition Classes
- FSDataInputStream → StreamCapabilities
- def hashCode(): Int
- Definition Classes
- AnyRef → Any
- Annotations
- @IntrinsicCandidate() @native()
- def initializeLogIfNecessary(isInterpreter: Boolean, silent: Boolean): Boolean
- Attributes
- protected
- Definition Classes
- Logging
- def initializeLogIfNecessary(isInterpreter: Boolean): Unit
- Attributes
- protected
- Definition Classes
- Logging
- final def isInstanceOf[T0]: Boolean
- Definition Classes
- Any
- def isTraceEnabled(): Boolean
- Attributes
- protected
- Definition Classes
- Logging
- def log: Logger
- Attributes
- protected
- Definition Classes
- Logging
- def logBasedOnLevel(level: Level)(f: => MessageWithContext): Unit
- Attributes
- protected
- Definition Classes
- Logging
- def logDebug(msg: => String, throwable: Throwable): Unit
- Attributes
- protected
- Definition Classes
- Logging
- def logDebug(entry: LogEntry, throwable: Throwable): Unit
- Attributes
- protected
- Definition Classes
- Logging
- def logDebug(entry: LogEntry): Unit
- Attributes
- protected
- Definition Classes
- Logging
- def logDebug(msg: => String): Unit
- Attributes
- protected
- Definition Classes
- Logging
- def logError(msg: => String, throwable: Throwable): Unit
- Attributes
- protected
- Definition Classes
- Logging
- def logError(entry: LogEntry, throwable: Throwable): Unit
- Attributes
- protected
- Definition Classes
- Logging
- def logError(entry: LogEntry): Unit
- Attributes
- protected
- Definition Classes
- Logging
- def logError(msg: => String): Unit
- Attributes
- protected
- Definition Classes
- Logging
- def logInfo(msg: => String, throwable: Throwable): Unit
- Attributes
- protected
- Definition Classes
- Logging
- def logInfo(entry: LogEntry, throwable: Throwable): Unit
- Attributes
- protected
- Definition Classes
- Logging
- def logInfo(entry: LogEntry): Unit
- Attributes
- protected
- Definition Classes
- Logging
- def logInfo(msg: => String): Unit
- Attributes
- protected
- Definition Classes
- Logging
- def logName: String
- Attributes
- protected
- Definition Classes
- Logging
- def logTrace(msg: => String, throwable: Throwable): Unit
- Attributes
- protected
- Definition Classes
- Logging
- def logTrace(entry: LogEntry, throwable: Throwable): Unit
- Attributes
- protected
- Definition Classes
- Logging
- def logTrace(entry: LogEntry): Unit
- Attributes
- protected
- Definition Classes
- Logging
- def logTrace(msg: => String): Unit
- Attributes
- protected
- Definition Classes
- Logging
- def logWarning(msg: => String, throwable: Throwable): Unit
- Attributes
- protected
- Definition Classes
- Logging
- def logWarning(entry: LogEntry, throwable: Throwable): Unit
- Attributes
- protected
- Definition Classes
- Logging
- def logWarning(entry: LogEntry): Unit
- Attributes
- protected
- Definition Classes
- Logging
- def logWarning(msg: => String): Unit
- Attributes
- protected
- Definition Classes
- Logging
- def mark(arg0: Int): Unit
- Definition Classes
- FilterInputStream → InputStream
- def markSupported(): Boolean
- Definition Classes
- FilterInputStream → InputStream
- def maxReadSizeForVectorReads(): Int
- Definition Classes
- FSDataInputStream → PositionedReadable
- def minSeekForVectorReads(): Int
- Definition Classes
- FSDataInputStream → PositionedReadable
- final def ne(arg0: AnyRef): Boolean
- Definition Classes
- AnyRef
- final def notify(): Unit
- Definition Classes
- AnyRef
- Annotations
- @IntrinsicCandidate() @native()
- final def notifyAll(): Unit
- Definition Classes
- AnyRef
- Annotations
- @IntrinsicCandidate() @native()
- def read(arg0: Long, arg1: ByteBuffer): Int
- Definition Classes
- FSDataInputStream → ByteBufferPositionedReadable
- Annotations
- @throws(classOf[java.io.IOException])
- final def read(arg0: ByteBufferPool, arg1: Int): ByteBuffer
- Definition Classes
- FSDataInputStream
- Annotations
- @throws(classOf[java.io.IOException]) @throws(classOf[java.lang.UnsupportedOperationException])
- def read(arg0: ByteBufferPool, arg1: Int, arg2: EnumSet[ReadOption]): ByteBuffer
- Definition Classes
- FSDataInputStream → HasEnhancedByteBufferAccess
- Annotations
- @throws(classOf[java.io.IOException]) @throws(classOf[java.lang.UnsupportedOperationException])
- def read(arg0: ByteBuffer): Int
- Definition Classes
- FSDataInputStream → ByteBufferReadable
- Annotations
- @throws(classOf[java.io.IOException])
- def read(arg0: Long, arg1: Array[Byte], arg2: Int, arg3: Int): Int
- Definition Classes
- FSDataInputStream → PositionedReadable
- Annotations
- @throws(classOf[java.io.IOException])
- final def read(arg0: Array[Byte], arg1: Int, arg2: Int): Int
- Definition Classes
- DataInputStream → FilterInputStream → InputStream
- Annotations
- @throws(classOf[java.io.IOException])
- final def read(arg0: Array[Byte]): Int
- Definition Classes
- DataInputStream → FilterInputStream → InputStream
- Annotations
- @throws(classOf[java.io.IOException])
- def read(): Int
- Definition Classes
- FilterInputStream → InputStream
- Annotations
- @throws(classOf[java.io.IOException])
- def readAllBytes(): Array[Byte]
- Definition Classes
- InputStream
- Annotations
- @throws(classOf[java.io.IOException])
- final def readBoolean(): Boolean
- Definition Classes
- DataInputStream → DataInput
- Annotations
- @throws(classOf[java.io.IOException])
- final def readByte(): Byte
- Definition Classes
- DataInputStream → DataInput
- Annotations
- @throws(classOf[java.io.IOException])
- final def readChar(): Char
- Definition Classes
- DataInputStream → DataInput
- Annotations
- @throws(classOf[java.io.IOException])
- final def readDouble(): Double
- Definition Classes
- DataInputStream → DataInput
- Annotations
- @throws(classOf[java.io.IOException])
- final def readFloat(): Float
- Definition Classes
- DataInputStream → DataInput
- Annotations
- @throws(classOf[java.io.IOException])
- def readFully(arg0: Long, arg1: ByteBuffer): Unit
- Definition Classes
- FSDataInputStream → ByteBufferPositionedReadable
- Annotations
- @throws(classOf[java.io.IOException])
- def readFully(arg0: Long, arg1: Array[Byte]): Unit
- Definition Classes
- FSDataInputStream → PositionedReadable
- Annotations
- @throws(classOf[java.io.IOException])
- def readFully(arg0: Long, arg1: Array[Byte], arg2: Int, arg3: Int): Unit
- Definition Classes
- FSDataInputStream → PositionedReadable
- Annotations
- @throws(classOf[java.io.IOException])
- final def readFully(arg0: Array[Byte], arg1: Int, arg2: Int): Unit
- Definition Classes
- DataInputStream → DataInput
- Annotations
- @throws(classOf[java.io.IOException])
- final def readFully(arg0: Array[Byte]): Unit
- Definition Classes
- DataInputStream → DataInput
- Annotations
- @throws(classOf[java.io.IOException])
- final def readInt(): Int
- Definition Classes
- DataInputStream → DataInput
- Annotations
- @throws(classOf[java.io.IOException])
- final def readLong(): Long
- Definition Classes
- DataInputStream → DataInput
- Annotations
- @throws(classOf[java.io.IOException])
- def readNBytes(arg0: Array[Byte], arg1: Int, arg2: Int): Int
- Definition Classes
- InputStream
- Annotations
- @throws(classOf[java.io.IOException])
- def readNBytes(arg0: Int): Array[Byte]
- Definition Classes
- InputStream
- Annotations
- @throws(classOf[java.io.IOException])
- final def readShort(): Short
- Definition Classes
- DataInputStream → DataInput
- Annotations
- @throws(classOf[java.io.IOException])
- final def readUTF(): String
- Definition Classes
- DataInputStream → DataInput
- Annotations
- @throws(classOf[java.io.IOException])
- final def readUnsignedByte(): Int
- Definition Classes
- DataInputStream → DataInput
- Annotations
- @throws(classOf[java.io.IOException])
- final def readUnsignedShort(): Int
- Definition Classes
- DataInputStream → DataInput
- Annotations
- @throws(classOf[java.io.IOException])
- def readVectored(arg0: List[_ <: FileRange], arg1: IntFunction[ByteBuffer], arg2: Consumer[ByteBuffer]): Unit
- Definition Classes
- FSDataInputStream → PositionedReadable
- Annotations
- @throws(classOf[java.io.IOException])
- def readVectored(arg0: List[_ <: FileRange], arg1: IntFunction[ByteBuffer]): Unit
- Definition Classes
- FSDataInputStream → PositionedReadable
- Annotations
- @throws(classOf[java.io.IOException])
- def releaseBuffer(arg0: ByteBuffer): Unit
- Definition Classes
- FSDataInputStream → HasEnhancedByteBufferAccess
- def reset(): Unit
- Definition Classes
- FilterInputStream → InputStream
- Annotations
- @throws(classOf[java.io.IOException])
- def seek(arg0: Long): Unit
- Definition Classes
- FSDataInputStream → Seekable
- Annotations
- @throws(classOf[java.io.IOException])
- def seekToNewSource(arg0: Long): Boolean
- Definition Classes
- FSDataInputStream → Seekable
- Annotations
- @throws(classOf[java.io.IOException])
- def setDropBehind(arg0: Boolean): Unit
- Definition Classes
- FSDataInputStream → CanSetDropBehind
- Annotations
- @throws(classOf[java.io.IOException]) @throws(classOf[java.lang.UnsupportedOperationException])
- def setReadahead(arg0: Long): Unit
- Definition Classes
- FSDataInputStream → CanSetReadahead
- Annotations
- @throws(classOf[java.io.IOException]) @throws(classOf[java.lang.UnsupportedOperationException])
- def skip(arg0: Long): Long
- Definition Classes
- FilterInputStream → InputStream
- Annotations
- @throws(classOf[java.io.IOException])
- final def skipBytes(arg0: Int): Int
- Definition Classes
- DataInputStream → DataInput
- Annotations
- @throws(classOf[java.io.IOException])
- def skipNBytes(arg0: Long): Unit
- Definition Classes
- InputStream
- Annotations
- @throws(classOf[java.io.IOException])
- final def synchronized[T0](arg0: => T0): T0
- Definition Classes
- AnyRef
- def toString(): String
- Definition Classes
- FSDataInputStream → AnyRef → Any
- def transferTo(arg0: OutputStream): Long
- Definition Classes
- InputStream
- Annotations
- @throws(classOf[java.io.IOException])
- def unbuffer(): Unit
- Definition Classes
- FSDataInputStream → CanUnbuffer
- final def wait(arg0: Long, arg1: Int): Unit
- Definition Classes
- AnyRef
- Annotations
- @throws(classOf[java.lang.InterruptedException])
- final def wait(arg0: Long): Unit
- Definition Classes
- AnyRef
- Annotations
- @throws(classOf[java.lang.InterruptedException]) @native()
- final def wait(): Unit
- Definition Classes
- AnyRef
- Annotations
- @throws(classOf[java.lang.InterruptedException])
- def withLogContext(context: Map[String, String])(body: => Unit): Unit
- Attributes
- protected
- Definition Classes
- Logging
Deprecated Value Members
- def finalize(): Unit
- Attributes
- protected[lang]
- Definition Classes
- AnyRef
- Annotations
- @throws(classOf[java.lang.Throwable]) @Deprecated
- Deprecated
(Since version 9)
- final def readLine(): String
- Definition Classes
- DataInputStream → DataInput
- Annotations
- @throws(classOf[java.io.IOException]) @Deprecated
- Deprecated