Skip to content

Commit 5f07a36

Browse files
Kontinuation2010YOUY01paleolimbot
authored
Apply suggestions from code review
Co-authored-by: Yongting You <2010youy01@gmail.com> Co-authored-by: Dewey Dunnington <dewey@dunnington.ca>
1 parent e70b076 commit 5f07a36

2 files changed

Lines changed: 4 additions & 2 deletions

File tree

rust/sedona/src/memory_pool.rs

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -26,7 +26,9 @@ pub const DEFAULT_UNSPILLABLE_RESERVE_RATIO: f64 = 0.2;
2626
/// A [`MemoryPool`] implementation similar to DataFusion's [`datafusion::execution::memory_pool::FairSpillPool`],
2727
/// but with the following changes:
2828
///
29-
/// It implements a reservation mechanism for unspillable memory consumers. This addresses an issue
29+
/// Spillable and non-spillable operators use logically separate portions of the memory pool,
30+
/// controlled by unspillable_reserve_ratio, instead of sharing a single pool as in
31+
/// DataFusion’s default FairSpillPool, which can lead to the following issues:
3032
/// where spillable consumers could potentially exhaust all available memory, preventing unspillable
3133
/// operations from acquiring necessary resources. This behavior is tracked in DataFusion issue
3234
/// https://github.com/apache/datafusion/issues/17334. In the context of Sedona, a typical example

sedona-cli/src/main.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -275,7 +275,7 @@ fn parse_size_string(size: &str, label: &str) -> Result<usize, String> {
275275
});
276276

277277
static SUFFIX_REGEX: LazyLock<regex::Regex> =
278-
LazyLock::new(|| regex::Regex::new(r"^([0-9]+)([a-z]+)?$").unwrap());
278+
LazyLock::new(|| regex::Regex::new(r"^([0-9.]+)\s*([a-z]+)?$").unwrap());
279279

280280
let lower = size.to_lowercase();
281281
if let Some(caps) = SUFFIX_REGEX.captures(&lower) {

0 commit comments

Comments
 (0)