diff --git a/independent-projects/resteasy-reactive/server/runtime/src/main/java/org/jboss/resteasy/reactive/server/core/ServerSerialisers.java b/independent-projects/resteasy-reactive/server/runtime/src/main/java/org/jboss/resteasy/reactive/server/core/ServerSerialisers.java index e6db1f881c06b..3f629b75b2711 100644 --- a/independent-projects/resteasy-reactive/server/runtime/src/main/java/org/jboss/resteasy/reactive/server/core/ServerSerialisers.java +++ b/independent-projects/resteasy-reactive/server/runtime/src/main/java/org/jboss/resteasy/reactive/server/core/ServerSerialisers.java @@ -476,6 +476,14 @@ public Entry(MessageBodyWriter writer, MediaType mediaType) { public static void encodeResponseHeaders(ResteasyReactiveRequestContext requestContext) { ServerHttpResponse vertxResponse = requestContext.serverResponse(); + boolean ouch = false; + for (java.util.Map.Entry entry : vertxResponse.getAllResponseHeaders()) { + System.err.println("Found header: " + entry.getKey() + ": " + entry.getValue()); + ouch = true; + } + if (ouch) { + throw new RuntimeException("Assertion failed: found vert.x headers before setting response"); + } LazyResponse lazyResponse = requestContext.getResponse(); if (!lazyResponse.isCreated() && lazyResponse.isPredetermined()) { //fast path