Class groovyx.net.http.JavaUsageTest

6

tests

0

failures

0

ignored

0.616s

duration

100%

successful

Tests

Test Duration Result
delete_request 0.057s passed
get_request 0.039s passed
head_request 0.071s passed
head_request_with_raw_function 0.046s passed
post_request 0.309s passed
put_request 0.094s passed

Standard output

06:24:57.648 [XNIO-55 Accept] DEBUG ersatz.xnio.nio - Started channel thread 'XNIO-55 Accept', selector sun.nio.ch.EPollSelectorImpl@2ad51abe
06:24:57.753 [Test worker] DEBUG ersatz.undertow - starting undertow server ersatz.undertow.Undertow@3aea1ece
06:24:57.755 [XNIO-56 I/O-1] DEBUG ersatz.xnio.nio - Started channel thread 'XNIO-56 I/O-1', selector sun.nio.ch.EPollSelectorImpl@554eec31
06:24:57.772 [XNIO-56 I/O-2] DEBUG ersatz.xnio.nio - Started channel thread 'XNIO-56 I/O-2', selector sun.nio.ch.EPollSelectorImpl@6884da37
06:24:57.774 [XNIO-56 I/O-3] DEBUG ersatz.xnio.nio - Started channel thread 'XNIO-56 I/O-3', selector sun.nio.ch.EPollSelectorImpl@76e45d2d
06:24:57.777 [XNIO-56 I/O-4] DEBUG ersatz.xnio.nio - Started channel thread 'XNIO-56 I/O-4', selector sun.nio.ch.EPollSelectorImpl@776bfd7b
06:24:57.794 [XNIO-56 I/O-6] DEBUG ersatz.xnio.nio - Started channel thread 'XNIO-56 I/O-6', selector sun.nio.ch.EPollSelectorImpl@758b70ef
06:24:57.796 [XNIO-56 I/O-5] DEBUG ersatz.xnio.nio - Started channel thread 'XNIO-56 I/O-5', selector sun.nio.ch.EPollSelectorImpl@2cb46ceb
06:24:57.802 [XNIO-56 I/O-7] DEBUG ersatz.xnio.nio - Started channel thread 'XNIO-56 I/O-7', selector sun.nio.ch.EPollSelectorImpl@27e049d4
06:24:57.806 [XNIO-56 I/O-8] DEBUG ersatz.xnio.nio - Started channel thread 'XNIO-56 I/O-8', selector sun.nio.ch.EPollSelectorImpl@12f04811
06:24:57.808 [Test worker] DEBUG ersatz.undertow - Configuring listener with protocol HTTP for interface localhost and port 0
06:24:57.811 [XNIO-56 Accept] DEBUG ersatz.xnio.nio - Started channel thread 'XNIO-56 Accept', selector sun.nio.ch.EPollSelectorImpl@71d01676
06:24:57.818 [Test worker] DEBUG groovyx.net.http.JavaHttpBuilder - Request-URI(POST): http://localhost:38109/foo
06:24:57.819 [Test worker] DEBUG groovy.net.http.JavaHttpBuilder.headers - Request-Header: Accept-Encoding -> [gzip, deflate]
06:24:57.819 [Test worker] DEBUG groovy.net.http.JavaHttpBuilder.headers - Request-Header: Content-Type -> [text/plain; charset=utf-8]
06:24:57.819 [Test worker] DEBUG groovy.net.http.JavaHttpBuilder.content - Request-Body(text/plain): This is CONTENT!!!
06:24:57.824 [XNIO-56 task-1] DEBUG com.stehno.ersatz.ErsatzServer - Request: { POST /foo (query=[:], headers={Accept=[text/html, image/gif, image/jpeg, *; q=.2, */*; q=.2], Connection=[keep-alive], Accept-Encoding=[gzip, deflate], Content-Type=[text/plain; charset=utf-8], Content-Length=[18], User-Agent=[Java/1.8.0_131], Host=[localhost:38109]}, cookies=[:]): This is CONTENT!!! }
06:24:57.863 [XNIO-56 task-1] DEBUG com.stehno.ersatz.ErsatzServer - Response({Content-Type=[text/plain]}): This is CONTENT!!!
06:24:57.864 [Test worker] DEBUG groovy.net.http.JavaHttpBuilder.content - Response-Body: This is CONTENT!!!
06:24:57.864 [Test worker] DEBUG groovy.net.http.JavaHttpBuilder.headers - Response-Header: Content-Encoding -> gzip
06:24:57.864 [Test worker] DEBUG groovy.net.http.JavaHttpBuilder.headers - Response-Header: Connection -> keep-alive
06:24:57.864 [Test worker] DEBUG groovy.net.http.JavaHttpBuilder.headers - Response-Header: Content-Type -> text/plain
06:24:57.864 [Test worker] DEBUG groovy.net.http.JavaHttpBuilder.headers - Response-Header: Content-Length -> 36
06:24:57.864 [Test worker] DEBUG groovy.net.http.JavaHttpBuilder.headers - Response-Header: Date -> Mon, 20 Nov 2017 12:24:50 GMT
06:24:57.959 [Test worker] DEBUG groovyx.net.http.JavaHttpBuilder - Request-URI(POST): http://localhost:38109/foo
06:24:57.959 [Test worker] DEBUG groovy.net.http.JavaHttpBuilder.headers - Request-Header: Accept-Encoding -> [gzip, deflate]
06:24:57.959 [Test worker] DEBUG groovy.net.http.JavaHttpBuilder.headers - Request-Header: Content-Type -> [text/plain; charset=utf-8]
06:24:57.959 [Test worker] DEBUG groovy.net.http.JavaHttpBuilder.content - Request-Body(text/plain): This is CONTENT!!!
06:24:58.033 [XNIO-56 task-2] DEBUG com.stehno.ersatz.ErsatzServer - Request: { POST /foo (query=[:], headers={Accept=[text/html, image/gif, image/jpeg, *; q=.2, */*; q=.2], Connection=[keep-alive], Accept-Encoding=[gzip, deflate], Content-Type=[text/plain; charset=utf-8], Content-Length=[18], User-Agent=[Java/1.8.0_131], Host=[localhost:38109]}, cookies=[:]): This is CONTENT!!! }
06:24:58.034 [XNIO-56 task-2] DEBUG com.stehno.ersatz.ErsatzServer - Response({Content-Type=[text/plain]}): This is CONTENT!!!
06:24:58.037 [Test worker] DEBUG groovy.net.http.JavaHttpBuilder.content - Response-Body: This is CONTENT!!!
06:24:58.037 [Test worker] DEBUG groovy.net.http.JavaHttpBuilder.headers - Response-Header: Content-Encoding -> gzip
06:24:58.037 [Test worker] DEBUG groovy.net.http.JavaHttpBuilder.headers - Response-Header: Connection -> keep-alive
06:24:58.037 [Test worker] DEBUG groovy.net.http.JavaHttpBuilder.headers - Response-Header: Content-Type -> text/plain
06:24:58.037 [Test worker] DEBUG groovy.net.http.JavaHttpBuilder.headers - Response-Header: Content-Length -> 36
06:24:58.037 [Test worker] DEBUG groovy.net.http.JavaHttpBuilder.headers - Response-Header: Date -> Mon, 20 Nov 2017 12:24:50 GMT
06:24:58.038 [Test worker] DEBUG ersatz.undertow - stopping undertow server ersatz.undertow.Undertow@3aea1ece
06:24:58.040 [Test worker] DEBUG ersatz.undertow - starting undertow server ersatz.undertow.Undertow@5467b58f
06:24:58.050 [XNIO-57 I/O-1] DEBUG ersatz.xnio.nio - Started channel thread 'XNIO-57 I/O-1', selector sun.nio.ch.EPollSelectorImpl@ab761b3
06:24:58.054 [XNIO-57 I/O-2] DEBUG ersatz.xnio.nio - Started channel thread 'XNIO-57 I/O-2', selector sun.nio.ch.EPollSelectorImpl@582dbaa7
06:24:58.073 [XNIO-57 I/O-4] DEBUG ersatz.xnio.nio - Started channel thread 'XNIO-57 I/O-4', selector sun.nio.ch.EPollSelectorImpl@29be76a1
06:24:58.086 [XNIO-57 I/O-6] DEBUG ersatz.xnio.nio - Started channel thread 'XNIO-57 I/O-6', selector sun.nio.ch.EPollSelectorImpl@5e881ea
06:24:58.094 [XNIO-57 I/O-7] DEBUG ersatz.xnio.nio - Started channel thread 'XNIO-57 I/O-7', selector sun.nio.ch.EPollSelectorImpl@57337ebf
06:24:58.094 [XNIO-57 I/O-8] DEBUG ersatz.xnio.nio - Started channel thread 'XNIO-57 I/O-8', selector sun.nio.ch.EPollSelectorImpl@75599338
06:24:58.073 [XNIO-57 I/O-3] DEBUG ersatz.xnio.nio - Started channel thread 'XNIO-57 I/O-3', selector sun.nio.ch.EPollSelectorImpl@6464f0bd
06:24:58.102 [Test worker] DEBUG ersatz.undertow - Configuring listener with protocol HTTP for interface localhost and port 0
06:24:58.074 [XNIO-57 I/O-5] DEBUG ersatz.xnio.nio - Started channel thread 'XNIO-57 I/O-5', selector sun.nio.ch.EPollSelectorImpl@7f8b59df
06:24:58.104 [Test worker] DEBUG groovyx.net.http.JavaHttpBuilder - Request-URI(PUT): http://localhost:35597/foo
06:24:58.104 [Test worker] DEBUG groovy.net.http.JavaHttpBuilder.headers - Request-Header: Accept-Encoding -> [gzip, deflate]
06:24:58.104 [Test worker] DEBUG groovy.net.http.JavaHttpBuilder.headers - Request-Header: Content-Type -> [text/plain; charset=utf-8]
06:24:58.105 [Test worker] DEBUG groovy.net.http.JavaHttpBuilder.content - Request-Body(text/plain): This is CONTENT!!!
06:24:58.114 [XNIO-57 Accept] DEBUG ersatz.xnio.nio - Started channel thread 'XNIO-57 Accept', selector sun.nio.ch.EPollSelectorImpl@4552d2c1
06:24:58.115 [XNIO-57 task-1] DEBUG com.stehno.ersatz.ErsatzServer - Request: { PUT /foo (query=[:], headers={Accept=[text/html, image/gif, image/jpeg, *; q=.2, */*; q=.2], Connection=[keep-alive], Accept-Encoding=[gzip, deflate], Content-Type=[text/plain; charset=utf-8], Content-Length=[18], User-Agent=[Java/1.8.0_131], Host=[localhost:35597]}, cookies=[:]): This is CONTENT!!! }
06:24:58.120 [XNIO-57 task-1] DEBUG com.stehno.ersatz.ErsatzServer - Response({Content-Type=[text/plain]}): This is CONTENT!!!
06:24:58.122 [Test worker] DEBUG groovy.net.http.JavaHttpBuilder.content - Response-Body: This is CONTENT!!!
06:24:58.122 [Test worker] DEBUG groovy.net.http.JavaHttpBuilder.headers - Response-Header: Content-Encoding -> gzip
06:24:58.122 [Test worker] DEBUG groovy.net.http.JavaHttpBuilder.headers - Response-Header: Connection -> keep-alive
06:24:58.122 [Test worker] DEBUG groovy.net.http.JavaHttpBuilder.headers - Response-Header: Content-Type -> text/plain
06:24:58.122 [Test worker] DEBUG groovy.net.http.JavaHttpBuilder.headers - Response-Header: Content-Length -> 36
06:24:58.122 [Test worker] DEBUG groovy.net.http.JavaHttpBuilder.headers - Response-Header: Date -> Mon, 20 Nov 2017 12:24:50 GMT
06:24:58.123 [Test worker] DEBUG groovyx.net.http.JavaHttpBuilder - Request-URI(PUT): http://localhost:35597/foo
06:24:58.123 [Test worker] DEBUG groovy.net.http.JavaHttpBuilder.headers - Request-Header: Accept-Encoding -> [gzip, deflate]
06:24:58.123 [Test worker] DEBUG groovy.net.http.JavaHttpBuilder.headers - Request-Header: Content-Type -> [text/plain; charset=utf-8]
06:24:58.123 [Test worker] DEBUG groovy.net.http.JavaHttpBuilder.content - Request-Body(text/plain): This is CONTENT!!!
06:24:58.130 [XNIO-57 task-2] DEBUG com.stehno.ersatz.ErsatzServer - Request: { PUT /foo (query=[:], headers={Accept=[text/html, image/gif, image/jpeg, *; q=.2, */*; q=.2], Connection=[keep-alive], Accept-Encoding=[gzip, deflate], Content-Type=[text/plain; charset=utf-8], Content-Length=[18], User-Agent=[Java/1.8.0_131], Host=[localhost:35597]}, cookies=[:]): This is CONTENT!!! }
06:24:58.131 [XNIO-57 task-2] DEBUG com.stehno.ersatz.ErsatzServer - Response({Content-Type=[text/plain]}): This is CONTENT!!!
06:24:58.131 [Test worker] DEBUG groovy.net.http.JavaHttpBuilder.content - Response-Body: This is CONTENT!!!
06:24:58.131 [Test worker] DEBUG groovy.net.http.JavaHttpBuilder.headers - Response-Header: Content-Encoding -> gzip
06:24:58.131 [Test worker] DEBUG groovy.net.http.JavaHttpBuilder.headers - Response-Header: Connection -> keep-alive
06:24:58.131 [Test worker] DEBUG groovy.net.http.JavaHttpBuilder.headers - Response-Header: Content-Type -> text/plain
06:24:58.131 [Test worker] DEBUG groovy.net.http.JavaHttpBuilder.headers - Response-Header: Content-Length -> 36
06:24:58.131 [Test worker] DEBUG groovy.net.http.JavaHttpBuilder.headers - Response-Header: Date -> Mon, 20 Nov 2017 12:24:50 GMT
06:24:58.132 [Test worker] DEBUG ersatz.undertow - stopping undertow server ersatz.undertow.Undertow@5467b58f
06:24:58.133 [Test worker] DEBUG ersatz.undertow - starting undertow server ersatz.undertow.Undertow@5f21cd09
06:24:58.140 [XNIO-58 I/O-1] DEBUG ersatz.xnio.nio - Started channel thread 'XNIO-58 I/O-1', selector sun.nio.ch.EPollSelectorImpl@56ed8fb2
06:24:58.149 [XNIO-58 I/O-2] DEBUG ersatz.xnio.nio - Started channel thread 'XNIO-58 I/O-2', selector sun.nio.ch.EPollSelectorImpl@35aa0a1a
06:24:58.150 [XNIO-58 I/O-3] DEBUG ersatz.xnio.nio - Started channel thread 'XNIO-58 I/O-3', selector sun.nio.ch.EPollSelectorImpl@5a4d32a8
06:24:58.154 [XNIO-58 I/O-4] DEBUG ersatz.xnio.nio - Started channel thread 'XNIO-58 I/O-4', selector sun.nio.ch.EPollSelectorImpl@21805c1c
06:24:58.157 [XNIO-58 I/O-5] DEBUG ersatz.xnio.nio - Started channel thread 'XNIO-58 I/O-5', selector sun.nio.ch.EPollSelectorImpl@5ae62453
06:24:58.163 [XNIO-58 I/O-6] DEBUG ersatz.xnio.nio - Started channel thread 'XNIO-58 I/O-6', selector sun.nio.ch.EPollSelectorImpl@1642187c
06:24:58.163 [XNIO-58 I/O-7] DEBUG ersatz.xnio.nio - Started channel thread 'XNIO-58 I/O-7', selector sun.nio.ch.EPollSelectorImpl@7aacb32d
06:24:58.164 [XNIO-58 I/O-8] DEBUG ersatz.xnio.nio - Started channel thread 'XNIO-58 I/O-8', selector sun.nio.ch.EPollSelectorImpl@699f2bee
06:24:58.165 [Test worker] DEBUG ersatz.undertow - Configuring listener with protocol HTTP for interface localhost and port 0
06:24:58.167 [Test worker] DEBUG groovyx.net.http.JavaHttpBuilder - Request-URI(HEAD): http://localhost:41143/foo
06:24:58.167 [Test worker] DEBUG groovy.net.http.JavaHttpBuilder.headers - Request-Header: Accept-Encoding -> [gzip, deflate]
06:24:58.170 [XNIO-58 Accept] DEBUG ersatz.xnio.nio - Started channel thread 'XNIO-58 Accept', selector sun.nio.ch.EPollSelectorImpl@73c3526c
06:24:58.186 [XNIO-58 task-1] DEBUG com.stehno.ersatz.ErsatzServer - Request: { HEAD /foo (query=[:], headers={Accept=[text/html, image/gif, image/jpeg, *; q=.2, */*; q=.2], Connection=[keep-alive], Accept-Encoding=[gzip, deflate], User-Agent=[Java/1.8.0_131], Host=[localhost:41143]}, cookies=[:]): <empty> }
06:24:58.187 [XNIO-58 task-1] DEBUG com.stehno.ersatz.ErsatzServer - Response({Content-Type=[text/plain]}): <empty>
06:24:58.190 [Test worker] DEBUG groovy.net.http.JavaHttpBuilder.content - Response-Body: null
06:24:58.190 [Test worker] DEBUG groovy.net.http.JavaHttpBuilder.headers - Response-Header: Connection -> keep-alive
06:24:58.190 [Test worker] DEBUG groovy.net.http.JavaHttpBuilder.headers - Response-Header: Content-Type -> text/plain
06:24:58.190 [Test worker] DEBUG groovy.net.http.JavaHttpBuilder.headers - Response-Header: Content-Length -> 0
06:24:58.190 [Test worker] DEBUG groovy.net.http.JavaHttpBuilder.headers - Response-Header: Date -> Mon, 20 Nov 2017 12:24:50 GMT
06:24:58.191 [Test worker] DEBUG groovyx.net.http.JavaHttpBuilder - Request-URI(HEAD): http://localhost:41143/foo
06:24:58.191 [Test worker] DEBUG groovy.net.http.JavaHttpBuilder.headers - Request-Header: Accept-Encoding -> [gzip, deflate]
06:24:58.202 [XNIO-58 task-2] DEBUG com.stehno.ersatz.ErsatzServer - Request: { HEAD /foo (query=[:], headers={Accept=[text/html, image/gif, image/jpeg, *; q=.2, */*; q=.2], Connection=[keep-alive], Accept-Encoding=[gzip, deflate], User-Agent=[Java/1.8.0_131], Host=[localhost:41143]}, cookies=[:]): <empty> }
06:24:58.202 [XNIO-58 task-2] DEBUG com.stehno.ersatz.ErsatzServer - Response({Content-Type=[text/plain]}): <empty>
06:24:58.203 [Test worker] DEBUG groovy.net.http.JavaHttpBuilder.content - Response-Body: null
06:24:58.203 [Test worker] DEBUG groovy.net.http.JavaHttpBuilder.headers - Response-Header: Connection -> keep-alive
06:24:58.203 [Test worker] DEBUG groovy.net.http.JavaHttpBuilder.headers - Response-Header: Content-Type -> text/plain
06:24:58.203 [Test worker] DEBUG groovy.net.http.JavaHttpBuilder.headers - Response-Header: Content-Length -> 0
06:24:58.203 [Test worker] DEBUG groovy.net.http.JavaHttpBuilder.headers - Response-Header: Date -> Mon, 20 Nov 2017 12:24:50 GMT
06:24:58.203 [Test worker] DEBUG ersatz.undertow - stopping undertow server ersatz.undertow.Undertow@5f21cd09
06:24:58.205 [Test worker] DEBUG ersatz.undertow - starting undertow server ersatz.undertow.Undertow@313f8cfc
06:24:58.207 [XNIO-58 task-2] DEBUG ersatz.undertow.request.io - UT005013: An IOException occurred
java.nio.channels.ClosedChannelException: null
	at sun.nio.ch.SocketChannelImpl.shutdownOutput(SocketChannelImpl.java:797)
	at ersatz.xnio.nio.NioSocketConduit.write(NioSocketConduit.java:170)
	at ersatz.undertow.server.protocol.http.HttpResponseConduit.processWrite(HttpResponseConduit.java:242)
	at ersatz.undertow.server.protocol.http.HttpResponseConduit.flush(HttpResponseConduit.java:739)
	at ersatz.undertow.conduits.HeadStreamSinkConduit.flush(HeadStreamSinkConduit.java:131)
	at ersatz.xnio.conduits.ConduitStreamSinkChannel.flush(ConduitStreamSinkChannel.java:162)
	at ersatz.undertow.channels.DetachableStreamSinkChannel.flush(DetachableStreamSinkChannel.java:119)
	at ersatz.xnio.channels.Channels.flushBlocking(Channels.java:63)
	at ersatz.undertow.io.UndertowOutputStream.close(UndertowOutputStream.java:344)
	at ersatz.undertow.io.BlockingSenderImpl.close(BlockingSenderImpl.java:170)
	at ersatz.undertow.io.DefaultIoCallback.onComplete(DefaultIoCallback.java:54)
	at ersatz.undertow.io.BlockingSenderImpl.invokeOnComplete(BlockingSenderImpl.java:227)
	at ersatz.undertow.io.BlockingSenderImpl.send(BlockingSenderImpl.java:95)
	at ersatz.undertow.io.BlockingSenderImpl.send(BlockingSenderImpl.java:117)
	at com.stehno.ersatz.ErsatzServer.send(ErsatzServer.groovy:494)
	at com.stehno.ersatz.ErsatzServer.access$0(ErsatzServer.groovy)
	at com.stehno.ersatz.ErsatzServer$1.handleRequest(ErsatzServer.groovy:370)
	at ersatz.undertow.server.handlers.HttpTraceHandler.handleRequest(HttpTraceHandler.java:70)
	at ersatz.undertow.server.handlers.encoding.EncodingHandler.handleRequest(EncodingHandler.java:72)
	at ersatz.undertow.server.Connectors.executeRootHandler(Connectors.java:332)
	at ersatz.undertow.server.HttpServerExchange$1.run(HttpServerExchange.java:812)
	at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1149)
	at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624)
	at java.lang.Thread.run(Thread.java:748)
	Suppressed: java.nio.channels.ClosedByInterruptException: null
		at java.nio.channels.spi.AbstractInterruptibleChannel.end(AbstractInterruptibleChannel.java:202)
		at sun.nio.ch.SocketChannelImpl.write(SocketChannelImpl.java:478)
		at ersatz.xnio.nio.NioSocketConduit.write(NioSocketConduit.java:164)
		... 22 common frames omitted
