Skip to content

Commit 53a9b85

Browse files
committed
misc changes
1 parent f96d42d commit 53a9b85

File tree

4 files changed

+6
-3
lines changed

4 files changed

+6
-3
lines changed

server/src/migration.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -155,7 +155,7 @@ async fn migration_stream(stream: &str, storage: &dyn ObjectStorage) -> anyhow::
155155
}
156156

157157
#[inline(always)]
158-
fn to_bytes(any: &(impl ?Sized + Serialize)) -> Bytes {
158+
pub fn to_bytes(any: &(impl ?Sized + Serialize)) -> Bytes {
159159
serde_json::to_vec(any)
160160
.map(|any| any.into())
161161
.expect("serialize cannot fail")

server/src/query.rs

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -186,6 +186,9 @@ impl TableScanVisitor {
186186
pub fn into_inner(self) -> Vec<String> {
187187
self.tables
188188
}
189+
pub fn top(&self) -> &str {
190+
self.tables[0].as_ref()
191+
}
189192
}
190193

191194
impl TreeNodeVisitor for TableScanVisitor {

server/src/storage/staging.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -293,7 +293,7 @@ pub fn convert_disk_files_to_parquet(
293293
}
294294
}
295295

296-
fn parquet_writer_props(
296+
pub fn parquet_writer_props(
297297
time_partition: Option<String>,
298298
index_time_partition: usize,
299299
custom_partition_fields: HashMap<String, usize>,

server/src/utils.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -280,7 +280,7 @@ pub fn get_ingestor_id() -> String {
280280
let result = format!("{:x}", hasher.finalize());
281281
let result = result.split_at(15).0.to_string();
282282
log::debug!("Ingestor ID: {}", &result);
283-
result.to_string()
283+
result
284284
}
285285

286286
#[cfg(test)]

0 commit comments

Comments
 (0)