-
Notifications
You must be signed in to change notification settings - Fork 1.1k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Deprecate MediaTypeCodec
and use Message Body Writer / Reader API for clients
#11121
Conversation
core/src/main/java/io/micronaut/core/io/buffer/ByteArrayByteBuffer.java
Outdated
Show resolved
Hide resolved
core/src/main/java/io/micronaut/core/io/buffer/ByteArrayByteBuffer.java
Outdated
Show resolved
Hide resolved
core/src/main/java/io/micronaut/core/io/buffer/ByteArrayByteBuffer.java
Outdated
Show resolved
Hide resolved
http-client-jdk/src/main/java/io/micronaut/http/client/jdk/HttpResponseAdapter.java
Outdated
Show resolved
Hide resolved
http-netty/src/main/java/io/micronaut/http/netty/websocket/AbstractNettyWebSocketHandler.java
Outdated
Show resolved
Hide resolved
http-netty/src/main/java/io/micronaut/http/netty/websocket/WebSocketMessageEncoder.java
Outdated
Show resolved
Hide resolved
* @since 4.7 | ||
*/ | ||
default MutableHttpRequest<B> toMutableRequest() { | ||
if (this instanceof MutableHttpRequest<B> mutableHttpRequest) { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
just override the method in MutableHttpRequest instead of using this instanceof
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I did also override it
Quality Gate failedFailed conditions See analysis details on SonarCloud Catch issues before they fail your Quality Gate with our IDE extension SonarLint |
I tested it by disabling all codecs, and the tests passed.
Right now, we still don't use the message body API for functions. We should convert other modules: servlet, Oracle Cloud, Azure, and GCP.