06:24:58.210 [XNIO-59 I/O-2] DEBUG ersatz.xnio.nio - Started channel thread 'XNIO-59 I/O-2', selector sun.nio.ch.EPollSelectorImpl@7ce907e8
06:24:58.211 [XNIO-59 I/O-1] DEBUG ersatz.xnio.nio - Started channel thread 'XNIO-59 I/O-1', selector sun.nio.ch.EPollSelectorImpl@75bb3ec7
06:24:58.214 [XNIO-59 I/O-3] DEBUG ersatz.xnio.nio - Started channel thread 'XNIO-59 I/O-3', selector sun.nio.ch.EPollSelectorImpl@1aba6e63
06:24:58.217 [XNIO-59 I/O-4] DEBUG ersatz.xnio.nio - Started channel thread 'XNIO-59 I/O-4', selector sun.nio.ch.EPollSelectorImpl@3a4220b1
06:24:58.231 [XNIO-59 I/O-5] DEBUG ersatz.xnio.nio - Started channel thread 'XNIO-59 I/O-5', selector sun.nio.ch.EPollSelectorImpl@5b4d0d55
06:24:58.233 [XNIO-59 I/O-6] DEBUG ersatz.xnio.nio - Started channel thread 'XNIO-59 I/O-6', selector sun.nio.ch.EPollSelectorImpl@7db536ba
06:24:58.233 [XNIO-59 I/O-7] DEBUG ersatz.xnio.nio - Started channel thread 'XNIO-59 I/O-7', selector sun.nio.ch.EPollSelectorImpl@3020286f
06:24:58.234 [XNIO-59 I/O-8] DEBUG ersatz.xnio.nio - Started channel thread 'XNIO-59 I/O-8', selector sun.nio.ch.EPollSelectorImpl@43cd9ddb
06:24:58.234 [XNIO-59 Accept] DEBUG ersatz.xnio.nio - Started channel thread 'XNIO-59 Accept', selector sun.nio.ch.EPollSelectorImpl@2ed6e7e3
06:24:58.234 [Test worker] DEBUG ersatz.undertow - Configuring listener with protocol HTTP for interface localhost and port 0
06:24:58.235 [Test worker] DEBUG groovyx.net.http.JavaHttpBuilder - Request-URI(GET): http://localhost:46403/foo
06:24:58.236 [Test worker] DEBUG groovy.net.http.JavaHttpBuilder.headers - Request-Header: Accept-Encoding -> [gzip, deflate]
06:24:58.238 [XNIO-59 task-1] DEBUG com.stehno.ersatz.ErsatzServer - Request: { GET /foo (query=[:], headers={Accept=[text/html, image/gif, image/jpeg, *; q=.2, */*; q=.2], Connection=[keep-alive], Accept-Encoding=[gzip, deflate], User-Agent=[Java/1.8.0_131], Host=[localhost:46403]}, cookies=[:]): <empty> }
06:24:58.238 [XNIO-59 task-1] DEBUG com.stehno.ersatz.ErsatzServer - Response({Content-Type=[text/plain]}): This is CONTENT!!!
06:24:58.239 [Test worker] DEBUG groovy.net.http.JavaHttpBuilder.content - Response-Body: This is CONTENT!!!
06:24:58.239 [Test worker] DEBUG groovy.net.http.JavaHttpBuilder.headers - Response-Header: Content-Encoding -> gzip
06:24:58.239 [Test worker] DEBUG groovy.net.http.JavaHttpBuilder.headers - Response-Header: Connection -> keep-alive
06:24:58.239 [Test worker] DEBUG groovy.net.http.JavaHttpBuilder.headers - Response-Header: Content-Type -> text/plain
06:24:58.239 [Test worker] DEBUG groovy.net.http.JavaHttpBuilder.headers - Response-Header: Content-Length -> 36
06:24:58.239 [Test worker] DEBUG groovy.net.http.JavaHttpBuilder.headers - Response-Header: Date -> Mon, 20 Nov 2017 12:24:50 GMT
06:24:58.240 [Test worker] DEBUG groovyx.net.http.JavaHttpBuilder - Request-URI(GET): http://localhost:46403/foo
06:24:58.240 [Test worker] DEBUG groovy.net.http.JavaHttpBuilder.headers - Request-Header: Accept-Encoding -> [gzip, deflate]
06:24:58.241 [XNIO-59 task-2] DEBUG com.stehno.ersatz.ErsatzServer - Request: { GET /foo (query=[:], headers={Accept=[text/html, image/gif, image/jpeg, *; q=.2, */*; q=.2], Connection=[keep-alive], Accept-Encoding=[gzip, deflate], User-Agent=[Java/1.8.0_131], Host=[localhost:46403]}, cookies=[:]): <empty> }
06:24:58.241 [XNIO-59 task-2] DEBUG com.stehno.ersatz.ErsatzServer - Response({Content-Type=[text/plain]}): This is CONTENT!!!
06:24:58.242 [Test worker] DEBUG groovy.net.http.JavaHttpBuilder.content - Response-Body: This is CONTENT!!!
06:24:58.242 [Test worker] DEBUG groovy.net.http.JavaHttpBuilder.headers - Response-Header: Content-Encoding -> gzip
06:24:58.242 [Test worker] DEBUG groovy.net.http.JavaHttpBuilder.headers - Response-Header: Connection -> keep-alive
06:24:58.242 [Test worker] DEBUG groovy.net.http.JavaHttpBuilder.headers - Response-Header: Content-Type -> text/plain
06:24:58.242 [Test worker] DEBUG groovy.net.http.JavaHttpBuilder.headers - Response-Header: Content-Length -> 36
06:24:58.242 [Test worker] DEBUG groovy.net.http.JavaHttpBuilder.headers - Response-Header: Date -> Mon, 20 Nov 2017 12:24:50 GMT
06:24:58.242 [Test worker] DEBUG ersatz.undertow - stopping undertow server ersatz.undertow.Undertow@313f8cfc
06:24:58.244 [Test worker] DEBUG ersatz.undertow - starting undertow server ersatz.undertow.Undertow@3674686f
06:24:58.244 [XNIO-59 task-2] DEBUG ersatz.undertow.request.io - UT005013: An IOException occurred
java.nio.channels.ClosedChannelException: null
	at sun.nio.ch.SocketChannelImpl.shutdownOutput(SocketChannelImpl.java:797)
	at ersatz.xnio.nio.NioSocketConduit.write(NioSocketConduit.java:190)
	at ersatz.undertow.server.protocol.http.HttpResponseConduit.processWrite(HttpResponseConduit.java:250)
	at ersatz.undertow.server.protocol.http.HttpResponseConduit.write(HttpResponseConduit.java:596)
	at ersatz.undertow.conduits.AbstractFixedLengthStreamSinkConduit.write(AbstractFixedLengthStreamSinkConduit.java:106)
	at ersatz.undertow.conduits.AbstractFixedLengthStreamSinkConduit.write(AbstractFixedLengthStreamSinkConduit.java:120)
	at ersatz.undertow.conduits.DeflatingStreamSinkConduit.performFlushIfRequired(DeflatingStreamSinkConduit.java:419)
	at ersatz.undertow.conduits.DeflatingStreamSinkConduit.flush(DeflatingStreamSinkConduit.java:349)
	at ersatz.xnio.conduits.ConduitStreamSinkChannel.flush(ConduitStreamSinkChannel.java:162)
	at ersatz.undertow.channels.DetachableStreamSinkChannel.flush(DetachableStreamSinkChannel.java:119)
	at ersatz.xnio.channels.Channels.flushBlocking(Channels.java:63)
	at ersatz.undertow.io.UndertowOutputStream.close(UndertowOutputStream.java:344)
	at ersatz.undertow.io.BlockingSenderImpl.close(BlockingSenderImpl.java:170)
	at ersatz.undertow.io.DefaultIoCallback.onComplete(DefaultIoCallback.java:54)
	at ersatz.undertow.io.BlockingSenderImpl.invokeOnComplete(BlockingSenderImpl.java:227)
	at ersatz.undertow.io.BlockingSenderImpl.send(BlockingSenderImpl.java:95)
	at ersatz.undertow.io.BlockingSenderImpl.send(BlockingSenderImpl.java:117)
	at com.stehno.ersatz.ErsatzServer.send(ErsatzServer.groovy:494)
	at com.stehno.ersatz.ErsatzServer.access$0(ErsatzServer.groovy)
	at com.stehno.ersatz.ErsatzServer$1.handleRequest(ErsatzServer.groovy:370)
	at ersatz.undertow.server.handlers.HttpTraceHandler.handleRequest(HttpTraceHandler.java:70)
	at ersatz.undertow.server.handlers.encoding.EncodingHandler.handleRequest(EncodingHandler.java:72)
	at ersatz.undertow.server.Connectors.executeRootHandler(Connectors.java:332)
	at ersatz.undertow.server.HttpServerExchange$1.run(HttpServerExchange.java:812)
	at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1149)
	at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624)
	at java.lang.Thread.run(Thread.java:748)
	Suppressed: java.nio.channels.ClosedByInterruptException: null
		at java.nio.channels.spi.AbstractInterruptibleChannel.end(AbstractInterruptibleChannel.java:202)
		at sun.nio.ch.SocketChannelImpl.write(SocketChannelImpl.java:511)
		at ersatz.xnio.nio.NioSocketConduit.write(NioSocketConduit.java:184)
		... 25 common frames omitted
