Skip to content

Commit

Permalink
Prepare object_store 0.9.0
Browse files Browse the repository at this point in the history
  • Loading branch information
tustvold committed Jan 5, 2024
1 parent 561d941 commit 1be2b9a
Show file tree
Hide file tree
Showing 6 changed files with 32 additions and 19 deletions.
3 changes: 3 additions & 0 deletions Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -92,3 +92,6 @@ opt-level = 3
overflow-checks = false
panic = 'unwind'
rpath = false

[patch.crates-io]
object_store = { git = "https://github.com/apache/arrow-rs.git", rev = "f7101ec3a2b37c436f4554c28fa2d0a05de533ff" }
35 changes: 22 additions & 13 deletions datafusion-cli/Cargo.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

3 changes: 3 additions & 0 deletions datafusion-cli/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -53,3 +53,6 @@ assert_cmd = "2.0"
ctor = "0.2.0"
predicates = "3.0"
rstest = "0.17"

[patch.crates-io]
object_store = { git = "https://github.com/apache/arrow-rs.git", rev = "f7101ec3a2b37c436f4554c28fa2d0a05de533ff" }
2 changes: 1 addition & 1 deletion datafusion/core/src/datasource/physical_plan/csv.rs
Original file line number Diff line number Diff line change
Expand Up @@ -375,7 +375,7 @@ impl FileOpener for CsvOpener {

let range = match calculated_range {
RangeCalculation::Range(None) => None,
RangeCalculation::Range(Some(range)) => Some(range),
RangeCalculation::Range(Some(range)) => Some(range.into()),
RangeCalculation::TerminateEarly => {
return Ok(
futures::stream::poll_fn(move |_| Poll::Ready(None)).boxed()
Expand Down
2 changes: 1 addition & 1 deletion datafusion/core/src/datasource/physical_plan/json.rs
Original file line number Diff line number Diff line change
Expand Up @@ -239,7 +239,7 @@ impl FileOpener for JsonOpener {

let range = match calculated_range {
RangeCalculation::Range(None) => None,
RangeCalculation::Range(Some(range)) => Some(range),
RangeCalculation::Range(Some(range)) => Some(range.into()),
RangeCalculation::TerminateEarly => {
return Ok(
futures::stream::poll_fn(move |_| Poll::Ready(None)).boxed()
Expand Down
6 changes: 2 additions & 4 deletions datafusion/core/src/datasource/physical_plan/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -75,7 +75,7 @@ use datafusion_physical_plan::ExecutionPlan;

use log::debug;
use object_store::ObjectMeta;
use object_store::{path::Path, GetOptions, ObjectStore};
use object_store::{path::Path, GetOptions, ObjectStore, GetRange};

/// The base configurations to provide when creating a physical plan for
/// writing to any given file format.
Expand Down Expand Up @@ -604,10 +604,8 @@ async fn find_first_newline(
start: usize,
end: usize,
) -> Result<usize> {
let range = Some(Range { start, end });

let options = GetOptions {
range,
range: Some(GetRange::Bounded(start..end)),
..Default::default()
};

Expand Down

0 comments on commit 1be2b9a

Please sign in to comment.