diff --git a/_source/_posts/2022-08-15-spring-boot-crud-update.md b/_source/_posts/2022-08-15-spring-boot-crud-update.md index a1da7617c9..fa8f9590c4 100644 --- a/_source/_posts/2022-08-15-spring-boot-crud-update.md +++ b/_source/_posts/2022-08-15-spring-boot-crud-update.md @@ -62,7 +62,7 @@ okta apps create **Type of Application**: `2: Single Page App` -**Redirect URI(s)**: `http://localhost:8000/login/callback` +**Redirect URI(s)**: `http://localhost:8080/login/callback` All other defaults are fine. @@ -88,7 +88,7 @@ The following command will download the starter project and un-tar it to a new d ```bash curl https://start.spring.io/starter.tgz \ - -d bootVersion=2.6.8 \ + -d bootVersion=2.6.10 \ -d jvmVersion=11 \ -d dependencies=web,data-rest,lombok,data-jpa,h2,okta \ -d type=gradle-project \ @@ -117,6 +117,17 @@ okta.oauth2.issuer= okta.oauth2.clientId= ``` +Open the `build.gradle` file and change the `sourceCompatibility` from 17 to 11. I think this should have been done by the `jvmVersion` flag when the project was downloaded via the REST API. However, for me, it wasn't. If you're running Java 17 locally, it won't matter, but if you're running Java 11 this will cause an error when you try and run the project. +```groovy +sourceCompatibility = '11' +``` + +You can run the bare project right now and see if it starts. + +```bash +./gradlew bootRun +``` + **You need to replace the two bracketed values** with the values you generated above for the OIDC app using the Okta CLI. Create a class to configure web security. The class below configures web security to allow all requests, effectively bypassing security. This is just so you can test the resource server initially. You'll enable security shortly. @@ -805,110 +816,212 @@ Create the `Todos` component. ```vue + - ``` This component encapsulates the card that holds all of the todos, as well as the todo-associated interface elements. It also handles the rest of the functions related to updating todos on the server as well as in the local cache. +You're welcome to delete the `HelloWorld.vue` component, if you want. Or you can leave it. It's not needed. + ## Test the todo app Make sure the Spring Boot server is still running. In a separate Bash shell, from the resource server directory, run the following command (if it is not already still running)