private static ColumnStatistics updateStatsForAlterPart(RawStore rawStore, Table before, String catalogName,
      String dbName, String tableName, Partition part) throws Exception {
    List<String> deletedCols = new ArrayList<>();
    List<ColumnStatistics> multiColumnStats = HiveAlterHandler
        .updateOrGetPartitionColumnStats(rawStore, catalogName, dbName, tableName, part.getValues(),
            part.getSd().getCols(), before, part, null, deletedCols);
    if (multiColumnStats.size() > 1) {
      throw new RuntimeException("CachedStore can only be enabled for Hive engine");
    }
    ColumnStatistics colStats = multiColumnStats.isEmpty() ? null : multiColumnStats.get(0);
    for (String column : deletedCols) {
      sharedCache.removePartitionColStatsFromCache(catalogName, dbName, tableName, part.getValues(), column);
    }
    if (colStats != null) {
      sharedCache.alterPartitionAndStatsInCache(catalogName, dbName, tableName, part.getWriteId(), part.getValues(),
          part.getParameters(), colStats.getStatsObj());
    }
    return colStats;
  }
Similar to setConf but used from within the tests
This does start the background thread for prewarm and update
@param conf
standalone-metastore/metastore-server/src/main/java/org/apache/hadoop/hive/metastore/cache/CachedStore.java