Skip to content

Commit

Permalink
fixed version & rm port scanner
Browse files Browse the repository at this point in the history
  • Loading branch information
odysa committed Feb 26, 2024
1 parent 456fad4 commit 740d899
Show file tree
Hide file tree
Showing 3 changed files with 2 additions and 12 deletions.
1 change: 0 additions & 1 deletion crates/iceberg/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -63,7 +63,6 @@ uuid = { workspace = true }

[dev-dependencies]
iceberg_test_utils = { path = "../test_utils", features = ["tests"] }
port_scanner = { workspace = true }
pretty_assertions = { workspace = true }
tempfile = { workspace = true }
tera = { workspace = true }
Expand Down
2 changes: 1 addition & 1 deletion crates/iceberg/testdata/file_io_s3/docker-compose.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@
version: '3'
services:
minio:
image: quay.io/minio/minio:latest
image: minio/minio:RELEASE.2024-02-26T09-33-48Z
ports:
- 9000
- 9001
Expand Down
11 changes: 1 addition & 10 deletions crates/iceberg/tests/file_io_s3_test.rs
Original file line number Diff line number Diff line change
Expand Up @@ -22,8 +22,6 @@ use iceberg::io::{
FileIO, FileIOBuilder, S3_ACCESS_KEY_ID, S3_ENDPOINT, S3_REGION, S3_SECRET_ACCESS_KEY,
};
use iceberg_test_utils::docker::DockerCompose;
use port_scanner::scan_port_addr;
use tokio::time::sleep;

struct MinIOFixture {
_docker_compose: DockerCompose,
Expand All @@ -39,14 +37,7 @@ impl MinIOFixture {
docker.run();
let container_ip = docker.get_container_ip("minio");
let read_port = format!("{}:{}", container_ip, 9000);
loop {
if !scan_port_addr(&read_port) {
log::info!("Waiting 1s for MinIO to ready...");
sleep(std::time::Duration::from_millis(1000)).await;
} else {
break;
}
}

MinIOFixture {
_docker_compose: docker,
file_io: FileIOBuilder::new("s3")
Expand Down

0 comments on commit 740d899

Please sign in to comment.