Search in sources :

Example 1 with CacheType

use of org.apache.hadoop.hdds.utils.db.cache.TableCache.CacheType in project ozone by apache.

the class OmMetadataManagerImpl method initializeOmTables.

/**
 * Initialize OM Tables.
 *
 * @throws IOException
 */
protected void initializeOmTables() throws IOException {
    userTable = this.store.getTable(USER_TABLE, String.class, PersistedUserVolumeInfo.class);
    checkTableStatus(userTable, USER_TABLE);
    CacheType cacheType = CacheType.FULL_CACHE;
    volumeTable = this.store.getTable(VOLUME_TABLE, String.class, OmVolumeArgs.class, cacheType);
    checkTableStatus(volumeTable, VOLUME_TABLE);
    bucketTable = this.store.getTable(BUCKET_TABLE, String.class, OmBucketInfo.class, cacheType);
    checkTableStatus(bucketTable, BUCKET_TABLE);
    keyTable = this.store.getTable(KEY_TABLE, String.class, OmKeyInfo.class);
    checkTableStatus(keyTable, KEY_TABLE);
    deletedTable = this.store.getTable(DELETED_TABLE, String.class, RepeatedOmKeyInfo.class);
    checkTableStatus(deletedTable, DELETED_TABLE);
    openKeyTable = this.store.getTable(OPEN_KEY_TABLE, String.class, OmKeyInfo.class);
    checkTableStatus(openKeyTable, OPEN_KEY_TABLE);
    multipartInfoTable = this.store.getTable(MULTIPARTINFO_TABLE, String.class, OmMultipartKeyInfo.class);
    checkTableStatus(multipartInfoTable, MULTIPARTINFO_TABLE);
    dTokenTable = this.store.getTable(DELEGATION_TOKEN_TABLE, OzoneTokenIdentifier.class, Long.class);
    checkTableStatus(dTokenTable, DELEGATION_TOKEN_TABLE);
    s3SecretTable = this.store.getTable(S3_SECRET_TABLE, String.class, S3SecretValue.class);
    checkTableStatus(s3SecretTable, S3_SECRET_TABLE);
    prefixTable = this.store.getTable(PREFIX_TABLE, String.class, OmPrefixInfo.class);
    checkTableStatus(prefixTable, PREFIX_TABLE);
    dirTable = this.store.getTable(DIRECTORY_TABLE, String.class, OmDirectoryInfo.class);
    checkTableStatus(dirTable, DIRECTORY_TABLE);
    fileTable = this.store.getTable(FILE_TABLE, String.class, OmKeyInfo.class);
    checkTableStatus(fileTable, FILE_TABLE);
    openFileTable = this.store.getTable(OPEN_FILE_TABLE, String.class, OmKeyInfo.class);
    checkTableStatus(openFileTable, OPEN_FILE_TABLE);
    deletedDirTable = this.store.getTable(DELETED_DIR_TABLE, String.class, OmKeyInfo.class);
    checkTableStatus(deletedDirTable, DELETED_DIR_TABLE);
    transactionInfoTable = this.store.getTable(TRANSACTION_INFO_TABLE, String.class, TransactionInfo.class);
    checkTableStatus(transactionInfoTable, TRANSACTION_INFO_TABLE);
    metaTable = this.store.getTable(META_TABLE, String.class, String.class);
    checkTableStatus(metaTable, META_TABLE);
}
Also used : OmBucketInfo(org.apache.hadoop.ozone.om.helpers.OmBucketInfo) OmVolumeArgs(org.apache.hadoop.ozone.om.helpers.OmVolumeArgs) OmPrefixInfo(org.apache.hadoop.ozone.om.helpers.OmPrefixInfo) S3SecretValue(org.apache.hadoop.ozone.om.helpers.S3SecretValue) PersistedUserVolumeInfo(org.apache.hadoop.ozone.storage.proto.OzoneManagerStorageProtos.PersistedUserVolumeInfo) CacheType(org.apache.hadoop.hdds.utils.db.cache.TableCache.CacheType) RepeatedOmKeyInfo(org.apache.hadoop.ozone.om.helpers.RepeatedOmKeyInfo) OmMultipartKeyInfo(org.apache.hadoop.ozone.om.helpers.OmMultipartKeyInfo) OzoneTokenIdentifier(org.apache.hadoop.ozone.security.OzoneTokenIdentifier) OmKeyInfo(org.apache.hadoop.ozone.om.helpers.OmKeyInfo) RepeatedOmKeyInfo(org.apache.hadoop.ozone.om.helpers.RepeatedOmKeyInfo) TransactionInfo(org.apache.hadoop.hdds.utils.TransactionInfo) OmDirectoryInfo(org.apache.hadoop.ozone.om.helpers.OmDirectoryInfo)

Aggregations

TransactionInfo (org.apache.hadoop.hdds.utils.TransactionInfo)1 CacheType (org.apache.hadoop.hdds.utils.db.cache.TableCache.CacheType)1 OmBucketInfo (org.apache.hadoop.ozone.om.helpers.OmBucketInfo)1 OmDirectoryInfo (org.apache.hadoop.ozone.om.helpers.OmDirectoryInfo)1 OmKeyInfo (org.apache.hadoop.ozone.om.helpers.OmKeyInfo)1 OmMultipartKeyInfo (org.apache.hadoop.ozone.om.helpers.OmMultipartKeyInfo)1 OmPrefixInfo (org.apache.hadoop.ozone.om.helpers.OmPrefixInfo)1 OmVolumeArgs (org.apache.hadoop.ozone.om.helpers.OmVolumeArgs)1 RepeatedOmKeyInfo (org.apache.hadoop.ozone.om.helpers.RepeatedOmKeyInfo)1 S3SecretValue (org.apache.hadoop.ozone.om.helpers.S3SecretValue)1 OzoneTokenIdentifier (org.apache.hadoop.ozone.security.OzoneTokenIdentifier)1 PersistedUserVolumeInfo (org.apache.hadoop.ozone.storage.proto.OzoneManagerStorageProtos.PersistedUserVolumeInfo)1