From 2fe8041b369c9f8cb452192d79890352b7949906 Mon Sep 17 00:00:00 2001 From: Julien Viet Date: Sun, 27 Oct 2024 10:20:52 +0100 Subject: [PATCH] Remove @Unstable from a few vertx API which have proven to be stable --- vertx-core/src/main/java/io/vertx/core/file/AsyncFile.java | 7 ------- .../main/java/io/vertx/core/http/HttpServerOptions.java | 4 ---- .../src/main/java/io/vertx/core/net/NetworkOptions.java | 3 --- .../main/java/io/vertx/core/net/TrafficShapingOptions.java | 2 -- 4 files changed, 16 deletions(-) diff --git a/vertx-core/src/main/java/io/vertx/core/file/AsyncFile.java b/vertx-core/src/main/java/io/vertx/core/file/AsyncFile.java index 10ce96bc121..866a8b9aff4 100644 --- a/vertx-core/src/main/java/io/vertx/core/file/AsyncFile.java +++ b/vertx-core/src/main/java/io/vertx/core/file/AsyncFile.java @@ -13,7 +13,6 @@ import io.vertx.codegen.annotations.Fluent; import io.vertx.codegen.annotations.Nullable; -import io.vertx.codegen.annotations.Unstable; import io.vertx.codegen.annotations.VertxGen; import io.vertx.core.Future; import io.vertx.core.Handler; @@ -174,7 +173,6 @@ public interface AsyncFile extends ReadStream, WriteStream { * * @return the lock if it can be acquired immediately, otherwise {@code null} */ - @Unstable default @Nullable AsyncFileLock tryLock() { return tryLock(0, Long.MAX_VALUE, false); } @@ -187,7 +185,6 @@ public interface AsyncFile extends ReadStream, WriteStream { * @param shared whether the lock should be shared * @return the lock if it can be acquired immediately, otherwise {@code null} */ - @Unstable @Nullable AsyncFileLock tryLock(long position, long size, boolean shared); /** @@ -195,7 +192,6 @@ public interface AsyncFile extends ReadStream, WriteStream { * * @return a future indicating the completion of this operation */ - @Unstable default Future lock() { return lock(0, Long.MAX_VALUE, false); } @@ -208,7 +204,6 @@ default Future lock() { * @param shared whether the lock should be shared * @return a future indicating the completion of this operation */ - @Unstable Future lock(long position, long size, boolean shared); /** @@ -222,7 +217,6 @@ default Future lock() { * @param block the code block called after lock acquisition * @return the future returned by the {@code block} */ - @Unstable default Future withLock(Supplier> block) { return withLock(0, Long.MAX_VALUE, false, block); } @@ -241,7 +235,6 @@ default Future withLock(Supplier> block) { * @param block the code block called after lock acquisition * @return the future returned by the {@code block} */ - @Unstable default Future withLock(long position, long size, boolean shared, Supplier> block) { return lock(position, size, shared) .compose(lock -> { diff --git a/vertx-core/src/main/java/io/vertx/core/http/HttpServerOptions.java b/vertx-core/src/main/java/io/vertx/core/http/HttpServerOptions.java index 69d063e0ebb..0ec62656fec 100755 --- a/vertx-core/src/main/java/io/vertx/core/http/HttpServerOptions.java +++ b/vertx-core/src/main/java/io/vertx/core/http/HttpServerOptions.java @@ -15,7 +15,6 @@ import io.netty.handler.logging.ByteBufFormat; import io.vertx.codegen.annotations.DataObject; import io.vertx.codegen.annotations.GenIgnore; -import io.vertx.codegen.annotations.Unstable; import io.vertx.codegen.json.annotations.JsonGen; import io.vertx.core.Handler; import io.vertx.core.buffer.Buffer; @@ -591,7 +590,6 @@ public HttpServerOptions setCompressionLevel(int compressionLevel) { /** * @return the list of compressor to use */ - @Unstable public List getCompressors() { return compressors; } @@ -602,7 +600,6 @@ public List getCompressors() { * @see #setCompressors(List) * @return a reference to this, so the API can be used fluently */ - @Unstable public HttpServerOptions addCompressor(CompressionOptions compressor) { if (compressors == null) { compressors = new ArrayList<>(); @@ -619,7 +616,6 @@ public HttpServerOptions addCompressor(CompressionOptions compressor) { * @param compressors the list of compressors * @return a reference to this, so the API can be used fluently */ - @Unstable public HttpServerOptions setCompressors(List compressors) { this.compressors = compressors; return this; diff --git a/vertx-core/src/main/java/io/vertx/core/net/NetworkOptions.java b/vertx-core/src/main/java/io/vertx/core/net/NetworkOptions.java index 855db3412f6..61296101f16 100644 --- a/vertx-core/src/main/java/io/vertx/core/net/NetworkOptions.java +++ b/vertx-core/src/main/java/io/vertx/core/net/NetworkOptions.java @@ -12,7 +12,6 @@ package io.vertx.core.net; import io.vertx.codegen.annotations.DataObject; -import io.vertx.codegen.annotations.Unstable; import io.vertx.codegen.json.annotations.JsonGen; import io.vertx.core.impl.Arguments; import io.vertx.core.json.JsonObject; @@ -206,7 +205,6 @@ public boolean getLogActivity() { /** * @return Netty's logging handler's data format. */ - @Unstable public ByteBufFormat getActivityLogDataFormat() { return activityLogDataFormat; } @@ -228,7 +226,6 @@ public NetworkOptions setLogActivity(boolean logActivity) { * @param activityLogDataFormat the format to use * @return a reference to this, so the API can be used fluently */ - @Unstable public NetworkOptions setActivityLogDataFormat(ByteBufFormat activityLogDataFormat) { this.activityLogDataFormat = activityLogDataFormat; return this; diff --git a/vertx-core/src/main/java/io/vertx/core/net/TrafficShapingOptions.java b/vertx-core/src/main/java/io/vertx/core/net/TrafficShapingOptions.java index 0ceb21f3c4f..e84af6c589b 100644 --- a/vertx-core/src/main/java/io/vertx/core/net/TrafficShapingOptions.java +++ b/vertx-core/src/main/java/io/vertx/core/net/TrafficShapingOptions.java @@ -16,14 +16,12 @@ import io.netty.util.internal.ObjectUtil; import io.vertx.codegen.annotations.DataObject; -import io.vertx.codegen.annotations.Unstable; import io.vertx.codegen.json.annotations.JsonGen; import io.vertx.core.json.JsonObject; /** * Options describing how {@link io.netty.handler.traffic.GlobalTrafficShapingHandler} will handle traffic shaping. */ -@Unstable @DataObject @JsonGen(publicConverter = false) public class TrafficShapingOptions {