diff options
author | Dan Timoney <dtimoney@att.com> | 2019-10-31 12:57:09 +0000 |
---|---|---|
committer | Gerrit Code Review <gerrit@onap.org> | 2019-10-31 12:57:09 +0000 |
commit | 987afaa51413b2b943deb2afdcdc92b89f16fc4c (patch) | |
tree | 04e0d3080d766a456b75b74bc999ab9f0b76a3b4 /ms/blueprintsprocessor/application/src | |
parent | e2619d958f8237f00467da8cacb0fb9fd210a323 (diff) | |
parent | 6fd8d3dbd0c6cdd27f9ef975e4a6a45403dfb298 (diff) |
Merge "Add GRPC log tracing service."
Diffstat (limited to 'ms/blueprintsprocessor/application/src')
2 files changed, 4 insertions, 2 deletions
diff --git a/ms/blueprintsprocessor/application/src/main/kotlin/org/onap/ccsdk/cds/blueprintsprocessor/BlueprintGRPCServer.kt b/ms/blueprintsprocessor/application/src/main/kotlin/org/onap/ccsdk/cds/blueprintsprocessor/BlueprintGRPCServer.kt index 160a1b1b4..2d39eaa1f 100644 --- a/ms/blueprintsprocessor/application/src/main/kotlin/org/onap/ccsdk/cds/blueprintsprocessor/BlueprintGRPCServer.kt +++ b/ms/blueprintsprocessor/application/src/main/kotlin/org/onap/ccsdk/cds/blueprintsprocessor/BlueprintGRPCServer.kt @@ -18,6 +18,7 @@ package org.onap.ccsdk.cds.blueprintsprocessor import io.grpc.ServerBuilder import org.onap.ccsdk.cds.blueprintsprocessor.designer.api.BluePrintManagementGRPCHandler +import org.onap.ccsdk.cds.blueprintsprocessor.grpc.interceptor.GrpcServerLoggingInterceptor import org.onap.ccsdk.cds.blueprintsprocessor.security.BasicAuthServerInterceptor import org.onap.ccsdk.cds.blueprintsprocessor.selfservice.api.BluePrintProcessingGRPCHandler import org.onap.ccsdk.cds.controllerblueprints.core.logger @@ -44,6 +45,7 @@ open class BlueprintGRPCServer(private val bluePrintProcessingGRPCHandler: BlueP log.info("Starting Blueprint Processor GRPC Starting..") val server = ServerBuilder .forPort(grpcPort!!) + .intercept(GrpcServerLoggingInterceptor()) .intercept(authInterceptor) .addService(bluePrintProcessingGRPCHandler) .addService(bluePrintManagementGRPCHandler) diff --git a/ms/blueprintsprocessor/application/src/main/kotlin/org/onap/ccsdk/cds/blueprintsprocessor/LoggingWebFilter.kt b/ms/blueprintsprocessor/application/src/main/kotlin/org/onap/ccsdk/cds/blueprintsprocessor/LoggingWebFilter.kt index 5ed5ff450..68fbf256c 100644 --- a/ms/blueprintsprocessor/application/src/main/kotlin/org/onap/ccsdk/cds/blueprintsprocessor/LoggingWebFilter.kt +++ b/ms/blueprintsprocessor/application/src/main/kotlin/org/onap/ccsdk/cds/blueprintsprocessor/LoggingWebFilter.kt @@ -16,7 +16,7 @@ package org.onap.ccsdk.cds.blueprintsprocessor -import org.onap.ccsdk.cds.blueprintsprocessor.core.service.LoggingService +import org.onap.ccsdk.cds.blueprintsprocessor.rest.service.RestLoggerService import org.onap.ccsdk.cds.controllerblueprints.core.MDCContext import org.springframework.stereotype.Component import org.springframework.web.server.ServerWebExchange @@ -29,7 +29,7 @@ import reactor.util.context.Context open class LoggingWebFilter : WebFilter { override fun filter(serverWebExchange: ServerWebExchange, webFilterChain: WebFilterChain): Mono<Void> { - val loggingService = LoggingService() + val loggingService = RestLoggerService() loggingService.entering(serverWebExchange.request) val filterChain = webFilterChain.filter(serverWebExchange).subscriberContext( Context.of(MDCContext, MDCContext())) |