diff --git a/src/main/java/io/vertx/core/Vertx.java b/src/main/java/io/vertx/core/Vertx.java index e736d7cb748..f70e68bb164 100644 --- a/src/main/java/io/vertx/core/Vertx.java +++ b/src/main/java/io/vertx/core/Vertx.java @@ -676,8 +676,10 @@ default void executeBlocking(Handler> blockingCodeHandler, Handle * Return the Netty EventLoopGroup used by Vert.x * * @return the EventLoopGroup + * @deprecated removed from public API in Vert.x 5 */ @GenIgnore(GenIgnore.PERMITTED_TYPE) + @Deprecated EventLoopGroup nettyEventLoopGroup(); /** diff --git a/src/main/java/io/vertx/core/buffer/Buffer.java b/src/main/java/io/vertx/core/buffer/Buffer.java index 1b919d96809..61497695646 100644 --- a/src/main/java/io/vertx/core/buffer/Buffer.java +++ b/src/main/java/io/vertx/core/buffer/Buffer.java @@ -110,7 +110,9 @@ static Buffer buffer(byte[] bytes) { * * @param byteBuf the Netty ByteBuf * @return the buffer + * @deprecated removed from public API in Vert.x 5 */ + @Deprecated @GenIgnore(GenIgnore.PERMITTED_TYPE) static Buffer buffer(ByteBuf byteBuf) { Objects.requireNonNull(byteBuf); @@ -705,7 +707,10 @@ default Object toJson() { * Returns the Buffer as a Netty {@code ByteBuf}. * *

The returned buffer is a duplicate that maintain its own indices. + * + * @deprecated removed from public API in Vert.x 5 */ + @Deprecated @GenIgnore(GenIgnore.PERMITTED_TYPE) ByteBuf getByteBuf(); diff --git a/src/main/java/io/vertx/core/impl/VertxInternal.java b/src/main/java/io/vertx/core/impl/VertxInternal.java index 69a1124e76c..04e38221a4a 100644 --- a/src/main/java/io/vertx/core/impl/VertxInternal.java +++ b/src/main/java/io/vertx/core/impl/VertxInternal.java @@ -15,6 +15,7 @@ import io.netty.channel.EventLoop; import io.netty.channel.EventLoopGroup; import io.netty.resolver.AddressResolverGroup; +import io.vertx.codegen.annotations.GenIgnore; import io.vertx.core.*; import io.vertx.core.http.HttpClient; import io.vertx.core.http.HttpClientOptions; diff --git a/src/test/java/io/vertx/core/dns/HostnameResolutionTest.java b/src/test/java/io/vertx/core/dns/HostnameResolutionTest.java index fcefa5d7999..a5ed8f9fec3 100644 --- a/src/test/java/io/vertx/core/dns/HostnameResolutionTest.java +++ b/src/test/java/io/vertx/core/dns/HostnameResolutionTest.java @@ -327,7 +327,7 @@ public void testAsyncResolveConnectIsNotifiedOnChannelEventLoop() throws Excepti CountDownLatch connectLatch = new CountDownLatch(1); Bootstrap bootstrap = new Bootstrap(); bootstrap.channelFactory(((VertxInternal)vertx).transport().channelFactory(false)); - bootstrap.group(vertx.nettyEventLoopGroup()); + bootstrap.group(((VertxInternal) vertx).getEventLoopGroup()); bootstrap.resolver(((VertxInternal) vertx).nettyAddressResolverGroup()); bootstrap.handler(new ChannelInitializer() { @Override