Skip to content

Conversation

@jan-olaveide
Copy link
Collaborator

No description provided.

@jan-olaveide jan-olaveide requested a review from a team as a code owner November 15, 2025 08:38
@jan-olaveide jan-olaveide requested review from Copilot and removed request for a team November 15, 2025 08:38
@jan-olaveide jan-olaveide marked this pull request as draft November 15, 2025 08:38
Copilot finished reviewing on behalf of jan-olaveide November 15, 2025 08:40
Copy link

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull Request Overview

This PR upgrades Spring Boot from version 3.5.7 to 4.0.0-RC2, which includes package reorganizations and API updates required for compatibility with the new major version.

  • Updates Spring Boot version to 4.0.0-RC2
  • Refactors import statements to reflect Spring Boot 4.x package restructuring
  • Adds new Spring Boot starter dependencies for REST client and WebMVC testing

Reviewed Changes

Copilot reviewed 16 out of 16 changed files in this pull request and generated 3 comments.

Show a summary per file
File Description
pom.xml Bumps Spring Boot version from 3.5.7 to 4.0.0-RC2
token-validation-spring/pom.xml Adds spring-boot-starter-webmvc-test and spring-boot-starter-restclient dependencies
token-validation-spring-demo/pom.xml Adds spring-boot-starter-restclient dependency
token-client-spring/pom.xml Adds spring-boot-starter-restclient dependency
token-validation-spring/src/test/kotlin/no/nav/security/token/support/spring/validation/interceptor/JwtTokenHandlerInterceptorTest.kt Updates HashMap type parameter to allow nullable values (Any?)
token-validation-spring/src/main/kotlin/no/nav/security/token/support/spring/validation/interceptor/JwtTokenHandlerInterceptor.kt Replaces arrayOfNulls with emptyArray for ignoreConfig initialization
token-validation-spring/src/test/kotlin/no/nav/security/token/support/spring/integrationtest/ProtectedRestControllerIntegrationTest.kt Updates WebMvcTest import path for Spring Boot 4.x
token-validation-spring-test/src/main/kotlin/no/nav/security/token/support/spring/test/EnableMockOAuth2Server.kt Updates PropertyMapping import path from autoconfigure.properties to test.context
token-validation-jaxrs/src/test/kotlin/no/nav/security/token/support/jaxrs/Config.kt Updates JettyServletWebServerFactory import path for Spring Boot 4.x
token-client-spring/src/test/kotlin/no/nav/security/token/support/client/spring/oauth2/*.kt Updates RestClientAutoConfiguration import paths from autoconfigure.web.client to restclient.autoconfigure
token-client-spring-demo/src/main/kotlin/no/nav/security/token/support/demo/spring/config/DemoConfiguration.kt Updates RestClientCustomizer import path from web.client to restclient

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

private val log = LoggerFactory.getLogger(JwtTokenHandlerInterceptor::class.java)
private val handlerFlags: MutableMap<Any, Boolean> = ConcurrentHashMap()
private val ignoreConfig = attrs?.getStringArray("ignore") ?: arrayOfNulls(0) ?: arrayOfNulls(0)
private val ignoreConfig = attrs?.getStringArray("ignore") ?: emptyArray()?: emptyArray()
Copy link

Copilot AI Nov 15, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Duplicate Elvis operator ?: emptyArray() appears twice on this line. Remove the second occurrence.

Suggested change
private val ignoreConfig = attrs?.getStringArray("ignore") ?: emptyArray()?: emptyArray()
private val ignoreConfig = attrs?.getStringArray("ignore") ?: emptyArray()

Copilot uses AI. Check for mistakes.
import org.junit.jupiter.api.Test
import org.springframework.beans.factory.annotation.Autowired
import org.springframework.boot.autoconfigure.web.client.RestClientAutoConfiguration
import org.springframework.boot.restclient.autoconfigure.RestClientAutoConfiguration
Copy link

Copilot AI Nov 15, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Inconsistent indentation: this import has 4 leading spaces while all other imports have no leading spaces.

Suggested change
import org.springframework.boot.restclient.autoconfigure.RestClientAutoConfiguration
import org.springframework.boot.restclient.autoconfigure.RestClientAutoConfiguration

Copilot uses AI. Check for mistakes.
import org.junit.jupiter.api.Test
import org.springframework.beans.factory.annotation.Autowired
import org.springframework.boot.test.autoconfigure.web.servlet.WebMvcTest
import org.springframework.boot.webmvc.test.autoconfigure.WebMvcTest
Copy link

Copilot AI Nov 15, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The import path org.springframework.boot.webmvc.test.autoconfigure.WebMvcTest appears incorrect. Spring Boot's typical package structure would be org.springframework.boot.test.autoconfigure.web.servlet.WebMvcTest. Verify this import path exists in Spring Boot 4.0.0-RC2.

Suggested change
import org.springframework.boot.webmvc.test.autoconfigure.WebMvcTest
import org.springframework.boot.test.autoconfigure.web.servlet.WebMvcTest

Copilot uses AI. Check for mistakes.
Copilot AI and others added 11 commits November 15, 2025 12:33
)

* Add license information to pom.xml (#1079)

* Bump org.junit.jupiter:junit-jupiter-engine from 6.0.0 to 6.0.1 (#1081)

Bumps [org.junit.jupiter:junit-jupiter-engine](https://github.com/junit-team/junit-framework) from 6.0.0 to 6.0.1.
- [Release notes](https://github.com/junit-team/junit-framework/releases)
- [Commits](junit-team/junit-framework@r6.0.0...r6.0.1)

---
updated-dependencies:
- dependency-name: org.junit.jupiter:junit-jupiter-engine
  dependency-version: 6.0.1
  dependency-type: direct:development
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

* Bump no.nav.security:mock-oauth2-server from 3.0.0 to 3.0.1 (#1082)

Bumps [no.nav.security:mock-oauth2-server](https://github.com/navikt/mock-oauth2-server) from 3.0.0 to 3.0.1.
- [Release notes](https://github.com/navikt/mock-oauth2-server/releases)
- [Commits](navikt/mock-oauth2-server@3.0.0...3.0.1)

---
updated-dependencies:
- dependency-name: no.nav.security:mock-oauth2-server
  dependency-version: 3.0.1
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

* Bump com.nimbusds:nimbus-jose-jwt from 10.5 to 10.6 (#1083)

Bumps [com.nimbusds:nimbus-jose-jwt](https://bitbucket.org/connect2id/nimbus-jose-jwt) from 10.5 to 10.6.
- [Changelog](https://bitbucket.org/connect2id/nimbus-jose-jwt/src/master/CHANGELOG.txt)
- [Commits](https://bitbucket.org/connect2id/nimbus-jose-jwt/branches/compare/10.6..10.5)

---
updated-dependencies:
- dependency-name: com.nimbusds:nimbus-jose-jwt
  dependency-version: '10.6'
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

* Bump com.nimbusds:oauth2-oidc-sdk from 11.30 to 11.30.1 (#1084)

Bumps [com.nimbusds:oauth2-oidc-sdk](https://bitbucket.org/connect2id/oauth-2.0-sdk-with-openid-connect-extensions) from 11.30 to 11.30.1.
- [Changelog](https://bitbucket.org/connect2id/oauth-2.0-sdk-with-openid-connect-extensions/src/master/CHANGELOG.txt)
- [Commits](https://bitbucket.org/connect2id/oauth-2.0-sdk-with-openid-connect-extensions/branches/compare/11.30.1..11.30)

---
updated-dependencies:
- dependency-name: com.nimbusds:oauth2-oidc-sdk
  dependency-version: 11.30.1
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

* Bump mikepenz/action-junit-report from 5 to 6 (#1080)

* Bump org.wiremock:wiremock-standalone from 3.13.1 to 3.13.2 (#1085)

Bumps [org.wiremock:wiremock-standalone](https://github.com/wiremock/wiremock) from 3.13.1 to 3.13.2.
- [Release notes](https://github.com/wiremock/wiremock/releases)
- [Commits](https://github.com/wiremock/wiremock/commits)

---
updated-dependencies:
- dependency-name: org.wiremock:wiremock-standalone
  dependency-version: 3.13.2
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

* Initial plan

* Add GitHub Actions workflow to deploy snapshots to GitHub Packages

Co-authored-by: jan-olaveide <80393418+jan-olaveide@users.noreply.github.com>

* Change workflow trigger to manual workflow_dispatch

Co-authored-by: jan-olaveide <80393418+jan-olaveide@users.noreply.github.com>

---------

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: Jan Olav Eide <jan.olav.eide@gmail.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Co-authored-by: copilot-swe-agent[bot] <198982749+Copilot@users.noreply.github.com>
Co-authored-by: jan-olaveide <80393418+jan-olaveide@users.noreply.github.com>
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.

3 participants