Releases
armeria-0.71.0
Compare
Sorry, something went wrong.
No results found
New features
Added RequestContext.decodedPath() and ServiceRequestContext.decodedMappedPath() which decodes the percent-encoded UTF-8 path. #756 #1356
RequestContext.path() and ServiceRequestContext.mappedPath() remain unchanged.
ServiceRequestContext ctx = ...;
assert ctx .path ().equals ("/unicode/%F0%9F%91%8D" );
assert ctx .decodedPath ().equals ("/unicode/👍" );
Added a utility class AsyncMethodCallbacks which bridges the gap between CompletionStage and AsyncMethodCallback. #508 #1357
// Before:
public void myThriftServiceMethod (AsyncMethodCallback <String > cb ) {
CompletableFuture <String > f = someAsyncOp ();
f .whenComplete ((res , cause ) -> {
if (cause != null ) {
if (cause instanceof Exception ) {
cb .onError (cause );
} else {
cb .onError (new CompletionException (cause ));
}
} else {
cb .onComplete (res );
}
});
}
// After:
public void myThriftServiceMethod (AsyncMethodCallback <String > cb ) {
AsyncMethodCallbacks .transfer (someAsyncOp (), cb );
}
Bug fixes
Fixed a bug where the server-side response stream is not aborted immediately when the corresponding client aborts the stream. #1350
Fixed an AssertionError in StartStopSupport. #1351 #1358
Fixed a bug where %26, %3B and %3D are not handled correctly in a query string. #1354
Fixed a bug where Zipkin context does not work as expected when a new subspan is created in a non-event loop. #1355
Fixed a bug where the path parameters are provided in a percent-encoded UTF-8 form, rather than in a decoded form. #1356
Breaking changes
Since this release, due to the fix #1356 , the path parameters which are:
retrieved using ServiceRequestContext.pathParam*() and PathMappingResult.pathParams()
injected via @Param annotation
.. will be provided in a decoded form. Please remove any decoding code such as URLDecoder.decode() to avoid double decode.
Dependencies
Jetty 9.4.11 -> 9.4.12
netty-tcnative-boringssl-static 2.0.14 -> 2.0.15
RxJava 2.2.1 -> 2.2.2
You can’t perform that action at this time.