Skip to content
This repository has been archived by the owner on May 11, 2021. It is now read-only.

Configuration

Miłosz Rembisz edited this page Jun 13, 2017 · 17 revisions

Library can be configured in multiple ways, compatible with Spring Boot, i.e. you can use .properties, .yaml and JVM options. Below you will find exhaustive list of configuration options recognized by this library:

Property Description Default value
graphite.format Protocol/format used when publishing to Graphite, available options: UDP, TCP, PICKLE TCP
graphite.port Graphite listening port, used for publishing metrics 2003
graphite.publishing.enabled Publish metrics to Graphite true
graphite.publishing.interval Interval (in milliseconds) when metrics are published 15000
hystrix.stream-servlet.path Path to streaming servlet, publish Hystrix statistics /health/hystrix.stream
metrics.jvm.enabled Enable JVM metrics true
metrics.jvm.path.base JVM metrics path base jvm
metrics.path.app Application name, as used in Graphite to construct metric path (e.g.: apps.prod.pl.service-name.node... and custom metric names follow) service-name
metrics.path.country Country name, see above pl
metrics.path.environment Environment (production, test, etc.), see above test
metrics.path.node Node name, see above InetAddress.localHost.hostName
metrics.path.root Root path name for Graphite, see above apps
microservice.config.file Location of microservice descriptor, see: micro-deps classpath:microservice.json
microservice.host Host name of this microservice's server discovered automatically
microservice.port TCP/IP port to run microservice, you can also use port system property or server.port environment variable 8080
request.payload.logging.maxlength How many of each client request to log, currently disabled 2000
rest.api.contact E-mail address as shown in Swagger info@4finance.com
rest.api.description Description as shown in Swagger APIs for this microservice
rest.api.license.type License of this microservie as shown in Swagger 4finance internal licence
rest.api.license.url License URL as shown in Swagger http://4finance.com
rest.api.terms API terms as shown in Swagger Defined by 4finance internal licences
rest.api.title Your microservice title as shown in Swagger Microservice API
rest.api.urls.to.list Pattern selecting which operations to include in Swagger .*
rest.api.version Your API version as shown in Swagger 1.0
rest.client.connectionTimeout Connection timeout (in milliseconds) of all REST client calls, negative means no timeout -1
rest.client.maxLogResponseChars Maximum number of characters of each REST client response to log. 0 will skip logging altogether 4096
rest.client.responseErrorMessageLoggingLevel Level of message logged by RethrowingResponseErrorHandler on error response, available options: NONE, WARN, ERROR ERROR
rest.client.readTimeout Timeout (in milliseconds) to wait for response, negative means no timeout -1
rest.correlationId.skipPattern Triggering some requests (e.g. static resources) should not generate new correlation ID `/api-docs.*
rest.client.retry.threads How many threads to use when asynchronously retrying REST calls 10
service.resolver.connection.retry.baseSleepMs Initial amount of milliseconds to wait between retries 50
service.resolver.connection.retry.maxRetries Max number of retries 20
service.resolver.connection.retry.maxSleepMs Max amount of milliseconds to wait between retries 500
service.resolver.url Address to ZooKeeper, where microservice will be registered, ignored if com.ofg.infrastructure.discovery.ZookeeperConnectorConditions are not met localhost:2181
stubrunner.port.range.max Maximum port number where library will register stubs for each microservice, one port per stub 15000
stubrunner.port.range.min Minimum port number, see above 10000
stubrunner.skip-local-repo Stub runner should always re-download stub definitions, rather than reusing local copy true
stubrunner.stubs.group Maven group where stub definitions of this microservice are located com.ofg
stubrunner.stubs.module Maven artifact, see above stub-definitions
stubrunner.stubs.repository.root Maven repository where collaborator's stubs are published http://nexus.4finance.net/content/repositories/Pipeline
stubrunner.use-microservice-definitions Use the new approach with Accurest true
stubrunner.work-offline forces offline work false
zookeeper.standalone.enabled Use standalone ZooKeeper, no matter what profile is used false