Skip to content
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

Fix : Can't handle CJK multibyte request in AJP parameter value #275

Closed
wants to merge 2 commits into from

Conversation

nameislocus
Copy link

Problem :

In HTTP protocol hander can handle multibyte character set. My case use EUC-KR character set. Tested in Wildfly 8.2 GA.

            <server name="default-server">
                <ajp-listener name="ajp" socket-binding="ajp" url-charset="EUC-KR"/>
                <http-listener name="default" socket-binding="http" url-charset="EUC-KR"/>

http://localhost:8080/test/test.jsp?param=한글

But, When I use AJP protocol can't handle EUC-KR character set.
http://localhost/test/test.jsp?param=한글

Query param's value are not '한글', it prints '??'.
Similar cases are in https://developer.jboss.org/thread/242677?start=0&tstart=0

Reason :

I found that it cause of handle byte as a char in AbstractAjpParser.
Multibyte(CJK ; Chinese, Japanese, Korean) character set are use most significant bit. So, when byte are casted to char, multibytes informations are eliminated.

Thanks for your great 'undertow'.

@undertow-pull-request
Copy link

Windows Build 905 is now running using a merge of c9c994c

@undertow-pull-request
Copy link

Linux Build 1341 is now running using a merge of c9c994c

@undertow-pull-request
Copy link

Windows Build 905 outcome was FAILURE using a merge of c9c994c
Summary: Tests failed: 13 (10 new), passed: 3059, ignored: 365 Build time: 0:12:21

Build problems:

Failed tests detected

Failed tests

io.undertow.server.security.SpnegoDigestAuthenticationTestCase.testDigestSuccess: java.lang.AssertionError: expected:<200> but was:<401>
    at org.junit.Assert.fail(Assert.java:88)
    at org.junit.Assert.failNotEquals(Assert.java:743)

io.undertow.server.security.SpnegoDigestAuthenticationTestCase.testNonceCountReUse: java.lang.AssertionError: expected:<200> but was:<401>
    at org.junit.Assert.fail(Assert.java:88)
    at org.junit.Assert.failNotEquals(Assert.java:743)

io.undertow.server.protocol.ajp.AjpParsingUnitTestCase.testByteByByteAjpParsing: java.lang.AssertionError: null
    at org.junit.Assert.fail(Assert.java:86)
    at org.junit.Assert.assertTrue(Assert.java:41)

io.undertow.server.protocol.ajp.AjpParsingUnitTestCase.testByteByByteAjpParsing: java.lang.AssertionError: null
    at org.junit.Assert.fail(Assert.java:86)
    at org.junit.Assert.assertTrue(Assert.java:41)

io.undertow.server.protocol.ajp.AjpParsingUnitTestCase.testByteByByteAjpParsing: java.lang.AssertionError: null
    at org.junit.Assert.fail(Assert.java:86)
    at org.junit.Assert.assertTrue(Assert.java:41)

io.undertow.server.protocol.ajp.AjpParsingUnitTestCase.testByteByByteAjpParsing: java.lang.AssertionError: null
    at org.junit.Assert.fail(Assert.java:86)
    at org.junit.Assert.assertTrue(Assert.java:41)

io.undertow.server.security.SpnegoDigestAuthenticationTestCase.testNonceCountReUse{proxy}{https}: java.lang.AssertionError: expected:<200> but was:<401>
    at org.junit.Assert.fail(Assert.java:88)
    at org.junit.Assert.failNotEquals(Assert.java:743)

io.undertow.server.protocol.ajp.AjpParsingUnitTestCase.testByteByByteAjpParsing: java.lang.AssertionError: null
    at org.junit.Assert.fail(Assert.java:86)
    at org.junit.Assert.assertTrue(Assert.java:41)

io.undertow.server.protocol.ajp.AjpParsingUnitTestCase.testByteByByteAjpParsing: java.lang.AssertionError: null
    at org.junit.Assert.fail(Assert.java:86)
    at org.junit.Assert.assertTrue(Assert.java:41)

