aboutsummaryrefslogtreecommitdiffstats
path: root/policy-endpoints/src/main/java/org/onap/policy/common/endpoints/event/comm/bus/internal/BusTopicBase.java
diff options
context:
space:
mode:
Diffstat (limited to 'policy-endpoints/src/main/java/org/onap/policy/common/endpoints/event/comm/bus/internal/BusTopicBase.java')
-rw-r--r--policy-endpoints/src/main/java/org/onap/policy/common/endpoints/event/comm/bus/internal/BusTopicBase.java48
1 files changed, 15 insertions, 33 deletions
diff --git a/policy-endpoints/src/main/java/org/onap/policy/common/endpoints/event/comm/bus/internal/BusTopicBase.java b/policy-endpoints/src/main/java/org/onap/policy/common/endpoints/event/comm/bus/internal/BusTopicBase.java
index ccf25753..f8236d3d 100644
--- a/policy-endpoints/src/main/java/org/onap/policy/common/endpoints/event/comm/bus/internal/BusTopicBase.java
+++ b/policy-endpoints/src/main/java/org/onap/policy/common/endpoints/event/comm/bus/internal/BusTopicBase.java
@@ -2,14 +2,15 @@
* ============LICENSE_START=======================================================
* ONAP
* ================================================================================
- * Copyright (C) 2017-2019 AT&T Intellectual Property. All rights reserved.
+ * Copyright (C) 2017-2019, 2021 AT&T Intellectual Property. All rights reserved.
+ * Modifications Copyright (C) 2020 Bell Canada. All rights reserved.
* ================================================================================
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
- *
+ *
* http://www.apache.org/licenses/LICENSE-2.0
- *
+ *
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
@@ -20,11 +21,13 @@
package org.onap.policy.common.endpoints.event.comm.bus.internal;
+import lombok.Getter;
import org.onap.policy.common.endpoints.event.comm.bus.ApiKeyEnabled;
/**
* Bus Topic Base.
*/
+@Getter
public abstract class BusTopicBase extends TopicBase implements ApiKeyEnabled {
/**
@@ -43,58 +46,37 @@ public abstract class BusTopicBase extends TopicBase implements ApiKeyEnabled {
protected boolean useHttps;
/**
+ * Allow tracing.
+ */
+ protected boolean allowTracing;
+
+ /**
* allow self signed certificates.
*/
protected boolean allowSelfSignedCerts;
/**
* Instantiates a new Bus Topic Base.
- *
+ *
* <p>servers list of servers
* topic topic name
* apiKey API Key
* apiSecret API Secret
* useHttps does connection use HTTPS?
+ * allowTracing Is tracing allowed?
* allowSelfSignedCerts are self-signed certificates allow
* @param busTopicParams holds all our parameters
* @throws IllegalArgumentException if invalid parameters are present
*/
- public BusTopicBase(BusTopicParams busTopicParams) {
+ protected BusTopicBase(BusTopicParams busTopicParams) {
super(busTopicParams.getServers(), busTopicParams.getTopic(), busTopicParams.getEffectiveTopic());
this.apiKey = busTopicParams.getApiKey();
this.apiSecret = busTopicParams.getApiSecret();
this.useHttps = busTopicParams.isUseHttps();
+ this.allowTracing = busTopicParams.isAllowTracing();
this.allowSelfSignedCerts = busTopicParams.isAllowSelfSignedCerts();
}
- @Override
- public String getApiKey() {
- return apiKey;
- }
-
- @Override
- public String getApiSecret() {
- return apiSecret;
- }
-
- /**
- * Is using HTTPS.
- *
- * @return if using https
- */
- public boolean isUseHttps() {
- return useHttps;
- }
-
- /**
- * Is self signed certificates allowed.
- *
- * @return if self signed certificates are allowed
- */
- public boolean isAllowSelfSignedCerts() {
- return allowSelfSignedCerts;
- }
-
protected boolean anyNullOrEmpty(String... args) {
for (String arg : args) {
if (arg == null || arg.isEmpty()) {