06:24:58.248 [XNIO-60 I/O-1] DEBUG ersatz.xnio.nio - Started channel thread 'XNIO-60 I/O-1', selector sun.nio.ch.EPollSelectorImpl@af6fd1
06:24:58.250 [XNIO-60 I/O-2] DEBUG ersatz.xnio.nio - Started channel thread 'XNIO-60 I/O-2', selector sun.nio.ch.EPollSelectorImpl@5d89e09
06:24:58.255 [XNIO-60 I/O-3] DEBUG ersatz.xnio.nio - Started channel thread 'XNIO-60 I/O-3', selector sun.nio.ch.EPollSelectorImpl@5b82ec40
06:24:58.263 [XNIO-60 I/O-4] DEBUG ersatz.xnio.nio - Started channel thread 'XNIO-60 I/O-4', selector sun.nio.ch.EPollSelectorImpl@7cc33115
06:24:58.266 [XNIO-60 I/O-5] DEBUG ersatz.xnio.nio - Started channel thread 'XNIO-60 I/O-5', selector sun.nio.ch.EPollSelectorImpl@40f9becc
06:24:58.278 [XNIO-60 I/O-7] DEBUG ersatz.xnio.nio - Started channel thread 'XNIO-60 I/O-7', selector sun.nio.ch.EPollSelectorImpl@444d1d40
06:24:58.278 [XNIO-60 I/O-8] DEBUG ersatz.xnio.nio - Started channel thread 'XNIO-60 I/O-8', selector sun.nio.ch.EPollSelectorImpl@13d751be
06:24:58.278 [Test worker] DEBUG ersatz.undertow - Configuring listener with protocol HTTP for interface localhost and port 0
06:24:58.281 [Test worker] DEBUG groovyx.net.http.JavaHttpBuilder - Request-URI(DELETE): http://localhost:33721/foo
06:24:58.281 [Test worker] DEBUG groovy.net.http.JavaHttpBuilder.headers - Request-Header: Accept-Encoding -> [gzip, deflate]
06:24:58.282 [XNIO-60 Accept] DEBUG ersatz.xnio.nio - Started channel thread 'XNIO-60 Accept', selector sun.nio.ch.EPollSelectorImpl@302ffed7
06:24:58.284 [XNIO-60 task-1] DEBUG com.stehno.ersatz.ErsatzServer - Request: { DELETE /foo (query=[:], headers={Accept=[text/html, image/gif, image/jpeg, *; q=.2, */*; q=.2], Connection=[keep-alive], Accept-Encoding=[gzip, deflate], User-Agent=[Java/1.8.0_131], Host=[localhost:33721]}, cookies=[:]): <empty> }
06:24:58.285 [XNIO-60 task-1] DEBUG com.stehno.ersatz.ErsatzServer - Response({Content-Type=[text/plain]}): This is CONTENT!!!
06:24:58.286 [Test worker] DEBUG groovy.net.http.JavaHttpBuilder.content - Response-Body: This is CONTENT!!!
06:24:58.286 [Test worker] DEBUG groovy.net.http.JavaHttpBuilder.headers - Response-Header: Content-Encoding -> gzip
06:24:58.286 [Test worker] DEBUG groovy.net.http.JavaHttpBuilder.headers - Response-Header: Connection -> keep-alive
06:24:58.286 [Test worker] DEBUG groovy.net.http.JavaHttpBuilder.headers - Response-Header: Content-Type -> text/plain
06:24:58.286 [Test worker] DEBUG groovy.net.http.JavaHttpBuilder.headers - Response-Header: Content-Length -> 36
06:24:58.286 [Test worker] DEBUG groovy.net.http.JavaHttpBuilder.headers - Response-Header: Date -> Mon, 20 Nov 2017 12:24:50 GMT
06:24:58.287 [Test worker] DEBUG groovyx.net.http.JavaHttpBuilder - Request-URI(DELETE): http://localhost:33721/foo
06:24:58.287 [Test worker] DEBUG groovy.net.http.JavaHttpBuilder.headers - Request-Header: Accept-Encoding -> [gzip, deflate]
06:24:58.290 [XNIO-60 I/O-6] DEBUG ersatz.xnio.nio - Started channel thread 'XNIO-60 I/O-6', selector sun.nio.ch.EPollSelectorImpl@1f89e9c7
06:24:58.298 [XNIO-60 task-2] DEBUG com.stehno.ersatz.ErsatzServer - Request: { DELETE /foo (query=[:], headers={Accept=[text/html, image/gif, image/jpeg, *; q=.2, */*; q=.2], Connection=[keep-alive], Accept-Encoding=[gzip, deflate], User-Agent=[Java/1.8.0_131], Host=[localhost:33721]}, cookies=[:]): <empty> }
06:24:58.299 [XNIO-60 task-2] DEBUG com.stehno.ersatz.ErsatzServer - Response({Content-Type=[text/plain]}): This is CONTENT!!!
06:24:58.299 [Test worker] DEBUG groovy.net.http.JavaHttpBuilder.content - Response-Body: This is CONTENT!!!
06:24:58.299 [Test worker] DEBUG groovy.net.http.JavaHttpBuilder.headers - Response-Header: Content-Encoding -> gzip
06:24:58.299 [Test worker] DEBUG groovy.net.http.JavaHttpBuilder.headers - Response-Header: Connection -> keep-alive
06:24:58.299 [Test worker] DEBUG groovy.net.http.JavaHttpBuilder.headers - Response-Header: Content-Type -> text/plain
06:24:58.299 [Test worker] DEBUG groovy.net.http.JavaHttpBuilder.headers - Response-Header: Content-Length -> 36
06:24:58.299 [Test worker] DEBUG groovy.net.http.JavaHttpBuilder.headers - Response-Header: Date -> Mon, 20 Nov 2017 12:24:50 GMT
06:24:58.299 [Test worker] DEBUG ersatz.undertow - stopping undertow server ersatz.undertow.Undertow@3674686f
06:24:58.301 [Test worker] DEBUG ersatz.undertow - starting undertow server ersatz.undertow.Undertow@44347dd1
06:24:58.303 [XNIO-60 task-2] DEBUG ersatz.undertow.request.io - UT005013: An IOException occurred
java.nio.channels.ClosedChannelException: null
	at sun.nio.ch.SocketChannelImpl.shutdownOutput(SocketChannelImpl.java:797)
	at ersatz.xnio.nio.NioSocketConduit.write(NioSocketConduit.java:190)
	at ersatz.undertow.server.protocol.http.HttpResponseConduit.processWrite(HttpResponseConduit.java:250)
	at ersatz.undertow.server.protocol.http.HttpResponseConduit.write(HttpResponseConduit.java:596)
	at ersatz.undertow.conduits.AbstractFixedLengthStreamSinkConduit.write(AbstractFixedLengthStreamSinkConduit.java:106)
	at ersatz.undertow.conduits.AbstractFixedLengthStreamSinkConduit.write(AbstractFixedLengthStreamSinkConduit.java:120)
	at ersatz.undertow.conduits.DeflatingStreamSinkConduit.performFlushIfRequired(DeflatingStreamSinkConduit.java:419)
	at ersatz.undertow.conduits.DeflatingStreamSinkConduit.flush(DeflatingStreamSinkConduit.java:349)
	at ersatz.xnio.conduits.ConduitStreamSinkChannel.flush(ConduitStreamSinkChannel.java:162)
	at ersatz.undertow.channels.DetachableStreamSinkChannel.flush(DetachableStreamSinkChannel.java:119)
	at ersatz.xnio.channels.Channels.flushBlocking(Channels.java:63)
	at ersatz.undertow.io.UndertowOutputStream.close(UndertowOutputStream.java:344)
	at ersatz.undertow.io.BlockingSenderImpl.close(BlockingSenderImpl.java:170)
	at ersatz.undertow.io.DefaultIoCallback.onComplete(DefaultIoCallback.java:54)
	at ersatz.undertow.io.BlockingSenderImpl.invokeOnComplete(BlockingSenderImpl.java:227)
	at ersatz.undertow.io.BlockingSenderImpl.send(BlockingSenderImpl.java:95)
	at ersatz.undertow.io.BlockingSenderImpl.send(BlockingSenderImpl.java:117)
	at com.stehno.ersatz.ErsatzServer.send(ErsatzServer.groovy:494)
	at com.stehno.ersatz.ErsatzServer.access$0(ErsatzServer.groovy)
	at com.stehno.ersatz.ErsatzServer$1.handleRequest(ErsatzServer.groovy:370)
	at ersatz.undertow.server.handlers.HttpTraceHandler.handleRequest(HttpTraceHandler.java:70)
	at ersatz.undertow.server.handlers.encoding.EncodingHandler.handleRequest(EncodingHandler.java:72)
	at ersatz.undertow.server.Connectors.executeRootHandler(Connectors.java:332)
	at ersatz.undertow.server.HttpServerExchange$1.run(HttpServerExchange.java:812)
	at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1149)
	at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624)
	at java.lang.Thread.run(Thread.java:748)
	Suppressed: java.nio.channels.ClosedByInterruptException: null
		at java.nio.channels.spi.AbstractInterruptibleChannel.end(AbstractInterruptibleChannel.java:202)
		at sun.nio.ch.SocketChannelImpl.write(SocketChannelImpl.java:511)
		at ersatz.xnio.nio.NioSocketConduit.write(NioSocketConduit.java:184)
		... 25 common frames omitted
