Skip to content

Commit

Permalink
anvender RestTemplateAzure class fra felles i ApplicationConfig. Rett…
Browse files Browse the repository at this point in the history
…er på application-local
  • Loading branch information
throndi committed Jul 30, 2024
1 parent aaf46ed commit 6d77ee4
Show file tree
Hide file tree
Showing 3 changed files with 7 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@ package no.nav.familie.ef.mottak.config
import com.fasterxml.jackson.module.kotlin.KotlinModule
import no.nav.familie.http.client.RetryOAuth2HttpClient
import no.nav.familie.http.config.RestTemplateBuilderBean
import no.nav.familie.http.config.RestTemplateAzure
import no.nav.familie.http.interceptor.BearerTokenClientInterceptor
import no.nav.familie.http.interceptor.BearerTokenExchangeClientInterceptor
import no.nav.familie.http.interceptor.ConsumerIdClientInterceptor
Expand Down Expand Up @@ -49,6 +50,7 @@ import java.time.temporal.ChronoUnit
MdcValuesPropagatingClientInterceptor::class,
ConsumerIdClientInterceptor::class,
KafkaErrorHandler::class,
RestTemplateAzure::class,
)
class ApplicationConfig {
private val logger = LoggerFactory.getLogger(ApplicationConfig::class.java)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ import java.net.URI
@Service
class PdlClient(
val pdlConfig: PdlConfig,
@Qualifier("restTemplateAzure") restTemplate: RestOperations,
@Qualifier("azureClientCredential") restTemplate: RestOperations,
) : AbstractPingableRestClient(restTemplate, "pdl.personinfo") {
override val pingUri: URI
get() = pdlConfig.pdlUri
Expand Down
5 changes: 4 additions & 1 deletion src/test/resources/application-local.yml
Original file line number Diff line number Diff line change
Expand Up @@ -94,7 +94,6 @@ dittnav.soknadfrontendUrl: http://localhost:3000/familie/alene-med-barn/soknad
EF_SAK_URL: http://localhost:8092/mockintegrasjoner/
ettersending.ettersendingUrl: http://localhost:3000/

AZUREAD_TOKEN_ENDPOINT_URL: https://login.microsoftonline.com/navq.onmicrosoft.com/oauth2/v2.0/token
ON_PREM_URL_ENV: dev

TOKEN_X_WELL_KNOWN_URL: http://localhost
Expand All @@ -109,5 +108,9 @@ TOKEN_X_PRIVATE_JWK: '{
UNLEASH_SERVER_API_URL: http://localhost:4242/api
UNLEASH_SERVER_API_TOKEN: token
NAIS_APP_NAME: familie-ef-mottak
API_SCOPE: api://${AZURE_APP_CLIENT_ID}/.default
AZURE_APP_TENANT_ID: navq.onmicrosoft.com
AZUREAD_TOKEN_ENDPOINT_URL: https://login.microsoftonline.com/navq.onmicrosoft.com/oauth2/v2.0/token
AUTHORIZATION_URL: https://login.microsoftonline.com/${AZURE_APP_TENANT_ID}/oauth2/v2.0/authorize

prosessering.rolle: "928636f4-fd0d-4149-978e-a6fb68bb19de" # 0000-GA-STDAPPS

0 comments on commit 6d77ee4

Please sign in to comment.