Skip to content
This repository has been archived by the owner on Nov 22, 2024. It is now read-only.

Commit

Permalink
Update dependencies.
Browse files Browse the repository at this point in the history
  • Loading branch information
gijskant committed Jul 3, 2020
1 parent f81b674 commit 98740cd
Show file tree
Hide file tree
Showing 2 changed files with 51 additions and 12 deletions.
31 changes: 24 additions & 7 deletions pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
<parent>
<groupId>org.springframework.boot</groupId>
<artifactId>spring-boot-starter-parent</artifactId>
<version>2.2.4.RELEASE</version>
<version>2.3.1.RELEASE</version>
<relativePath/> <!-- lookup parent from repository -->
</parent>
<groupId>nl.thehyve</groupId>
Expand All @@ -15,22 +15,27 @@
<description>Data warehouse Inventory Management System</description>

<properties>
<equalsverifier.version>3.1.12</equalsverifier.version>
<hibernate-jcache.version>5.4.10.Final</hibernate-jcache.version>
<keycloak.version>8.0.2</keycloak.version>
<liquibase.version>3.8.5</liquibase.version>
<lombok.version>1.18.10</lombok.version>
<equalsverifier.version>3.4.1</equalsverifier.version>
<hibernate-jcache.version>5.4.17.Final</hibernate-jcache.version>
<keycloak.version>10.0.2</keycloak.version>
<liquibase.version>3.10.0</liquibase.version>
<lombok.version>1.18.12</lombok.version>
<java.version>11</java.version>
<jacoco-maven-plugin.version>0.8.2</jacoco-maven-plugin.version>
<mapstruct.version>1.3.1.Final</mapstruct.version>
<postgresql.version>42.2.9</postgresql.version>
<owasp-dependency-check.version>5.3.2</owasp-dependency-check.version>
<postgresql.version>42.2.14</postgresql.version>
</properties>

<dependencies>
<dependency>
<groupId>org.springframework.boot</groupId>
<artifactId>spring-boot-starter-data-jpa</artifactId>
</dependency>
<dependency>
<groupId>org.springframework.boot</groupId>
<artifactId>spring-boot-starter-validation</artifactId>
</dependency>
<dependency>
<groupId>org.springframework.boot</groupId>
<artifactId>spring-boot-starter-web</artifactId>
Expand Down Expand Up @@ -159,6 +164,18 @@
</annotationProcessorPaths>
</configuration>
</plugin>
<plugin>
<groupId>org.owasp</groupId>
<artifactId>dependency-check-maven</artifactId>
<version>${owasp-dependency-check.version}</version>
<executions>
<execution>
<goals>
<goal>check</goal>
</goals>
</execution>
</executions>
</plugin>
</plugins>
</build>

Expand Down
32 changes: 27 additions & 5 deletions src/main/java/nl/thehyve/whereabouts/config/KeycloakConfig.java
Original file line number Diff line number Diff line change
@@ -1,15 +1,37 @@
package nl.thehyve.whereabouts.config;

import org.keycloak.adapters.springboot.KeycloakSpringBootConfigResolver;
import org.springframework.context.annotation.Bean;
import org.keycloak.adapters.KeycloakConfigResolver;
import org.keycloak.adapters.KeycloakDeployment;
import org.keycloak.adapters.KeycloakDeploymentBuilder;
import org.keycloak.adapters.spi.HttpFacade;
import org.keycloak.representations.adapters.config.AdapterConfig;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.context.annotation.Configuration;
import org.springframework.context.annotation.Primary;

@Configuration
public class KeycloakConfig {

@Bean
public KeycloakSpringBootConfigResolver KeycloakConfigResolver() {
return new KeycloakSpringBootConfigResolver();
@Primary
@Configuration
static
class CustomKeycloakSpringBootConfigResolver implements KeycloakConfigResolver {

private final AdapterConfig adapterConfig;
private KeycloakDeployment keycloakDeployment;

@Autowired
CustomKeycloakSpringBootConfigResolver(AdapterConfig adapterConfig) {
this.adapterConfig = adapterConfig;
}

@Override
public KeycloakDeployment resolve(HttpFacade.Request request) {
if (this.keycloakDeployment == null) {
this.keycloakDeployment = KeycloakDeploymentBuilder.build(this.adapterConfig);
}
return this.keycloakDeployment;
}
}

}

0 comments on commit 98740cd

Please sign in to comment.