Interface FileKeyMaterialStore
- All Known Implementing Classes:
HadoopFSKeyMaterialStore
public interface FileKeyMaterialStore
-
Method Summary
Modifier and TypeMethodDescriptionvoidaddKeyMaterial(String keyIDInFile, String keyMaterial) Add key material for one encryption key.getKeyMaterial(String keyIDInFile) Get key materialvoidinitialize(org.apache.hadoop.fs.Path parquetFilePath, org.apache.hadoop.conf.Configuration hadoopConfig, boolean tempStore) Initializes key material store for a parquet file.voidmoveMaterialTo(FileKeyMaterialStore targetKeyMaterialStore) Move key material to another store.voidRemove key material from persistent store.voidAfter key material was added for all keys in the given Parquet file, save material in persistent store.
-
Method Details
-
initialize
void initialize(org.apache.hadoop.fs.Path parquetFilePath, org.apache.hadoop.conf.Configuration hadoopConfig, boolean tempStore) Initializes key material store for a parquet file.- Parameters:
parquetFilePath- Parquet file pathhadoopConfig- Hadoop configurationtempStore- set true if this is a temporary store, used in key rotation
-
addKeyMaterial
Add key material for one encryption key.- Parameters:
keyIDInFile- ID of the key in Parquet filekeyMaterial- key material
-
saveMaterial
void saveMaterial()After key material was added for all keys in the given Parquet file, save material in persistent store. -
getKeyMaterial
Get key material- Parameters:
keyIDInFile- ID of a key in Parquet file- Returns:
- key material
-
getKeyIDSet
- Returns:
- Set of all key IDs in this store (for the given Parquet file)
-
removeMaterial
void removeMaterial()Remove key material from persistent store. Used in key rotation. -
moveMaterialTo
Move key material to another store. Used in key rotation.- Parameters:
targetKeyMaterialStore- target store
-