io.undertow.server.protocol.ajp.AjpParsingUnitTestCase.testByteByByteAjpParsing: java.lang.AssertionError: null
    at org.junit.Assert.fail(Assert.java:86)
    at org.junit.Assert.assertTrue(Assert.java:41)

io.undertow.server.handlers.HttpTunnelingViaConnectTestCase.testConnectViaProxy{proxy}{spdy}: java.lang.AssertionError: null
    at org.junit.Assert.fail(Assert.java:86)
    at org.junit.Assert.assertTrue(Assert.java:41)


##### there are 3 more failed tests, see build details

@undertow-pull-request
Copy link

Linux Build 1341 outcome was FAILURE using a merge of c9c994c
Summary: Tests failed: 10 (7 new), passed: 3139, ignored: 288 Build time: 0:13:25

Build problems:

Failed tests detected

Failed tests

io.undertow.server.protocol.ajp.AjpParsingUnitTestCase.testByteByByteAjpParsing: java.lang.AssertionError: null
    at org.junit.Assert.fail(Assert.java:86)
    at org.junit.Assert.assertTrue(Assert.java:41)

io.undertow.server.protocol.ajp.AjpParsingUnitTestCase.testByteByByteAjpParsing: java.lang.AssertionError: null
    at org.junit.Assert.fail(Assert.java:86)
    at org.junit.Assert.assertTrue(Assert.java:41)

io.undertow.server.protocol.ajp.AjpParsingUnitTestCase.testByteByByteAjpParsing: java.lang.AssertionError: null
    at org.junit.Assert.fail(Assert.java:86)
    at org.junit.Assert.assertTrue(Assert.java:41)

io.undertow.server.protocol.ajp.AjpParsingUnitTestCase.testByteByByteAjpParsing: java.lang.AssertionError: null
    at org.junit.Assert.fail(Assert.java:86)
    at org.junit.Assert.assertTrue(Assert.java:41)

io.undertow.server.protocol.ajp.AjpParsingUnitTestCase.testByteByByteAjpParsing: java.lang.AssertionError: null
    at org.junit.Assert.fail(Assert.java:86)
    at org.junit.Assert.assertTrue(Assert.java:41)

io.undertow.server.protocol.ajp.AjpParsingUnitTestCase.testByteByByteAjpParsing: java.lang.AssertionError: null
    at org.junit.Assert.fail(Assert.java:86)
    at org.junit.Assert.assertTrue(Assert.java:41)

io.undertow.server.protocol.ajp.AjpParsingUnitTestCase.testByteByByteAjpParsing: java.lang.AssertionError: null
    at org.junit.Assert.fail(Assert.java:86)
    at org.junit.Assert.assertTrue(Assert.java:41)

io.undertow.server.handlers.HttpTunnelingViaConnectTestCase.testConnectViaProxy{proxy}{spdy}: java.lang.AssertionError: null
    at org.junit.Assert.fail(Assert.java:86)
    at org.junit.Assert.assertTrue(Assert.java:41)

io.undertow.server.handlers.HttpTunnelingViaConnectTestCase.testConnectViaProxy{proxy}{http2}: java.lang.AssertionError: null
    at org.junit.Assert.fail(Assert.java:86)
    at org.junit.Assert.assertTrue(Assert.java:41)

io.undertow.server.handlers.HttpTunnelingViaConnectTestCase.testConnectViaProxy{proxy}{http2-clear}: java.lang.AssertionError: null
    at org.junit.Assert.fail(Assert.java:86)
    at org.junit.Assert.assertTrue(Assert.java:41)

@undertow-pull-request
Copy link

Windows Build 906 is now running using a merge of e2c0429

@undertow-pull-request
Copy link

Linux Build 1342 is now running using a merge of e2c0429

@undertow-pull-request
Copy link

Windows Build 906 outcome was FAILURE using a merge of e2c0429
Summary: Tests failed: 28 (24 new), passed: 3045, ignored: 365 Build time: 0:18:54

Build problems:

Failed tests detected

Failed tests

