I'm sorry to be late to the game here. The source release for Unix/Linux is really broken (but only that source release).

I recreated a source tarball using the jnirelease.sh script and that tarball was OK. It looks to me that the following happened during rolling the Unix/Linux src tarball for 1.2.0:

- the jnirelease.sh script calls buildconf
- buildconf cleans up some files in line 54 and then copies them in from APR to the build sub directory in line 56. Those files are:

  - build/apr_common.m4
  - build/find_apr.m4
  - build/install.sh \
  - build/config.guess
  - build/config.sub

All of these files are missing from the src tarball. I guess this is due to using a wrong directory in the --with-apr switch to jnirelease.sh. Maybe an apr installation directory instead of an apr source or svn directory. The buildconf script output generated during jnirelease.sh should have given an error when trying to copy the files, but unfortunately doesn't stop in that case.

Due to the missing m4 files, the generated configure script contains lots of unresolved APR m4 macros and doesn't work. But the other missing files will be needed as well.

buildconf should have also generated a file build-outputs.mk which is missing in the tarball. To generate the file it runs "$apr_src_dir/build/gen-build.py make" in line 76, another sign that the apr src dir given to jnirelease.sh wasn't correct (or python was missing).

So the src gz tarball is really broken, one can not build tcnative from it.

Running the TC trunk unit tests against a 1.2.0 build based on a re-rolled tarball using Java 1.8.0_51, APR 1.5.2 and OpenSSL 1.0.2d on Solaris 10 did not show many problems. Harmless failures were

[junit] Test org.apache.tomcat.util.net.openssl.ciphers.TestCipher FAILED [junit] Test org.apache.tomcat.util.net.openssl.ciphers.TestOpenSSLCipherConfigurationParser FAILED

likely due to test suite and my OpenSSL version (1.0.2d) not using the exact same set of ciphers.

More serious was a crash in org.apache.tomcat.websocket.TestWebSocketFrameClientSSL:

