X-Git-Url: https://gerrit.onap.org/r/gitweb?a=blobdiff_plain;f=sources%2Fhv-collector-configuration%2Fsrc%2Fmain%2Fkotlin%2Forg%2Fonap%2Fdcae%2Fcollectors%2Fveshv%2Fconfig%2Fimpl%2FCbsConfigurationProvider.kt;h=8e774f9d360228e87d7d8ce02b451bde0522c5b1;hb=ae4dcd511e70bd95222c504771fa184d993b5bba;hp=6f16b3d1b4f0475eb9f4c959e2f7a3ffee6fe550;hpb=b98ad1204d2e3613bfb0648dd7b8ab865752b963;p=dcaegen2%2Fcollectors%2Fhv-ves.git diff --git a/sources/hv-collector-configuration/src/main/kotlin/org/onap/dcae/collectors/veshv/config/impl/CbsConfigurationProvider.kt b/sources/hv-collector-configuration/src/main/kotlin/org/onap/dcae/collectors/veshv/config/impl/CbsConfigurationProvider.kt index 6f16b3d1..8e774f9d 100644 --- a/sources/hv-collector-configuration/src/main/kotlin/org/onap/dcae/collectors/veshv/config/impl/CbsConfigurationProvider.kt +++ b/sources/hv-collector-configuration/src/main/kotlin/org/onap/dcae/collectors/veshv/config/impl/CbsConfigurationProvider.kt @@ -2,7 +2,7 @@ * ============LICENSE_START======================================================= * dcaegen2-collectors-veshv * ================================================================================ - * Copyright (C) 2018-2019 NOKIA + * Copyright (C) 2018-2020 NOKIA * ================================================================================ * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. @@ -34,6 +34,7 @@ import org.onap.dcaegen2.services.sdk.rest.services.cbs.client.api.streams.Strea import org.onap.dcaegen2.services.sdk.rest.services.cbs.client.api.streams.StreamPredicates.streamOfType import reactor.core.publisher.Flux import reactor.retry.Retry +import reactor.util.retry.Retry.withThrowable /** * @author Jakub Dudycz @@ -60,7 +61,7 @@ internal class CbsConfigurationProvider(private val cbsClientAdapter: CbsClientA .map(::parseConfiguration) .doOnNext { logger.info(mdc) { "Successfully parsed configuration json to:\n$it" } } .onErrorLog(logger, mdc) { "Error while creating configuration" } - .retryWhen(retry) + .retryWhen(withThrowable(retry)) private fun parseConfiguration(json: JsonObject) = configParser