io.undertow.server.ssl.SimpleSSLTestCase.simpleSSLTestCase{proxy}{ajp}: java.net.SocketTimeoutException: Read timed out
    at java.net.SocketInputStream.socketRead0(Native Method)
    at java.net.SocketInputStream.read(SocketInputStream.java:150)

io.undertow.server.security.DigestAuthenticationAuthTestCase.testDigestSuccess{proxy}{ajp}: java.lang.AssertionError: expected:<200> but was:<401>
    at org.junit.Assert.fail(Assert.java:88)
    at org.junit.Assert.failNotEquals(Assert.java:743)

io.undertow.server.security.SimpleConfidentialRedirectTestCase.simpleRedirectTestCase{proxy}{ajp}: java.net.SocketTimeoutException: Read timed out
    at java.net.SocketInputStream.socketRead0(Native Method)
    at java.net.SocketInputStream.read(SocketInputStream.java:150)

io.undertow.server.security.ClientCertTestCase.testClientCertSuccess{proxy}{ajp}: java.net.SocketTimeoutException: Read timed out
    at java.net.SocketInputStream.socketRead0(Native Method)
    at java.net.SocketInputStream.read(SocketInputStream.java:150)

io.undertow.server.handlers.proxy.LoadBalancingProxySPDYTestCase.testStickySessions{proxy}{ajp}: java.lang.AssertionError: expected:<200> but was:<503>
    at org.junit.Assert.fail(Assert.java:88)
    at org.junit.Assert.failNotEquals(Assert.java:743)

io.undertow.server.handlers.proxy.LoadBalancingProxySPDYTestCase.testStickySessions{proxy}{ajp}: java.lang.RuntimeException: Buffer Leak io.undertow.server.handlers.proxy.LoadBalancingProxySPDYTestCase.testStickySessions{proxy}{ajp}
    at io.undertow.testutils.DefaultServer$1.testFinished(DefaultServer.java:259)
    at org.junit.runner.notification.RunNotifier$7.notifyListener(RunNotifier.java:191)

io.undertow.server.handlers.proxy.LoadBalancingProxyAJPTestCase.testStickySessions{proxy}{spdy}: java.lang.AssertionError: expected:<200> but was:<503>
    at org.junit.Assert.fail(Assert.java:88)
    at org.junit.Assert.failNotEquals(Assert.java:743)

io.undertow.server.handlers.proxy.LoadBalancingProxyAJPTestCase.testLoadShared{proxy}{spdy}: java.lang.AssertionError: expected:<200> but was:<503>
    at org.junit.Assert.fail(Assert.java:88)
    at org.junit.Assert.failNotEquals(Assert.java:743)

io.undertow.server.handlers.proxy.LoadBalancingProxyAJPTestCase.testLoadSharedWithServerShutdown{proxy}{spdy}: java.lang.RuntimeException: Failed with i=0
    at io.undertow.server.handlers.proxy.AbstractLoadBalancingProxyTestCase.testLoadSharedWithServerShutdown(AbstractLoadBalancingProxyTestCase.java:94)
    at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)

io.undertow.server.handlers.proxy.LoadBalancingProxyAJPTestCase.testDuplicateHeaders{proxy}{spdy}: java.lang.AssertionError: expected:<200> but was:<503>
    at org.junit.Assert.fail(Assert.java:88)
    at org.junit.Assert.failNotEquals(Assert.java:743)

io.undertow.server.handlers.proxy.LoadBalancingProxyAJPTestCase.testStickySessions{proxy}{https}: java.lang.AssertionError: expected:<200> but was:<503>
    at org.junit.Assert.fail(Assert.java:88)
    at org.junit.Assert.failNotEquals(Assert.java:743)


##### there are 18 more failed tests, see build details

@undertow-pull-request
Copy link

Linux Build 1342 outcome was FAILURE using a merge of e2c0429
Summary: Tests failed: 28 (25 new), passed: 3125, ignored: 288 Build time: 0:20:30

Build problems:

Failed tests detected

Failed tests

io.undertow.server.ssl.SimpleSSLTestCase.simpleSSLTestCase{proxy}{ajp}: java.net.SocketTimeoutException: Read timed out
    at java.net.SocketInputStream.socketRead0(Native Method)
    at java.net.SocketInputStream.read(SocketInputStream.java:152)