06:24:58.306 [XNIO-61 I/O-1] DEBUG ersatz.xnio.nio - Started channel thread 'XNIO-61 I/O-1', selector sun.nio.ch.EPollSelectorImpl@49c1ad9e
06:24:58.326 [XNIO-61 I/O-2] DEBUG ersatz.xnio.nio - Started channel thread 'XNIO-61 I/O-2', selector sun.nio.ch.EPollSelectorImpl@24880340
06:24:58.334 [XNIO-61 I/O-3] DEBUG ersatz.xnio.nio - Started channel thread 'XNIO-61 I/O-3', selector sun.nio.ch.EPollSelectorImpl@44073427
06:24:58.335 [XNIO-61 I/O-4] DEBUG ersatz.xnio.nio - Started channel thread 'XNIO-61 I/O-4', selector sun.nio.ch.EPollSelectorImpl@383753e8
06:24:58.336 [XNIO-61 I/O-5] DEBUG ersatz.xnio.nio - Started channel thread 'XNIO-61 I/O-5', selector sun.nio.ch.EPollSelectorImpl@2acd4176
06:24:58.336 [XNIO-61 I/O-6] DEBUG ersatz.xnio.nio - Started channel thread 'XNIO-61 I/O-6', selector sun.nio.ch.EPollSelectorImpl@35a86084
06:24:58.336 [XNIO-61 I/O-8] DEBUG ersatz.xnio.nio - Started channel thread 'XNIO-61 I/O-8', selector sun.nio.ch.EPollSelectorImpl@26b5e6e4
06:24:58.339 [XNIO-61 I/O-7] DEBUG ersatz.xnio.nio - Started channel thread 'XNIO-61 I/O-7', selector sun.nio.ch.EPollSelectorImpl@77729ef2
06:24:58.339 [Test worker] DEBUG ersatz.undertow - Configuring listener with protocol HTTP for interface localhost and port 0
06:24:58.341 [Test worker] DEBUG groovyx.net.http.JavaHttpBuilder - Request-URI(HEAD): http://localhost:46717/foo
06:24:58.341 [Test worker] DEBUG groovy.net.http.JavaHttpBuilder.headers - Request-Header: Accept-Encoding -> [gzip, deflate]
06:24:58.342 [XNIO-61 Accept] DEBUG ersatz.xnio.nio - Started channel thread 'XNIO-61 Accept', selector sun.nio.ch.EPollSelectorImpl@37d884e9
06:24:58.344 [XNIO-61 task-1] DEBUG com.stehno.ersatz.ErsatzServer - Request: { HEAD /foo (query=[:], headers={Accept=[text/html, image/gif, image/jpeg, *; q=.2, */*; q=.2], Connection=[keep-alive], Accept-Encoding=[gzip, deflate], User-Agent=[Java/1.8.0_131], Host=[localhost:46717]}, cookies=[:]): <empty> }
06:24:58.346 [XNIO-61 task-1] DEBUG com.stehno.ersatz.ErsatzServer - Response({Content-Type=[text/plain]}): <empty>
06:24:58.346 [Test worker] DEBUG groovy.net.http.JavaHttpBuilder.content - Response-Body: null
06:24:58.346 [Test worker] DEBUG groovy.net.http.JavaHttpBuilder.headers - Response-Header: Connection -> keep-alive
06:24:58.346 [Test worker] DEBUG groovy.net.http.JavaHttpBuilder.headers - Response-Header: Content-Type -> text/plain
06:24:58.346 [Test worker] DEBUG groovy.net.http.JavaHttpBuilder.headers - Response-Header: Content-Length -> 0
06:24:58.346 [Test worker] DEBUG groovy.net.http.JavaHttpBuilder.headers - Response-Header: Date -> Mon, 20 Nov 2017 12:24:50 GMT
06:24:58.346 [Test worker] DEBUG ersatz.undertow - stopping undertow server ersatz.undertow.Undertow@44347dd1