Skip to content

Commit

Permalink
Fjern ubrukt httpclient
Browse files Browse the repository at this point in the history
  • Loading branch information
tu55eladd committed Sep 18, 2024
1 parent 7bf33e7 commit baa8409
Show file tree
Hide file tree
Showing 2 changed files with 0 additions and 9 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -37,13 +37,6 @@ public class OkHttpClientConfig {
.build();
}

@Bean OkHttpClient veilarbpersonHttpClient(MeterRegistry meterRegistry, AzureAdMachineToMachineTokenClient azureAdMachineToMachineTokenClient) {
return RestClient.baseClientBuilder()
.addInterceptor(azureAdInterceptor(() -> azureAdMachineToMachineTokenClient.createMachineToMachineToken(veilarbpersonScope)))
.eventListener(OkHttpMetricsEventListener.builder(meterRegistry, "okhttp.requests").build())
.build();
}

@Bean OkHttpClient veilarbarenaHttpClient(MeterRegistry meterRegistry, AzureAdMachineToMachineTokenClient azureAdMachineToMachineTokenClient) {
return RestClient.baseClientBuilder()
.addInterceptor(azureAdInterceptor(() -> azureAdMachineToMachineTokenClient.createMachineToMachineToken(veilarbarenaScope)))
Expand All @@ -68,7 +61,6 @@ public class OkHttpClientConfig {
}

private final String veilarboppfolgingScope = String.format("api://%s-gcp.poao.veilarboppfolging/.default", isProduction().orElse(false) ? "prod" : "dev");
private final String veilarbpersonScope = String.format("api://%s-fss.pto.veilarbperson/.default", isProduction().orElse(false) ? "prod" : "dev");
private final String veilarbarenaScope = String.format("api://%s-fss.pto.veilarbarena/.default", isProduction().orElse(false) ? "prod" : "dev");
private final String orkivarScope = String.format("api://%s-gcp.dab.orkivar/.default", isProduction().orElse(false) ? "prod" : "dev");
private final String dialogScope = String.format("api://%s-gcp.dab.veilarbdialog/.default", isProduction().orElse(false) ? "prod" : "dev");
Expand Down
1 change: 0 additions & 1 deletion src/test/resources/application.properties
Original file line number Diff line number Diff line change
Expand Up @@ -81,7 +81,6 @@ spring.graphql.graphiql.enabled=true

######### Eksterne tjenester #############
VEILARBOPPFOLGINGAPI_URL=http://localhost:${wiremock.server.port}
VEILARBPERSONAPI_URL=http://localhost:${wiremock.server.port}/veilarbperson/api
app.env.veilarena.serviceurl=http://localhost:${wiremock.server.port}
wiremock.server.httpsPort=-1
orkivar.url=http://localhost:${wiremock.server.port}/orkivar
Expand Down

0 comments on commit baa8409

Please sign in to comment.