io.undertow.server.security.SimpleConfidentialRedirectTestCase.simpleRedirectTestCase{proxy}{ajp}: java.net.SocketTimeoutException: Read timed out
    at java.net.SocketInputStream.socketRead0(Native Method)
    at java.net.SocketInputStream.read(SocketInputStream.java:152)

io.undertow.server.security.ClientCertTestCase.testClientCertSuccess{proxy}{ajp}: java.net.SocketTimeoutException: Read timed out
    at java.net.SocketInputStream.socketRead0(Native Method)
    at java.net.SocketInputStream.read(SocketInputStream.java:152)

io.undertow.server.handlers.FixedLengthResponseTestCase.sendHttpRequest{proxy}{ajp}: java.lang.RuntimeException: Buffer Leak io.undertow.server.handlers.FixedLengthResponseTestCase.sendHttpRequest{proxy}{ajp}
    at io.undertow.testutils.DefaultServer$1.testFinished(DefaultServer.java:259)
    at org.junit.runner.notification.RunNotifier$7.notifyListener(RunNotifier.java:191)

io.undertow.server.handlers.proxy.LoadBalancingProxyAJPTestCase.testStickySessions{proxy}{spdy}: java.lang.AssertionError: expected:<200> but was:<503>
    at org.junit.Assert.fail(Assert.java:88)
    at org.junit.Assert.failNotEquals(Assert.java:743)

io.undertow.server.handlers.proxy.LoadBalancingProxyAJPTestCase.testLoadShared{proxy}{spdy}: java.lang.AssertionError: expected:<200> but was:<503>
    at org.junit.Assert.fail(Assert.java:88)
    at org.junit.Assert.failNotEquals(Assert.java:743)

io.undertow.server.handlers.proxy.LoadBalancingProxyAJPTestCase.testLoadSharedWithServerShutdown{proxy}{spdy}: java.lang.RuntimeException: Failed with i=0
    at io.undertow.server.handlers.proxy.AbstractLoadBalancingProxyTestCase.testLoadSharedWithServerShutdown(AbstractLoadBalancingProxyTestCase.java:94)
    at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)

io.undertow.server.handlers.proxy.LoadBalancingProxyAJPTestCase.testDuplicateHeaders{proxy}{spdy}: java.lang.AssertionError: expected:<200> but was:<503>
    at org.junit.Assert.fail(Assert.java:88)
    at org.junit.Assert.failNotEquals(Assert.java:743)

io.undertow.server.handlers.proxy.LoadBalancingProxyAJPTestCase.testStickySessions{proxy}{https}: java.lang.AssertionError: expected:<200> but was:<503>
    at org.junit.Assert.fail(Assert.java:88)
    at org.junit.Assert.failNotEquals(Assert.java:743)

io.undertow.server.handlers.proxy.LoadBalancingProxyAJPTestCase.testLoadShared{proxy}{https}: java.lang.AssertionError: expected:<200> but was:<503>
    at org.junit.Assert.fail(Assert.java:88)
    at org.junit.Assert.failNotEquals(Assert.java:743)

io.undertow.server.handlers.proxy.LoadBalancingProxyAJPTestCase.testLoadSharedWithServerShutdown{proxy}{https}: java.lang.RuntimeException: Failed with i=0
    at io.undertow.server.handlers.proxy.AbstractLoadBalancingProxyTestCase.testLoadSharedWithServerShutdown(AbstractLoadBalancingProxyTestCase.java:94)
    at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)


##### there are 18 more failed tests, see build details

@undertow-pull-request
Copy link

Windows Build 909 is now running using a merge of e2c0429

@undertow-pull-request
Copy link

Linux Build 1345 is now running using a merge of e2c0429

@undertow-pull-request
Copy link

Windows Build 909 outcome was FAILURE using a merge of e2c0429
Summary: Tests failed: 24, passed: 3048, ignored: 365 Build time: 0:20:16

Build problems:

Failed tests detected

Failed tests

