GithubHelp home page GithubHelp logo

Comments (4)

wilkinsona avatar wilkinsona commented on April 28, 2024 1

Thanks for the report. We have integration tests for restarts with both a local application and a remote application. The app that's used for tests uses Tomcat and all of the tests are passing. In short, we're not aware of any general problems with the remote restart support so there must be something specific to your usage of it that is causing it to break.

As a reproducer project you can use JKube's Spring Boot Watch quickstart and a local Kubernetes cluster such as Minikube.

Unfortunately, we don't have time to use such a complex reproducer as there are too many moving parts. Any one of them could be causing the problem, not just Spring Boot. If you would like us to spend some more time investigating, please provide a reproducer that contains the bare minimum that's needed to reproduce the problem. The process of producing this reproducer may identify an external cause which can then be addressed by the relevant maintainers. If it identifies Spring Boot as the cause we can then take another look and see why our existing tests didn't catch the problem.

from spring-boot.

manusa avatar manusa commented on April 28, 2024

Hi @wilkinsona,

I managed to create a fairly simple end to end (e2e) test project that consistently reproduces the issue.
You can check the source code here: https://github.com/marcnuri-work/spring-projects-spring-boot-issues-39733/tree/290fe9c5e81c994154b0bf949b10dfef3145ba97.

You should be able to clone the project and run ./mvnw verify to run the tests.
I also defined a GitHub CI workflow which also reproduces the issue.

If you carefully review the CI logs, you'll notice that with version 2.7.11, the test does pass:
https://github.com/marcnuri-work/spring-projects-spring-boot-issues-39733/actions/runs/8100572266/job/22138883889#step:4:1501

However, for the 2.7.12 version the test fails (I assume it will be the same for any 3.x.x version too):
https://github.com/marcnuri-work/spring-projects-spring-boot-issues-39733/actions/runs/8100572266/job/22138883889#step:4:1502

I configured the test to print out the log of the remote application, we can see here the stacktrace I mentioned in the issue description:

Caused by: java.lang.Error: factory already defined
	at java.base/java.net.URL.setURLStreamHandlerFactory(URL.java:1392) ~[na:na]

Regarding the integration test you linked, I'm not sure if it applies to the current scenario (Remote Update). I do see there's a RemoteApplicationLauncher, but this one doesn't contain a test scenario for the update feature either.


P.S. I saw there was a link to the integration tests after bootstrapping my own project and working on the complete implementation 🤦. I would have worked on the original repo otherwise, sorry.

from spring-boot.

wilkinsona avatar wilkinsona commented on April 28, 2024

Regarding the integration test you linked, I'm not sure if it applies to the current scenario (Remote Update). I do see there's a RemoteApplicationLauncher, but this one doesn't contain a test scenario for the update feature either.

I am pretty sure that it does. Every test in that class is making an update to the application. The tests are run in three different ways:

  • With a local application
  • With a remote application
  • With a remote application running as a jar file

However, for the 2.7.12 version the test fails (I assume it will be the same for any 3.x.x version too):

Spring Boot 2.7.x is out of OSS support. Do you know that it fails with 3.x.x or is this just an assumption?

from spring-boot.

manusa avatar manusa commented on April 28, 2024

I am pretty sure that it does.

As I said, I just gave an overall look, I surely missed it. I assumed it was just testing with local application. Since it's an integration test (no apparent separate process invocations) it's hard (for me) to understand what's really going on.

Do you know that it fails with 3.x.x or is this just an assumption?

Not an assumption, it has the same failure https://github.com/marcnuri-work/spring-projects-spring-boot-issues-39733/actions/runs/8115267126/job/22182771368#step:4:1942 (I just added 3.2.0 to the test suite).

P.S. BTW learning that end of commercial support for 2.x (i.e. Java 8) is mid 2025 just killed me, for some reason I thought it was mid-2024 when it would be over 😭,

from spring-boot.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.