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

115 Upgrade Spring Boot #168

Merged
merged 29 commits into from
Nov 10, 2023
Merged

115 Upgrade Spring Boot #168

merged 29 commits into from
Nov 10, 2023

Conversation

Pfeil
Copy link
Member

@Pfeil Pfeil commented Sep 14, 2023

Fixes #155

  • fix deprecated stuff before upgrade, as far as possible
  • Upgrade spring boot, service-base and repo-core and make it compiling
  • builds
  • runs
  • tests run
    • test which do not work anymore due to the change on the error message not being available now, but the body is.
    • tests which return 404 instead of 200 when querying known pids
    • tests testing swagger availability: returns 403 on access. Probably related to spring security filter chain.
    • tests of elasticsearch run (disabled by default, require a local elastic instance)
      • Caused by: java.net.UnknownHostException: http://localhost:9200: nodename nor servname provided, or not known even though elastic was available at this address (tried elastic 7 and 8)
  • fix linting issues
  • test coverage – I can't see why it should have changed (claimed -0.3%). So I took the opportunity to test the handlediff class.

Breaking changes:

  • It does now matter if /api/v1/known-pids (works) is queried or /api/v1/known-pids/. This is due to a change in spring boot 3. I do not plan to work around this, as some options may be deprecated at some point anyway, and any other workaround will include a lot of boilerplate.

@coveralls
Copy link

coveralls commented Sep 14, 2023

Pull Request Test Coverage Report for Build #313

  • 1 of 1 (100.0%) changed or added relevant line in 1 file are covered.
  • 1 unchanged line in 1 file lost coverage.
  • Overall coverage increased (+2.6%) to 72.606%

Files with Coverage Reduction New Missed Lines %
src/main/java/edu/kit/datamanager/pit/pidlog/KnownPid.java 1 95.56%
Totals Coverage Status
Change from base Build #302: 2.6%
Covered Lines: 872
Relevant Lines: 1201

💛 - Coveralls

@Pfeil
Copy link
Member Author

Pfeil commented Sep 15, 2023

Current issue: If running the application (or tests) it directly crashes.

Pointers from the exception so far:

  • Something seems to require javax.servlet.http.HttpServletRequest, which has been renamed to jakarta. But as it compiles, it is definitely not in my code.
  • Some OpenAPI class is appearing in the output
  • High-level reason is an exception in the spring web security config class (filterChain function/bean, "Error creating bean with name 'filterChain'")
  • "Factory method 'selfLinkProvider' threw exception with message: Error creating bean with name 'mvcConversionService': Requested bean is currently in creation: Is there an unresolvable circular reference?"

It seems the only place I can influence here is the filterChain method, so I should look into fixing/refactoring this one.

Edit: The culprit was the outdated springdoc version. Fixed.

@Pfeil Pfeil linked an issue Sep 23, 2023 that may be closed by this pull request
@Pfeil Pfeil marked this pull request as ready for review November 10, 2023 18:14
@Pfeil Pfeil merged commit 1e403b6 into dev-v2 Nov 10, 2023
4 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Upgrade Spring Boot
2 participants