io.undertow.server.ssl.SimpleSSLTestCase.simpleSSLTestCase{proxy}{ajp}: java.net.SocketTimeoutException: Read timed out
    at java.net.SocketInputStream.socketRead0(Native Method)
    at java.net.SocketInputStream.read(SocketInputStream.java:152)

io.undertow.server.security.SimpleConfidentialRedirectTestCase.simpleRedirectTestCase{proxy}{ajp}: java.net.SocketTimeoutException: Read timed out
    at java.net.SocketInputStream.socketRead0(Native Method)
    at java.net.SocketInputStream.read(SocketInputStream.java:152)

io.undertow.server.security.ClientCertTestCase.testClientCertSuccess{proxy}{ajp}: java.net.SocketTimeoutException: Read timed out
    at java.net.SocketInputStream.socketRead0(Native Method)
    at java.net.SocketInputStream.read(SocketInputStream.java:152)

io.undertow.server.handlers.proxy.LoadBalancingProxyAJPTestCase.testStickySessions{proxy}{spdy}: java.lang.AssertionError: expected:<200> but was:<503>
    at org.junit.Assert.fail(Assert.java:88)
    at org.junit.Assert.failNotEquals(Assert.java:743)

io.undertow.server.handlers.proxy.LoadBalancingProxyAJPTestCase.testLoadShared{proxy}{spdy}: java.lang.AssertionError: expected:<200> but was:<503>
    at org.junit.Assert.fail(Assert.java:88)
    at org.junit.Assert.failNotEquals(Assert.java:743)

io.undertow.server.handlers.proxy.LoadBalancingProxyAJPTestCase.testLoadSharedWithServerShutdown{proxy}{spdy}: java.lang.RuntimeException: Failed with i=0
    at io.undertow.server.handlers.proxy.AbstractLoadBalancingProxyTestCase.testLoadSharedWithServerShutdown(AbstractLoadBalancingProxyTestCase.java:94)
    at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)

io.undertow.server.handlers.proxy.LoadBalancingProxyAJPTestCase.testDuplicateHeaders{proxy}{spdy}: java.lang.AssertionError: expected:<200> but was:<503>
    at org.junit.Assert.fail(Assert.java:88)
    at org.junit.Assert.failNotEquals(Assert.java:743)

io.undertow.server.handlers.HttpTunnelingViaConnectTestCase.testConnectViaProxy{proxy}{spdy}: java.lang.AssertionError: null
    at org.junit.Assert.fail(Assert.java:86)
    at org.junit.Assert.assertTrue(Assert.java:41)

io.undertow.server.handlers.proxy.LoadBalancingProxyAJPTestCase.testStickySessions{proxy}{https}: java.lang.AssertionError: expected:<200> but was:<503>
    at org.junit.Assert.fail(Assert.java:88)
    at org.junit.Assert.failNotEquals(Assert.java:743)

io.undertow.server.handlers.proxy.LoadBalancingProxyAJPTestCase.testLoadShared{proxy}{https}: java.lang.AssertionError: expected:<200> but was:<503>
    at org.junit.Assert.fail(Assert.java:88)
    at org.junit.Assert.failNotEquals(Assert.java:743)

io.undertow.server.handlers.proxy.LoadBalancingProxyAJPTestCase.testLoadSharedWithServerShutdown{proxy}{https}: java.lang.RuntimeException: Failed with i=0
    at io.undertow.server.handlers.proxy.AbstractLoadBalancingProxyTestCase.testLoadSharedWithServerShutdown(AbstractLoadBalancingProxyTestCase.java:94)
    at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)


##### there are 14 more failed tests, see build details

@undertow-pull-request
Copy link

Linux Build 1345 outcome was FAILURE using a merge of e2c0429
Summary: Tests failed: 28 (1 new), passed: 3125, ignored: 288 Build time: 0:20:25

Build problems:

Failed tests detected

Failed tests

