diff --git a/s3stream/src/main/java/com/automq/stream/s3/cache/blockcache/DataBlockCache.java b/s3stream/src/main/java/com/automq/stream/s3/cache/blockcache/DataBlockCache.java index 84244603a5..382fe59e90 100644 --- a/s3stream/src/main/java/com/automq/stream/s3/cache/blockcache/DataBlockCache.java +++ b/s3stream/src/main/java/com/automq/stream/s3/cache/blockcache/DataBlockCache.java @@ -18,6 +18,7 @@ import com.automq.stream.s3.metrics.S3StreamMetricsManager; import com.automq.stream.s3.metrics.stats.StorageOperationStats; import com.automq.stream.s3.network.ThrottleStrategy; +import com.automq.stream.utils.AsyncSemaphore; import com.automq.stream.utils.FutureUtil; import com.automq.stream.utils.Time; import com.automq.stream.utils.threads.EventLoop; diff --git a/s3stream/src/main/java/com/automq/stream/s3/cache/blockcache/AsyncSemaphore.java b/s3stream/src/main/java/com/automq/stream/utils/AsyncSemaphore.java similarity index 97% rename from s3stream/src/main/java/com/automq/stream/s3/cache/blockcache/AsyncSemaphore.java rename to s3stream/src/main/java/com/automq/stream/utils/AsyncSemaphore.java index 9b7936546b..ec50c523ae 100644 --- a/s3stream/src/main/java/com/automq/stream/s3/cache/blockcache/AsyncSemaphore.java +++ b/s3stream/src/main/java/com/automq/stream/utils/AsyncSemaphore.java @@ -9,7 +9,7 @@ * by the Apache License, Version 2.0 */ -package com.automq.stream.s3.cache.blockcache; +package com.automq.stream.utils; import com.automq.stream.utils.threads.EventLoop; @@ -21,7 +21,7 @@ import java.util.concurrent.CompletableFuture; import java.util.function.Supplier; -class AsyncSemaphore { +public class AsyncSemaphore { private static final Logger LOGGER = LoggerFactory.getLogger(AsyncSemaphore.class); private final Queue tasks = new LinkedList<>(); private long permits;