Skip to content

Commit 6093309

Browse files
committed
nydus-image: merge main branch and remove unnecessary output.
1 parent 00ce305 commit 6093309

File tree

2 files changed

+12
-2
lines changed

2 files changed

+12
-2
lines changed

src/bin/nydus-image/deduplicate.rs

+4-1
Original file line numberDiff line numberDiff line change
@@ -194,6 +194,9 @@ pub fn update_ctx_from_parent_bootstrap(
194194
ctx.conversion_type = ConversionType::TarToTarfs;
195195
ctx.blob_features |= BlobFeatures::TARFS;
196196
}
197+
ctx.fs_version =
198+
RafsVersion::try_from(sb.meta.version).context("Failed to get RAFS version")?;
199+
ctx.compressor = config.compressor;
197200

198201
Ok(())
199202
}
@@ -1306,7 +1309,7 @@ impl Table<ChunkdictBlobInfo, DatabaseError> for BlobTable {
13061309
.lock()
13071310
.map_err(|e| DatabaseError::PoisonError(e.to_string()))?;
13081311
let mut stmt: rusqlite::Statement<'_> = conn_guard.prepare(
1309-
"SELECT blob_id, blob_compressed_size, blob_uncompressed_size from blob
1312+
"SELECT blob_id, blob_compressed_size, blob_uncompressed_size, blob_compressor, blob_meta_ci_compressed_size, blob_meta_ci_uncompressed_size, blob_meta_ci_offset from blob
13101313
ORDER BY id LIMIT ?1 OFFSET ?2",
13111314
)?;
13121315
let blob_iterator = stmt.query_map(params![limit, offset], |row| {

src/bin/nydus-image/main.rs

+8-1
Original file line numberDiff line numberDiff line change
@@ -1344,7 +1344,14 @@ impl Command {
13441344
chunkdict_chunks,
13451345
chunkdict_blobs,
13461346
)?;
1347-
OutputSerializer::dump(matches, output, build_info).unwrap();
1347+
OutputSerializer::dump(
1348+
matches,
1349+
output,
1350+
build_info,
1351+
build_ctx.compressor,
1352+
build_ctx.fs_version,
1353+
)
1354+
.unwrap();
13481355
info!(
13491356
"Chunkdict metadata is saved at: {:?}",
13501357
matches

0 commit comments

Comments
 (0)