Fix memory leak in Zipkin API (#10126)
This commit is contained in:
parent
108260681e
commit
210c374976
|
|
@ -29,6 +29,7 @@
|
|||
* Remove abandon logic in MergableBufferedData, which caused unexpected no-update.
|
||||
* Fix miss set `LastUpdateTimestamp` that caused the metrics session to expire.
|
||||
* Rename MAL rule `spring-sleuth.yaml` to `spring-micrometer.yaml`.
|
||||
* Fix memory leak in Zipkin API.
|
||||
|
||||
#### UI
|
||||
|
||||
|
|
|
|||
|
|
@ -100,10 +100,11 @@ public class ZipkinSpanHTTPHandler {
|
|||
final HttpRequest req) {
|
||||
final HistogramMetrics.Timer timer = histogram.createTimer();
|
||||
final HttpResponse response = HttpResponse.from(req.aggregate().thenApply(request -> {
|
||||
final HttpData httpData = UnzippingBytesRequestConverter.convertRequest(ctx, request);
|
||||
final List<Span> spanList = decoder.decodeList(httpData.byteBuf().nioBuffer());
|
||||
spanForward.send(spanList);
|
||||
return HttpResponse.of(HttpStatus.OK);
|
||||
try (final HttpData httpData = UnzippingBytesRequestConverter.convertRequest(ctx, request)) {
|
||||
final List<Span> spanList = decoder.decodeList(httpData.byteBuf().nioBuffer());
|
||||
spanForward.send(spanList);
|
||||
return HttpResponse.of(HttpStatus.OK);
|
||||
}
|
||||
}));
|
||||
response.whenComplete().handle((unused, throwable) -> {
|
||||
if (nonNull(throwable)) {
|
||||
|
|
|
|||
Loading…
Reference in New Issue