diff options
Diffstat (limited to 'cps-service/src/main/java/org/onap/cps/notification/NotificationProperties.java')
-rw-r--r-- | cps-service/src/main/java/org/onap/cps/notification/NotificationProperties.java | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/cps-service/src/main/java/org/onap/cps/notification/NotificationProperties.java b/cps-service/src/main/java/org/onap/cps/notification/NotificationProperties.java index eb75e3f75..3776a93d9 100644 --- a/cps-service/src/main/java/org/onap/cps/notification/NotificationProperties.java +++ b/cps-service/src/main/java/org/onap/cps/notification/NotificationProperties.java @@ -23,6 +23,7 @@ import java.util.Collections; import java.util.Map; import javax.validation.constraints.NotNull; import lombok.Data; +import org.springframework.beans.factory.annotation.Value; import org.springframework.boot.context.properties.ConfigurationProperties; import org.springframework.stereotype.Component; import org.springframework.validation.annotation.Validated; @@ -36,6 +37,7 @@ public class NotificationProperties { @NotNull private String topic; private Map<String, String> filters = Collections.emptyMap(); - @NotNull - private boolean enabled = false; + + @Value("${notification.enabled:true}") + private boolean enabled; } |