spring-projects / spring-lifecycle-smoke-tests

24 stars 18 forks source link

Fix `webflux-netty` smoke test #14

Closed sdeleuze closed 12 months ago

sdeleuze commented 1 year ago

When @violetagg is back, let see what can be made on Netty side to fix current failure.

Notice on Linux aarch64 running on a Mac M2, it seems to work as expected, so the failure may be architecture specific.

violetagg commented 1 year ago

I'll check that

violetagg commented 1 year ago

@sdeleuze @wilkinsona We need to dispose ReactorResourceFactory on checkpoint and then to recreate it on restore.

https://github.com/spring-projects/spring-boot/blob/018c188cebfda2750d2cc4302343a646105fe0a7/spring-boot-project/spring-boot/src/main/java/org/springframework/boot/web/embedded/netty/NettyReactiveWebServerFactory.java#L163

sdeleuze commented 1 year ago

I will do some related test for the HTTP client and provide a feedback since ReactorResourceFactory seems to be used on both client and server.

sdeleuze commented 1 year ago

So I was able to have WebClient with Reactor Netty working with checkpoint/restore after the following modification visible on this branch:

Looks like modifications would be needed on both Framework and Boot sides to support Reactor Netty, so let's discuss it in an upcoming meeting.

sdeleuze commented 1 year ago

I think I have been able to fix that purely on Spring Framework side, will push related changes after most test and polish.

sdeleuze commented 1 year ago

With https://github.com/spring-projects/spring-framework/commit/125b8e741805cc678c427abb248859bd084f0989, ReactorResourceFactory is now lifecycle-aware, but unlike what I initially thought, some refinements are likely going to be needed on Spring Boot side, I have created https://github.com/spring-projects/spring-boot/issues/37209 related issue.

sdeleuze commented 12 months ago

The related smoke test is now green, thanks @wilkinsona!