class CachedTableManager extends Logging
- Alphabetic
- By Inheritance
- CachedTableManager
- Logging
- AnyRef
- Any
- Hide All
- Show All
- Public
- Protected
Instance Constructors
- new CachedTableManager(preSignedUrlExpirationMs: Long, refreshCheckIntervalMs: Long, refreshThresholdMs: Long, expireAfterAccessMs: Long)
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
- final def asInstanceOf[T0]: T0
- Definition Classes
- Any
- def clear(): Unit
Clear the cached pre signed urls.
Clear the cached pre signed urls. This is an internal API to clear the cache in case some users config incorrect pre signed url expiration time and leave expired urls in the cache.
- def clone(): AnyRef
- Attributes
- protected[lang]
- Definition Classes
- AnyRef
- Annotations
- @throws(classOf[java.lang.CloneNotSupportedException]) @IntrinsicCandidate() @native()
- 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 getPreSignedUrl(tablePath: String, fileId: String): GetPreSignedUrlResponse
Returns
PreSignedUrlfrom the cache. - def getQueryStateSize(tablePath: String): Int
- 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 isValidUrlExpirationTime(expiration: Option[Long]): Boolean
- def log: Logger
- 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
- 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()
- val preSignedUrlExpirationMs: Long
- def refresh(): Unit
Refreshes the pre-signed URLs in the cache.
Refreshes the pre-signed URLs in the cache. This method iterates through the cache entries, checks their validity, and updates or removes them as necessary.
- val refreshThresholdMs: Long
- def register(tablePath: String, idToUrl: Map[String, String], refs: Seq[WeakReference[AnyRef]], profileProvider: DeltaSharingProfileProvider, refresher: (Option[String]) => TableRefreshResult, expirationTimestamp: Long = System.currentTimeMillis() + preSignedUrlExpirationMs, refreshToken: Option[String], keepUrlsAfterRefsGone: Boolean = false): Unit
Register a table path in the cache.
Register a table path in the cache. The pre signed urls will be refreshed automatically to support long running queries.
- tablePath
the table path. This is usually the profile file path.
- idToUrl
the pre signed url map. This will be refreshed when the pre signed urls is going to expire.
- refs
A list of weak references which can be used to determine whether the cache is still needed. When all the weak references return null, we will remove the pre signed url cache of this table form the cache.
- profileProvider
a profile Provider that can provide customized refresher function.
- refresher
A function to re-generate pre signed urls for the table.
- expirationTimestamp
Optional, If set, it's a timestamp to indicate the expiration timestamp of the idToUrl.
- refreshToken
an optional refresh token that can be used by the refresher to retrieve the same set of files with refreshed urls.
- keepUrlsAfterRefsGone
If true, for QuerySpecificCachedTable, URLs will be kept in cache even when all references are gone, and will only be cleaned up based on cache expiry time.
- def registerQueryStatesInQuerySpecificCachedTable(tablePath: String, refs: Seq[WeakReference[AnyRef]], profileProvider: DeltaSharingProfileProvider): Unit
Adds new query states to an existing QuerySpecificCachedTable entry in the cache.
Adds new query states to an existing QuerySpecificCachedTable entry in the cache.
This method is used when a new query (with its own queryId and refresher wrapper) wants to share the same cached table entry as other queries, but only needs to add its own state (references and refresher wrapper) without modifying the rest of the table's cache entry. If the table is not a QuerySpecificCachedTable, or does not exist, this method is a no-op.
The method is atomic and thread-safe, using computeIfPresent to avoid race conditions with concurrent register or refresh operations.
- tablePath
The path of the table whose query states should be updated.
- refs
A sequence of weak references for the new query, used to track its usage.
- profileProvider
The profile provider, which supplies the queryId and refresher wrapper for the new query state.
- def size(): Int
- def stop(): Unit
- final def synchronized[T0](arg0: => T0): T0
- Definition Classes
- AnyRef
- def toString(): String
- Definition Classes
- AnyRef → Any
- 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)