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

TCK Challenge: JAXRSClientIT#closeTest fixes #1196 #1197

Closed
wants to merge 1 commit into from

Conversation

jbescos
Copy link
Member

@jbescos jbescos commented Nov 29, 2023

Relates to #1196

It also increased the frequency that events are sent back. I had a problem in Helidon that it took longer than the test expects to be aware of the closed stream.

This is the stacktrace when the exception is thrown:

, ee.jakarta.tck.ws.rs.jaxrs21.ee.sse.sseeventsource.RepeatedCasterResource$1.run(RepeatedCasterResource.java:58)]
, org.glassfish.jersey.media.sse.internal.JerseyEventSink.send(JerseyEventSink.java:140)
, org.glassfish.jersey.server.ChunkedOutput.write(ChunkedOutput.java:184)
, org.glassfish.jersey.server.ChunkedOutput.flushQueue(ChunkedOutput.java:198)
, org.glassfish.jersey.process.internal.RequestScope.runInScope(RequestScope.java:314)
, org.glassfish.jersey.internal.Errors.process(Errors.java:219)
, org.glassfish.jersey.internal.Errors.process(Errors.java:292)
, org.glassfish.jersey.server.ChunkedOutput$1.call(ChunkedOutput.java:198)
, org.glassfish.jersey.server.ChunkedOutput$1.call(ChunkedOutput.java:231)
, org.glassfish.jersey.message.internal.MessageBodyFactory.writeTo(MessageBodyFactory.java:1116)
, org.glassfish.jersey.message.internal.WriterInterceptorExecutor.proceed(WriterInterceptorExecutor.java:139)
, org.glassfish.jersey.message.internal.WriterInterceptorExecutor$TerminalWriterInterceptor.aroundWriteTo(WriterInterceptorExecutor.java:227)
, org.glassfish.jersey.message.internal.WriterInterceptorExecutor$TerminalWriterInterceptor.invokeWriteTo(WriterInterceptorExecutor.java:242)
, org.glassfish.jersey.media.sse.OutboundEventWriter.writeTo(OutboundEventWriter.java:44)
, org.glassfish.jersey.media.sse.OutboundEventWriter.writeTo(OutboundEventWriter.java:118)
, org.glassfish.jersey.message.internal.StringMessageProvider.writeTo(StringMessageProvider.java:36)
, org.glassfish.jersey.message.internal.StringMessageProvider.writeTo(StringMessageProvider.java:76)
, org.glassfish.jersey.message.internal.AbstractMessageReaderWriterProvider.writeToAsString(AbstractMessageReaderWriterProvider.java:107)
, org.glassfish.jersey.message.internal.ReaderWriter.writeToAsString(ReaderWriter.java:247)
, java.base/java.io.OutputStreamWriter.flush(OutputStreamWriter.java:262)
, java.base/sun.nio.cs.StreamEncoder.flush(StreamEncoder.java:201)
, java.base/sun.nio.cs.StreamEncoder.lockedFlush(StreamEncoder.java:214)
, java.base/sun.nio.cs.StreamEncoder.implFlush(StreamEncoder.java:410)
, java.base/sun.nio.cs.StreamEncoder.implFlushBuffer(StreamEncoder.java:405)
, java.base/sun.nio.cs.StreamEncoder.writeBytes(StreamEncoder.java:309)
, java.base/java.io.OutputStream.write(OutputStream.java:167)
, org.glassfish.jersey.media.sse.OutboundEventWriter$1.write(OutboundEventWriter.java:132)
, org.glassfish.jersey.message.internal.WriterInterceptorExecutor$UnCloseableOutputStream.write(WriterInterceptorExecutor.java:271)
, org.glassfish.jersey.message.internal.CommittingOutputStream.write(CommittingOutputStream.java:185)
, io.helidon.microprofile.server.JaxRsService$NoFlushOutputStream.write(JaxRsService.java:402)
, java.base/java.io.FilterOutputStream.write(FilterOutputStream.java:110)
, java.base/java.io.BufferedOutputStream.write(BufferedOutputStream.java:206)
, java.base/java.io.BufferedOutputStream.implWrite(BufferedOutputStream.java:222)
, java.base/java.io.BufferedOutputStream.flushBuffer(BufferedOutputStream.java:125)
, io.helidon.webserver.http1.Http1ServerResponse$BlockingOutputStream.write(Http1ServerResponse.java:439)
, io.helidon.webserver.http1.Http1ServerResponse$BlockingOutputStream.write(Http1ServerResponse.java:591)
, io.helidon.webserver.http1.Http1ServerResponse$BlockingOutputStream.writeChunked(Http1ServerResponse.java:665)
, io.helidon.common.socket.SocketWriterDirect.write(SocketWriterDirect.java:43)
, io.helidon.common.socket.SocketWriter.writeNow(SocketWriter.java:77)
, io.helidon.common.socket.PlainSocket.write(PlainSocket.java:136)
, io.helidon.common.buffers.FixedBufferData.writeTo(FixedBufferData.java:71)
, java.base/java.net.Socket$SocketOutputStream.write(Socket.java:1195)
, java.base/sun.nio.ch.NioSocketImpl$2.write(NioSocketImpl.java:819)
, java.base/sun.nio.ch.NioSocketImpl.write(NioSocketImpl.java:440)
, java.base/sun.nio.ch.NioSocketImpl.implWrite(NioSocketImpl.java:410)
, java.base/sun.nio.ch.NioSocketImpl.tryWrite(NioSocketImpl.java:394)
, java.base/sun.nio.ch.SocketDispatcher.write(SocketDispatcher.java:62)
[java.base/sun.nio.ch.SocketDispatcher.write0(Native Method)

@jbescos jbescos changed the title TCK Challenge: RepeatedCasterResource#send fixes #1196 TCK Challenge: JAXRSClientIT#closeTest fixes #1196 Nov 29, 2023
@spericas
Copy link
Contributor

spericas commented Dec 4, 2023

@jbescos If we "fix" a TCK test, we also need to exclude the test until the next release. Fixing a test may cause another implementation that is already "certified" to fail for some reason, so we need to delay its execution. So you need to provide the exclusion as well.

@alwin-joseph can explain this better.

@spericas spericas self-requested a review December 4, 2023 20:48
@spericas spericas self-assigned this Dec 4, 2023
@jbescos
Copy link
Member Author

jbescos commented Dec 5, 2023

Thanks for checking it @spericas. What is the proper way to exclude it, with @Disabled?

@alwin-joseph
Copy link
Contributor

Yes @jbescos We use @Disabled to exclude the test once the corresponding TCK challenge for the specific version is accepted.
So, since the test in latest TCK 3.1.4 is challenged here via #1196, once the challenge is accepted we can exclude the same in branch release-3.1.x , for eg: #1181.
This PR for fixing the test can exist in master branch as it will be in effect for next release(4.0).

@jbescos
Copy link
Member Author

jbescos commented Dec 5, 2023

Thank you @alwin-joseph . It is disabled now for branch release-3.1.x #1198

@jbescos
Copy link
Member Author

jbescos commented Dec 6, 2023

Issue closed

@jbescos jbescos closed this Dec 6, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants