From 7e5b3d9d558be5c160c767bad6b76ed550bbc4a2 Mon Sep 17 00:00:00 2001 From: ase-101 Date: Thu, 3 Oct 2024 18:19:31 +0530 Subject: [PATCH] moved tomcat and prometheus configuration to bootstrap.properties Signed-off-by: ase-101 --- .../resources/application-default.properties | 16 -------------- .../src/main/resources/bootstrap.properties | 22 ++++++++++++++----- 2 files changed, 17 insertions(+), 21 deletions(-) diff --git a/mock-identity-system/src/main/resources/application-default.properties b/mock-identity-system/src/main/resources/application-default.properties index 5c6f3c5b..25080536 100644 --- a/mock-identity-system/src/main/resources/application-default.properties +++ b/mock-identity-system/src/main/resources/application-default.properties @@ -25,22 +25,6 @@ # mosip.api.internal.url # mosip.api.public.url -## Tomcat access logs -server.tomcat.accesslog.enabled=true -server.tomcat.accesslog.directory=/dev -server.tomcat.accesslog.prefix=stdout -server.tomcat.accesslog.buffered=false -server.tomcat.accesslog.suffix= -server.tomcat.accesslog.file-date-format= -server.tomcat.accesslog.pattern={"@timestamp":"%{yyyy-MM-dd'T'HH:mm:ss.SSS'Z'}t","level":"ACCESS","level_value":70000,"traceId":"%{X-B3-TraceId}i","statusCode":%s,"req.requestURI":"%U","bytesSent":%b,"timeTaken":%T,"appName":"${spring.application.name}","req.userAgent":"%{User-Agent}i","req.xForwardedFor":"%{X-Forwarded-For}i","req.referer":"%{Referer}i","req.method":"%m","req.remoteHost":"%a"} -server.tomcat.accesslog.className=io.mosip.kernel.core.logger.config.SleuthValve - -## Prometheus -management.endpoint.metrics.enabled=true -management.endpoints.web.exposure.include=* -management.endpoint.prometheus.enabled=true -management.metrics.export.prometheus.enabled=true - ##----------------------------------------- Database properties -------------------------------------------------------- mosip.mockidentitysystem.database.hostname=${database.host} mosip.mockidentitysystem.database.port=${database.port} diff --git a/mock-identity-system/src/main/resources/bootstrap.properties b/mock-identity-system/src/main/resources/bootstrap.properties index 0255d6e1..cc80ac20 100644 --- a/mock-identity-system/src/main/resources/bootstrap.properties +++ b/mock-identity-system/src/main/resources/bootstrap.properties @@ -12,10 +12,6 @@ health.config.enabled=false server.servlet.context-path=/v1/mock-identity-system management.security.enable=false management.endpoint.health.show-details=always -management.endpoints.web.exposure.include=info,health,refresh,mappings -management.endpoint.metrics.enabled=true -management.endpoint.prometheus.enabled=true -management.metrics.export.prometheus.enabled=true openapi.info.title=${spring.application.name} openapi.info.description=${spring.application.name} @@ -29,4 +25,20 @@ openapi.group.name=${openapi.info.title} openapi.group.paths[0]=/** springdoc.swagger-ui.disable-swagger-default-url=true springdoc.swagger-ui.tagsSorter=alpha -springdoc.swagger-ui.operationsSorter=alpha \ No newline at end of file +springdoc.swagger-ui.operationsSorter=alpha + +## Tomcat access logs +server.tomcat.accesslog.enabled=true +server.tomcat.accesslog.directory=/dev +server.tomcat.accesslog.prefix=stdout +server.tomcat.accesslog.buffered=false +server.tomcat.accesslog.suffix= +server.tomcat.accesslog.file-date-format= +server.tomcat.accesslog.pattern={"@timestamp":"%{yyyy-MM-dd'T'HH:mm:ss.SSS'Z'}t","level":"ACCESS","level_value":70000,"traceId":"%{X-B3-TraceId}i","statusCode":%s,"req.requestURI":"%U","bytesSent":%b,"timeTaken":%T,"appName":"${spring.application.name}","req.userAgent":"%{User-Agent}i","req.xForwardedFor":"%{X-Forwarded-For}i","req.referer":"%{Referer}i","req.method":"%m","req.remoteHost":"%a"} +server.tomcat.accesslog.className=io.mosip.kernel.core.logger.config.SleuthValve + +## Prometheus +management.endpoint.metrics.enabled=true +management.endpoints.web.exposure.include=* +management.endpoint.prometheus.enabled=true +management.metrics.export.prometheus.enabled=true \ No newline at end of file