io.undertow.server.handlers.LotsOfHeadersResponseTestCase.testLotsOfHeadersInResponse{proxy}{ajp}: java.lang.RuntimeException: Buffer Leak io.undertow.server.handlers.LotsOfHeadersResponseTestCase.testLotsOfHeadersInResponse{proxy}{ajp}
    at io.undertow.testutils.DefaultServer$1.testFinished(DefaultServer.java:259)
    at org.junit.runner.notification.RunNotifier$7.notifyListener(RunNotifier.java:191)

io.undertow.server.ssl.SimpleSSLTestCase.simpleSSLTestCase{proxy}{ajp}: java.net.SocketTimeoutException: Read timed out
    at java.net.SocketInputStream.socketRead0(Native Method)
    at java.net.SocketInputStream.read(SocketInputStream.java:152)

io.undertow.server.security.SimpleConfidentialRedirectTestCase.simpleRedirectTestCase{proxy}{ajp}: java.net.SocketTimeoutException: Read timed out
    at java.net.SocketInputStream.socketRead0(Native Method)
    at java.net.SocketInputStream.read(SocketInputStream.java:152)

io.undertow.server.security.ClientCertTestCase.testClientCertSuccess{proxy}{ajp}: java.net.SocketTimeoutException: Read timed out
    at java.net.SocketInputStream.socketRead0(Native Method)
    at java.net.SocketInputStream.read(SocketInputStream.java:152)

io.undertow.server.handlers.proxy.LoadBalancingProxyAJPTestCase.testStickySessions{proxy}{spdy}: java.lang.AssertionError: expected:<200> but was:<503>
    at org.junit.Assert.fail(Assert.java:88)
    at org.junit.Assert.failNotEquals(Assert.java:743)

io.undertow.server.handlers.proxy.LoadBalancingProxyAJPTestCase.testLoadShared{proxy}{spdy}: java.lang.AssertionError: expected:<200> but was:<503>
    at org.junit.Assert.fail(Assert.java:88)
    at org.junit.Assert.failNotEquals(Assert.java:743)

io.undertow.server.handlers.proxy.LoadBalancingProxyAJPTestCase.testLoadSharedWithServerShutdown{proxy}{spdy}: java.lang.RuntimeException: Failed with i=0
    at io.undertow.server.handlers.proxy.AbstractLoadBalancingProxyTestCase.testLoadSharedWithServerShutdown(AbstractLoadBalancingProxyTestCase.java:94)
    at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)

io.undertow.server.handlers.proxy.LoadBalancingProxyAJPTestCase.testDuplicateHeaders{proxy}{spdy}: java.lang.AssertionError: expected:<200> but was:<503>
    at org.junit.Assert.fail(Assert.java:88)
    at org.junit.Assert.failNotEquals(Assert.java:743)

io.undertow.server.handlers.HttpTunnelingViaConnectTestCase.testConnectViaProxy{proxy}{spdy}: java.lang.AssertionError: null
    at org.junit.Assert.fail(Assert.java:86)
    at org.junit.Assert.assertTrue(Assert.java:41)

io.undertow.server.handlers.proxy.LoadBalancingProxyAJPTestCase.testStickySessions{proxy}{https}: java.lang.AssertionError: expected:<200> but was:<503>
    at org.junit.Assert.fail(Assert.java:88)
    at org.junit.Assert.failNotEquals(Assert.java:743)

io.undertow.server.handlers.proxy.LoadBalancingProxyAJPTestCase.testLoadShared{proxy}{https}: java.lang.AssertionError: expected:<200> but was:<503>
    at org.junit.Assert.fail(Assert.java:88)
    at org.junit.Assert.failNotEquals(Assert.java:743)


##### there are 18 more failed tests, see build details

@undertow-pull-request
Copy link

Windows Build 914 is now running using a merge of e2c0429

@undertow-pull-request
Copy link

Linux Build 1350 is now running using a merge of e2c0429

@undertow-pull-request
Copy link

Windows Build 914 outcome was FAILURE using a merge of e2c0429
Summary: Tests failed: 23 (2 new), passed: 3043, ignored: 371 Build time: 0:19:24

Build problems:

Failed tests detected

Failed tests

