Package com.atlan.cache
Class OffHeapFailureCache
java.lang.Object
com.atlan.cache.AbstractOffHeapCache<String,AssetBatch.FailedBatch>
com.atlan.cache.OffHeapFailureCache
- All Implemented Interfaces:
AtlanCloseable,AutoCloseable
Generic class through which to cache any batch failures efficiently, off-heap, to avoid risking extreme
memory usage.
-
Constructor Summary
ConstructorsConstructorDescriptionOffHeapFailureCache(AtlanClient client, String name) Construct new cache for failures. -
Method Summary
Modifier and TypeMethodDescriptiondeserializeKey(byte[] bytes) deserializeValue(byte[] bytes) voidextendedWith(OffHeapFailureCache other, boolean closeOriginal) Extend this cache with all the entries from the provided cache.byte[]serializeKey(String key) byte[]Methods inherited from class com.atlan.cache.AbstractOffHeapCache
close, containsKey, entrySet, get, getName, getSize, isEmpty, isNotClosed, isNotEmpty, put, putAll, size, values
-
Constructor Details
-
OffHeapFailureCache
Construct new cache for failures.- Parameters:
client- connectivity to the Atlan tenantname- to distinguish which cache is which
-
-
Method Details
-
serializeKey
- Specified by:
serializeKeyin classAbstractOffHeapCache<String,AssetBatch.FailedBatch>
-
deserializeKey
- Specified by:
deserializeKeyin classAbstractOffHeapCache<String,AssetBatch.FailedBatch>
-
serializeValue
- Specified by:
serializeValuein classAbstractOffHeapCache<String,AssetBatch.FailedBatch>
-
deserializeValue
- Specified by:
deserializeValuein classAbstractOffHeapCache<String,AssetBatch.FailedBatch>
-
extendedWith
Extend this cache with all the entries from the provided cache.- Parameters:
other- other cache with which to extend this onecloseOriginal- if true, close the provided cache after the extension is complete
-