Native frames: (J=compiled Java code, j=interpreted, Vv=VM code, C=native code)
C  [libssl.so.1.0.0+0x302cc]  ssl3_write_bytes+0x52c
C  [libssl.so.1.0.0+0x2da84]  ssl3_write+0x64
C  [libssl.so.1.0.0+0x48a40]  SSL_write+0x40
C  [libtcnative-1.so.0.2.0+0x1ea94]  ssl_socket_send+0x6c
C [libtcnative-1.so.0.2.0+0x15bac] Java_org_apache_tomcat_jni_Socket_sendb+0x70
j  org.apache.tomcat.jni.Socket.sendb(JLjava/nio/ByteBuffer;II)I+78334172
j  org.apache.tomcat.jni.Socket.sendb(JLjava/nio/ByteBuffer;II)I+0
j org.apache.tomcat.util.net.AprEndpoint$AprSocketWrapper.doWriteInternal()V+89 j org.apache.tomcat.util.net.AprEndpoint$AprSocketWrapper.doWriteInternal(Z)V+85
j  org.apache.tomcat.util.net.SocketWrapperBase.doWrite(Z)V+2
j  org.apache.tomcat.util.net.SocketWrapperBase.flushBlocking()V+2
j  org.apache.tomcat.util.net.SocketWrapperBase.flush(Z)Z+16
j org.apache.tomcat.websocket.server.WsRemoteEndpointImplServer.doWrite(Ljavax/websocket/SendHandler;J[Ljava/nio/ByteBuffer;)V+188 j org.apache.tomcat.websocket.WsRemoteEndpointImplBase$OutputBufferSendHandler.write()V+263 j org.apache.tomcat.websocket.WsRemoteEndpointImplBase.writeMessagePart(Lorg/apache/tomcat/websocket/MessagePart;)V+353 j org.apache.tomcat.websocket.WsRemoteEndpointImplBase.sendMessageBlock(BLjava/nio/ByteBuffer;ZJ)V+177 j org.apache.tomcat.websocket.WsRemoteEndpointImplBase.sendMessageBlock(Ljava/nio/CharBuffer;Z)V+101 j org.apache.tomcat.websocket.WsRemoteEndpointImplBase.sendString(Ljava/lang/String;)V+33 j org.apache.tomcat.websocket.WsRemoteEndpointBasic.sendText(Ljava/lang/String;)V+5 j org.apache.tomcat.websocket.TesterFirehoseServer$Endpoint.onMessage(Ljavax/websocket/Session;Ljava/lang/String;)V+117

...

j org.apache.tomcat.websocket.pojo.PojoMessageHandlerWholeBase.onMessage(Ljava/lang/Object;)V+147
j  org.apache.tomcat.websocket.WsFrameBase.sendMessageText(Z)V+142
j  org.apache.tomcat.websocket.WsFrameBase.processDataText()Z+425
j  org.apache.tomcat.websocket.WsFrameBase.processData()Z+41
j  org.apache.tomcat.websocket.WsFrameBase.processInputBuffer()V+81
j  org.apache.tomcat.websocket.server.WsFrameServer.onDataAvailable()V+69
j org.apache.tomcat.websocket.server.WsHttpUpgradeHandler.upgradeDispatch(Lorg/apache/tomcat/util/net/SocketStatus;)Lorg/apache/tomcat/util/net/AbstractEndpoint$Handler$SocketState;+64 j org.apache.coyote.http11.upgrade.UpgradeProcessorInternal.dispatch(Lorg/apache/tomcat/util/net/SocketStatus;)Lorg/apache/tomcat/util/net/AbstractEndpoint$Handler$SocketState;+5 j org.apache.coyote.AbstractProcessorLight.process(Lorg/apache/tomcat/util/net/SocketWrapperBase;Lorg/apache/tomcat/util/net/SocketStatus;)Lorg/apache/tomcat/util/net/AbstractEndpoint$Handler$SocketState;+81 j org.apache.coyote.AbstractProtocol$AbstractConnectionHandler.process(Lorg/apache/tomcat/util/net/SocketWrapperBase;Lorg/apache/tomcat/util/net/SocketStatus;)Lorg/apache/tomcat/util/net/AbstractEndpoint$Handler$SocketState;+259
j  org.apache.tomcat.util.net.AprEndpoint$SocketProcessor.run()V+35
j java.util.concurrent.ThreadPoolExecutor.runWorker(Ljava/util/concurrent/ThreadPoolExecutor$Worker;)V+95
j  java.util.concurrent.ThreadPoolExecutor$Worker.run()V+5
j  org.apache.tomcat.util.threads.TaskThread$WrappingRunnable.run()V+4
j  java.lang.Thread.run()V+11
v  ~StubRoutines::call_stub
V [libjvm.so+0x750588] void JavaCalls::call_helper(JavaValue*,methodHandle*,JavaCallArguments*,Thread*)+0xa58 V [libjvm.so+0x74e9b4] void JavaCalls::call_virtual(JavaValue*,KlassHandle,Symbol*,Symbol*,JavaCallArguments*,Thread*)+0x370 V [libjvm.so+0x74ec78] void JavaCalls::call_virtual(JavaValue*,Handle,KlassHandle,Symbol*,Symbol*,Thread*)+0x50
V  [libjvm.so+0x881a7c]  void thread_entry(JavaThread*,Thread*)+0xdc
V  [libjvm.so+0xd64ae4]  void JavaThread::thread_main_inner()+0x94
V  [libjvm.so+0xd64a30]  void JavaThread::run()+0x398
V  [libjvm.so+0xb9f980]  java_start+0x390
C  [libc.so.1+0xd64c0]  _lwp_start+0x8

Before the crash, the test logged:

    [junit] Running org.apache.tomcat.websocket.TestWebSocketFrameClientSSL
[junit] 30-Oct-2015 23:27:10.759 INFO [main] org.apache.catalina.startup.LoggingBaseTest.setUp Starting test case [testBug56032] [junit] 30-Oct-2015 23:27:11.499 INFO [main] org.apache.catalina.core.AprLifecycleListener.lifecycleEvent Loaded APR based Apache Tomcat Native library 1.2.0 using APR version 1.5.2. [junit] 30-Oct-2015 23:27:11.500 INFO [main] org.apache.catalina.core.AprLifecycleListener.lifecycleEvent APR capabilities: IPv6 [true], sendfile [true], accept filters [false], random [true]. [junit] 30-Oct-2015 23:27:11.526 INFO [main] org.apache.catalina.core.AprLifecycleListener.initializeSSL OpenSSL successfully initialized (OpenSSL 1.0.2d 9 Jul 2015) [junit] 30-Oct-2015 23:27:12.709 INFO [main] org.apache.coyote.AbstractProtocol.init Initializing ProtocolHandler ["https-apr-127.0.0.1-auto-1"] [junit] 30-Oct-2015 23:27:12.781 INFO [main] org.apache.catalina.core.StandardService.startInternal Starting service Tomcat [junit] 30-Oct-2015 23:27:12.782 INFO [main] org.apache.catalina.core.StandardEngine.startInternal Starting Servlet Engine: Apache Tomcat/9.0.0-dev [junit] 30-Oct-2015 23:27:13.586 INFO [main] org.apache.coyote.AbstractProtocol.start Starting ProtocolHandler [https-apr-127.0.0.1-auto-1-37331]
    [junit] Waiting for server to report an error
    [junit] Received Hello, now sending data
[junit] 30-Oct-2015 23:32:16.526 INFO [main] org.apache.coyote.AbstractProtocol.pause Pausing ProtocolHandler ["https-apr-127.0.0.1-auto-1-37331"] [junit] 30-Oct-2015 23:32:16.600 INFO [main] org.apache.catalina.core.StandardService.stopInternal Stopping service Tomcat [junit] 30-Oct-2015 23:32:21.621 WARNING [localhost-startStop-2] org.apache.tomcat.websocket.WsSession.doClose Failed to flush batched messages on session close
    [junit]  java.net.SocketTimeoutException
[junit] at org.apache.tomcat.websocket.WsRemoteEndpointImplBase.sendMessageBlock(WsRemoteEndpointImplBase.java:295) [junit] at org.apache.tomcat.websocket.WsRemoteEndpointImplBase.sendMessageBlock(WsRemoteEndpointImplBase.java:256) [junit] at org.apache.tomcat.websocket.WsRemoteEndpointImplBase.flushBatch(WsRemoteEndpointImplBase.java:119) [junit] at org.apache.tomcat.websocket.WsRemoteEndpointImplBase.setBatchingAllowed(WsRemoteEndpointImplBase.java:106) [junit] at org.apache.tomcat.websocket.WsSession.doClose(WsSession.java:469) [junit] at org.apache.tomcat.websocket.WsSession.close(WsSession.java:444) [junit] at org.apache.tomcat.websocket.WsWebSocketContainer.destroy(WsWebSocketContainer.java:789) [junit] at org.apache.tomcat.websocket.server.WsServerContainer.destroy(WsServerContainer.java:280) [junit] at org.apache.tomcat.websocket.server.WsContextListener.contextDestroyed(WsContextListener.java:48) [junit] at org.apache.catalina.core.StandardContext.listenerStop(StandardContext.java:4780) [junit] at org.apache.catalina.core.StandardContext.stopInternal(StandardContext.java:5401) [junit] at org.apache.catalina.util.LifecycleBase.stop(LifecycleBase.java:237) [junit] at org.apache.catalina.core.ContainerBase$StopChild.call(ContainerBase.java:1420) [junit] at org.apache.catalina.core.ContainerBase$StopChild.call(ContainerBase.java:1409)
    [junit]     at java.util.concurrent.FutureTask.run(FutureTask.java:266)
[junit] at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142) [junit] at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617)
    [junit]     at java.lang.Thread.run(Thread.java:745)
    [junit]


Unfortunately the core dump is not digestable by gdb, so I can't easily look at the native data.

Mark: do you want to re-roll? All other files, zip and bins look OK. The src zip doesn't need those missing Unix files at least not for creating a Windows binary. There's also no need for a change to the svn tag, only to rerun jnirelease.sh against a complete apr source directory. I can't really judge, whether the crash is acceptable for a .0 release though.

Sorry for not having joined the tests earlier.

Regards,

Rainer


---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscr...@tomcat.apache.org
For additional commands, e-mail: dev-h...@tomcat.apache.org

Reply via email to