io.undertow.server.handlers.proxy.LoadBalancingProxyTestCase.testLoadShared{proxy}{https}: java.lang.AssertionError: expected:<200> but was:<500>
    at org.junit.Assert.fail(Assert.java:88)
    at org.junit.Assert.failNotEquals(Assert.java:743)

io.undertow.server.handlers.proxy.LoadBalancingProxyTestCase.testLoadSharedWithServerShutdown{proxy}{https}: java.lang.RuntimeException: Failed with i=3
    at io.undertow.server.handlers.proxy.AbstractLoadBalancingProxyTestCase.testLoadSharedWithServerShutdown(AbstractLoadBalancingProxyTestCase.java:94)
    at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)

io.undertow.server.ssl.SimpleSSLTestCase.simpleSSLTestCase{proxy}{ajp}: java.net.SocketTimeoutException: Read timed out
    at java.net.SocketInputStream.socketRead0(Native Method)
    at java.net.SocketInputStream.read(SocketInputStream.java:152)

io.undertow.server.security.SimpleConfidentialRedirectTestCase.simpleRedirectTestCase{proxy}{ajp}: java.net.SocketTimeoutException: Read timed out
    at java.net.SocketInputStream.socketRead0(Native Method)
    at java.net.SocketInputStream.read(SocketInputStream.java:152)

io.undertow.server.security.ClientCertTestCase.testClientCertSuccess{proxy}{ajp}: java.net.SocketTimeoutException: Read timed out
    at java.net.SocketInputStream.socketRead0(Native Method)
    at java.net.SocketInputStream.read(SocketInputStream.java:152)

io.undertow.server.handlers.proxy.LoadBalancingProxyAJPTestCase.testStickySessions{proxy}{spdy}: java.lang.AssertionError: expected:<200> but was:<503>
    at org.junit.Assert.fail(Assert.java:88)
    at org.junit.Assert.failNotEquals(Assert.java:743)

io.undertow.server.handlers.proxy.LoadBalancingProxyAJPTestCase.testLoadShared{proxy}{spdy}: java.lang.AssertionError: expected:<200> but was:<503>
    at org.junit.Assert.fail(Assert.java:88)
    at org.junit.Assert.failNotEquals(Assert.java:743)

io.undertow.server.handlers.proxy.LoadBalancingProxyAJPTestCase.testLoadSharedWithServerShutdown{proxy}{spdy}: java.lang.RuntimeException: Failed with i=0
    at io.undertow.server.handlers.proxy.AbstractLoadBalancingProxyTestCase.testLoadSharedWithServerShutdown(AbstractLoadBalancingProxyTestCase.java:94)
    at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)

io.undertow.server.handlers.proxy.LoadBalancingProxyAJPTestCase.testDuplicateHeaders{proxy}{spdy}: java.lang.AssertionError: expected:<200> but was:<503>
    at org.junit.Assert.fail(Assert.java:88)
    at org.junit.Assert.failNotEquals(Assert.java:743)

io.undertow.server.handlers.proxy.LoadBalancingProxyAJPTestCase.testStickySessions{proxy}{https}: java.lang.AssertionError: expected:<200> but was:<503>
    at org.junit.Assert.fail(Assert.java:88)
    at org.junit.Assert.failNotEquals(Assert.java:743)

io.undertow.server.handlers.proxy.LoadBalancingProxyAJPTestCase.testLoadShared{proxy}{https}: java.lang.AssertionError: expected:<200> but was:<503>
    at org.junit.Assert.fail(Assert.java:88)
    at org.junit.Assert.failNotEquals(Assert.java:743)


##### there are 13 more failed tests, see build details

@undertow-pull-request
Copy link

Linux Build 1350 outcome was FAILURE using a merge of e2c0429
Summary: Tests failed: 25, passed: 3122, ignored: 294 Build time: 0:20:53

Build problems:

Failed tests detected

Failed tests

io.undertow.server.ssl.SimpleSSLTestCase.simpleSSLTestCase{proxy}{ajp}: java.net.SocketTimeoutException: Read timed out
    at java.net.SocketInputStream.socketRead0(Native Method)
    at java.net.SocketInputStream.read(SocketInputStream.java:152)

