Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion core/services/webhdfs/src/core.rs
Original file line number Diff line number Diff line change
Expand Up @@ -314,7 +314,7 @@ impl WebhdfsCore {
percent_encode_path(&p),
);
if !start_after.is_empty() {
url += format!("&startAfter={start_after}").as_str();
url += format!("&startAfter={}", percent_encode_path(start_after)).as_str();
}
if let Some(user) = &self.user_name {
url += format!("&user.name={user}").as_str();
Expand Down
8 changes: 7 additions & 1 deletion core/services/webhdfs/src/writer.rs
Original file line number Diff line number Diff line change
Expand Up @@ -135,10 +135,16 @@ impl oio::BlockWrite for WebhdfsWriter {
}

async fn abort_block(&self, block_ids: Vec<Uuid>) -> Result<()> {
let Some(ref atomic_write_dir) = self.core.atomic_write_dir else {
return Err(Error::new(
ErrorKind::Unsupported,
"write multi is not supported when atomic is not set",
));
};
for block_id in block_ids {
let resp = self
.core
.webhdfs_delete(&self.ctx, &block_id.to_string())
.webhdfs_delete(&self.ctx, &format!("{atomic_write_dir}{block_id}"))
.await?;
match resp.status() {
StatusCode::OK => {}
Expand Down
Loading