io.undertow.server.security.SimpleConfidentialRedirectTestCase.simpleRedirectTestCase{proxy}{ajp}: java.net.SocketTimeoutException: Read timed out
    at java.net.SocketInputStream.socketRead0(Native Method)
    at java.net.SocketInputStream.read(SocketInputStream.java:152)

io.undertow.server.security.ClientCertTestCase.testClientCertSuccess{proxy}{ajp}: java.net.SocketTimeoutException: Read timed out
    at java.net.SocketInputStream.socketRead0(Native Method)
    at java.net.SocketInputStream.read(SocketInputStream.java:152)

io.undertow.server.handlers.LotsOfHeadersResponseTestCase.testLotsOfHeadersInResponse{proxy}{ajp}: java.lang.RuntimeException: Buffer Leak io.undertow.server.handlers.LotsOfHeadersResponseTestCase.testLotsOfHeadersInResponse{proxy}{ajp}
    at io.undertow.testutils.DefaultServer$1.testFinished(DefaultServer.java:259)
    at org.junit.runner.notification.RunNotifier$7.notifyListener(RunNotifier.java:191)

io.undertow.server.handlers.proxy.LoadBalancingProxyAJPTestCase.testStickySessions{proxy}{spdy}: java.lang.AssertionError: expected:<200> but was:<503>
    at org.junit.Assert.fail(Assert.java:88)
    at org.junit.Assert.failNotEquals(Assert.java:743)

io.undertow.server.handlers.proxy.LoadBalancingProxyAJPTestCase.testLoadShared{proxy}{spdy}: java.lang.AssertionError: expected:<200> but was:<503>
    at org.junit.Assert.fail(Assert.java:88)
    at org.junit.Assert.failNotEquals(Assert.java:743)

io.undertow.server.handlers.proxy.LoadBalancingProxyAJPTestCase.testLoadSharedWithServerShutdown{proxy}{spdy}: java.lang.RuntimeException: Failed with i=0
    at io.undertow.server.handlers.proxy.AbstractLoadBalancingProxyTestCase.testLoadSharedWithServerShutdown(AbstractLoadBalancingProxyTestCase.java:94)
    at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)

io.undertow.server.handlers.proxy.LoadBalancingProxyAJPTestCase.testDuplicateHeaders{proxy}{spdy}: java.lang.AssertionError: expected:<200> but was:<503>
    at org.junit.Assert.fail(Assert.java:88)
    at org.junit.Assert.failNotEquals(Assert.java:743)

io.undertow.server.handlers.proxy.LoadBalancingProxyAJPTestCase.testStickySessions{proxy}{https}: java.lang.AssertionError: expected:<200> but was:<503>
    at org.junit.Assert.fail(Assert.java:88)
    at org.junit.Assert.failNotEquals(Assert.java:743)

io.undertow.server.handlers.proxy.LoadBalancingProxyAJPTestCase.testLoadShared{proxy}{https}: java.lang.AssertionError: expected:<200> but was:<503>
    at org.junit.Assert.fail(Assert.java:88)
    at org.junit.Assert.failNotEquals(Assert.java:743)

io.undertow.server.handlers.proxy.LoadBalancingProxyAJPTestCase.testLoadSharedWithServerShutdown{proxy}{https}: java.lang.RuntimeException: Failed with i=0
    at io.undertow.server.handlers.proxy.AbstractLoadBalancingProxyTestCase.testLoadSharedWithServerShutdown(AbstractLoadBalancingProxyTestCase.java:94)
    at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)


##### there are 15 more failed tests, see build details

@stuartwdouglas
Copy link
Contributor

Thanks for the PR, I have created https://issues.jboss.org/browse/UNDERTOW-362 to track this. I will probably fix this a slightly different way however, as List is very inefficient (it creates a lot of unnecessary objects)

@stuartwdouglas
Copy link
Contributor

Thanks for the PR, however I have fixed it a different way that should give better performance:
a567f4e

Can you test this out and make sure it works for you?

@nameislocus
Copy link
Author

It works very well.
Thanks for your fix.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
3 participants