From 4c1c6891ed6cd4a9e5c2e0b3bacd0c2df89364a7 Mon Sep 17 00:00:00 2001 From: Jorge Hernandez Date: Tue, 19 Feb 2019 20:05:31 -0600 Subject: Support for lab contextual topic names. This work allows a drools application, with its drl template to refer to the topic name by its invariable canonical name, ie. POLICY-CL-MGT. Since the drl is a design time artifact, it is desired to know topics by its canonical non-changeable name. The actual per lab environment topic name may change on a per deployment basis, for example POLICY-CL-MGT-WINDRIVER or POLICY-CL-MGT-TLAB. The template can still use POLICY-CL-MGT without modification but the actual installation configuration would use the "effectiveTopic" property to point to the right topic on a per lab basis. This also helps with installation (long story) since the canonical topics will be known ahead of time. Change-Id: I8322bf7e427569c37a76eea5ce6d5b9547cb2ff3 Issue-ID: POLICY-1534 Signed-off-by: Jorge Hernandez --- .../policy/common/endpoints/event/comm/Topic.java | 25 ++++++++---- .../comm/bus/IndexedDmaapTopicSinkFactory.java | 6 ++- .../comm/bus/IndexedDmaapTopicSourceFactory.java | 9 +++-- .../event/comm/bus/IndexedUebTopicSinkFactory.java | 7 +++- .../comm/bus/IndexedUebTopicSourceFactory.java | 8 +++- .../event/comm/bus/internal/BusTopicBase.java | 6 +-- .../event/comm/bus/internal/BusTopicParams.java | 12 +++++- .../comm/bus/internal/InlineDmaapTopicSink.java | 8 ++-- .../comm/bus/internal/InlineUebTopicSink.java | 6 +-- .../internal/SingleThreadedDmaapTopicSource.java | 6 +-- .../bus/internal/SingleThreadedUebTopicSource.java | 7 ++-- .../event/comm/bus/internal/TopicBase.java | 45 +++++++++++++++++++--- 12 files changed, 106 insertions(+), 39 deletions(-) (limited to 'policy-endpoints/src/main/java/org/onap/policy/common/endpoints/event/comm') diff --git a/policy-endpoints/src/main/java/org/onap/policy/common/endpoints/event/comm/Topic.java b/policy-endpoints/src/main/java/org/onap/policy/common/endpoints/event/comm/Topic.java index 800fcce4..96c00c77 100644 --- a/policy-endpoints/src/main/java/org/onap/policy/common/endpoints/event/comm/Topic.java +++ b/policy-endpoints/src/main/java/org/onap/policy/common/endpoints/event/comm/Topic.java @@ -1,8 +1,8 @@ /*- * ============LICENSE_START======================================================= - * policy-endpoints + * ONAP * ================================================================================ - * Copyright (C) 2017-2018 AT&T Intellectual Property. All rights reserved. + * Copyright (C) 2017-2019 AT&T Intellectual Property. All rights reserved. * Modifications Copyright (C) 2019 Samsung Electronics Co., Ltd. * ================================================================================ * Licensed under the Apache License, Version 2.0 (the "License"); @@ -35,7 +35,7 @@ public interface Topic extends TopicRegisterable, Startable, Lockable { /** * Underlying Communication infrastructure Types. */ - public enum CommInfrastructure { + enum CommInfrastructure { /** * UEB Communication Infrastructure. */ @@ -55,31 +55,40 @@ public interface Topic extends TopicRegisterable, Startable, Lockable { } /** - * Gets the topic name. + * Gets the canonical topic name. * * @return topic name */ - public String getTopic(); + String getTopic(); + + /** + * Gets the effective topic that is used in + * the network communication. This name is usually + * the topic name. + * + * @return topic name alias + */ + String getEffectiveTopic(); /** * Gets the communication infrastructure type. * * @return CommInfrastructure object */ - public CommInfrastructure getTopicCommInfrastructure(); + CommInfrastructure getTopicCommInfrastructure(); /** * Return list of servers. * * @return bus servers */ - public List getServers(); + List getServers(); /** * Get the more recent events in this topic entity. * * @return list of most recent events */ - public String[] getRecentEvents(); + String[] getRecentEvents(); } diff --git a/policy-endpoints/src/main/java/org/onap/policy/common/endpoints/event/comm/bus/IndexedDmaapTopicSinkFactory.java b/policy-endpoints/src/main/java/org/onap/policy/common/endpoints/event/comm/bus/IndexedDmaapTopicSinkFactory.java index 659833ce..4ccf08de 100644 --- a/policy-endpoints/src/main/java/org/onap/policy/common/endpoints/event/comm/bus/IndexedDmaapTopicSinkFactory.java +++ b/policy-endpoints/src/main/java/org/onap/policy/common/endpoints/event/comm/bus/IndexedDmaapTopicSinkFactory.java @@ -1,6 +1,6 @@ /* * ============LICENSE_START======================================================= - * ONAP Policy Engine - Common Modules + * ONAP * ================================================================================ * Copyright (C) 2017-2019 AT&T Intellectual Property. All rights reserved. * ================================================================================ @@ -109,6 +109,9 @@ class IndexedDmaapTopicSinkFactory implements DmaapTopicSinkFactory { serverList = new ArrayList<>(); } + final String effectiveTopic = properties.getProperty(PolicyEndPointProperties.PROPERTY_DMAAP_SINK_TOPICS + + "." + topic + PolicyEndPointProperties.PROPERTY_TOPIC_EFFECTIVE_TOPIC_SUFFIX, topic); + final String apiKey = properties.getProperty(PolicyEndPointProperties.PROPERTY_DMAAP_SINK_TOPICS + "." + topic + PolicyEndPointProperties.PROPERTY_TOPIC_API_KEY_SUFFIX); final String apiSecret = properties.getProperty(PolicyEndPointProperties.PROPERTY_DMAAP_SINK_TOPICS @@ -232,6 +235,7 @@ class IndexedDmaapTopicSinkFactory implements DmaapTopicSinkFactory { DmaapTopicSink dmaapTopicSink = this.build(BusTopicParams.builder() .servers(serverList) .topic(topic) + .effectiveTopic(effectiveTopic) .apiKey(apiKey) .apiSecret(apiSecret) .userName(aafMechId) diff --git a/policy-endpoints/src/main/java/org/onap/policy/common/endpoints/event/comm/bus/IndexedDmaapTopicSourceFactory.java b/policy-endpoints/src/main/java/org/onap/policy/common/endpoints/event/comm/bus/IndexedDmaapTopicSourceFactory.java index 0c008f11..ddc3321f 100644 --- a/policy-endpoints/src/main/java/org/onap/policy/common/endpoints/event/comm/bus/IndexedDmaapTopicSourceFactory.java +++ b/policy-endpoints/src/main/java/org/onap/policy/common/endpoints/event/comm/bus/IndexedDmaapTopicSourceFactory.java @@ -1,6 +1,6 @@ /* * ============LICENSE_START======================================================= - * ONAP Policy Engine - Common Modules + * ONAP * ================================================================================ * Copyright (C) 2017-2019 AT&T Intellectual Property. All rights reserved. * ================================================================================ @@ -99,6 +99,10 @@ class IndexedDmaapTopicSourceFactory implements DmaapTopicSourceFactory { serverList = new ArrayList<>(); } + final String effectiveTopic = properties.getProperty( + PolicyEndPointProperties.PROPERTY_DMAAP_SOURCE_TOPICS + "." + + topic + PolicyEndPointProperties.PROPERTY_TOPIC_EFFECTIVE_TOPIC_SUFFIX, topic); + final String apiKey = properties.getProperty( PolicyEndPointProperties.PROPERTY_DMAAP_SOURCE_TOPICS + "." + topic + PolicyEndPointProperties.PROPERTY_TOPIC_API_KEY_SUFFIX); @@ -201,9 +205,7 @@ class IndexedDmaapTopicSourceFactory implements DmaapTopicSourceFactory { dme2AdditionalProps.put(DME2_SESSION_STICKINESS_REQUIRED_PROPERTY, dme2SessionStickinessRequired); } - if (servers == null || servers.isEmpty()) { - logger.error("{}: no DMaaP servers or DME2 ServiceName provided", this); continue; } @@ -260,6 +262,7 @@ class IndexedDmaapTopicSourceFactory implements DmaapTopicSourceFactory { DmaapTopicSource uebTopicSource = this.build(BusTopicParams.builder() .servers(serverList) .topic(topic) + .effectiveTopic(effectiveTopic) .apiKey(apiKey) .apiSecret(apiSecret) .userName(aafMechId) diff --git a/policy-endpoints/src/main/java/org/onap/policy/common/endpoints/event/comm/bus/IndexedUebTopicSinkFactory.java b/policy-endpoints/src/main/java/org/onap/policy/common/endpoints/event/comm/bus/IndexedUebTopicSinkFactory.java index 5b3fc669..62437823 100644 --- a/policy-endpoints/src/main/java/org/onap/policy/common/endpoints/event/comm/bus/IndexedUebTopicSinkFactory.java +++ b/policy-endpoints/src/main/java/org/onap/policy/common/endpoints/event/comm/bus/IndexedUebTopicSinkFactory.java @@ -1,6 +1,6 @@ /* * ============LICENSE_START======================================================= - * ONAP Policy Engine - Common Modules + * ONAP * ================================================================================ * Copyright (C) 2017-2019 AT&T Intellectual Property. All rights reserved. * ================================================================================ @@ -114,7 +114,9 @@ class IndexedUebTopicSinkFactory implements UebTopicSinkFactory { final List serverList = new ArrayList<>(Arrays.asList(servers.split("\\s*,\\s*"))); - final String apiKey = properties.getProperty(PolicyEndPointProperties.PROPERTY_UEB_SINK_TOPICS + final String effectiveTopic = properties.getProperty(PolicyEndPointProperties.PROPERTY_UEB_SINK_TOPICS + + "." + topic + PolicyEndPointProperties.PROPERTY_TOPIC_EFFECTIVE_TOPIC_SUFFIX, topic); + final String apiKey = properties.getProperty(PolicyEndPointProperties.PROPERTY_UEB_SINK_TOPICS + "." + topic + PolicyEndPointProperties.PROPERTY_TOPIC_API_KEY_SUFFIX); final String apiSecret = properties.getProperty(PolicyEndPointProperties.PROPERTY_UEB_SINK_TOPICS + "." + topic + PolicyEndPointProperties.PROPERTY_TOPIC_API_SECRET_SUFFIX); @@ -151,6 +153,7 @@ class IndexedUebTopicSinkFactory implements UebTopicSinkFactory { UebTopicSink uebTopicWriter = this.build(BusTopicParams.builder() .servers(serverList) .topic(topic) + .effectiveTopic(effectiveTopic) .apiKey(apiKey) .apiSecret(apiSecret) .partitionId(partitionKey) diff --git a/policy-endpoints/src/main/java/org/onap/policy/common/endpoints/event/comm/bus/IndexedUebTopicSourceFactory.java b/policy-endpoints/src/main/java/org/onap/policy/common/endpoints/event/comm/bus/IndexedUebTopicSourceFactory.java index 88a472c2..f3ef8fdc 100644 --- a/policy-endpoints/src/main/java/org/onap/policy/common/endpoints/event/comm/bus/IndexedUebTopicSourceFactory.java +++ b/policy-endpoints/src/main/java/org/onap/policy/common/endpoints/event/comm/bus/IndexedUebTopicSourceFactory.java @@ -1,6 +1,6 @@ /* * ============LICENSE_START======================================================= - * ONAP Policy Engine - Common Modules + * ONAP * ================================================================================ * Copyright (C) 2017-2019 AT&T Intellectual Property. All rights reserved. * ================================================================================ @@ -101,7 +101,10 @@ class IndexedUebTopicSourceFactory implements UebTopicSourceFactory { final List serverList = new ArrayList<>(Arrays.asList(servers.split("\\s*,\\s*"))); - final String apiKey = properties.getProperty(PolicyEndPointProperties.PROPERTY_UEB_SOURCE_TOPICS + final String effectiveTopic = properties.getProperty(PolicyEndPointProperties.PROPERTY_UEB_SOURCE_TOPICS + + "." + topic + PolicyEndPointProperties.PROPERTY_TOPIC_EFFECTIVE_TOPIC_SUFFIX, topic); + + final String apiKey = properties.getProperty(PolicyEndPointProperties.PROPERTY_UEB_SOURCE_TOPICS + "." + topic + PolicyEndPointProperties.PROPERTY_TOPIC_API_KEY_SUFFIX); final String apiSecret = properties.getProperty(PolicyEndPointProperties.PROPERTY_UEB_SOURCE_TOPICS @@ -167,6 +170,7 @@ class IndexedUebTopicSourceFactory implements UebTopicSourceFactory { UebTopicSource uebTopicSource = this.build(BusTopicParams.builder() .servers(serverList) .topic(topic) + .effectiveTopic(effectiveTopic) .apiKey(apiKey) .apiSecret(apiSecret) .consumerGroup(consumerGroup) 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 3e4f48e7..ccf25753 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 @@ -1,8 +1,8 @@ /* * ============LICENSE_START======================================================= - * policy-endpoints + * ONAP * ================================================================================ - * Copyright (C) 2017-2018 AT&T Intellectual Property. All rights reserved. + * Copyright (C) 2017-2019 AT&T Intellectual Property. 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. @@ -60,7 +60,7 @@ public abstract class BusTopicBase extends TopicBase implements ApiKeyEnabled { * @throws IllegalArgumentException if invalid parameters are present */ public BusTopicBase(BusTopicParams busTopicParams) { - super(busTopicParams.getServers(), busTopicParams.getTopic()); + super(busTopicParams.getServers(), busTopicParams.getTopic(), busTopicParams.getEffectiveTopic()); this.apiKey = busTopicParams.getApiKey(); this.apiSecret = busTopicParams.getApiSecret(); this.useHttps = busTopicParams.isUseHttps(); diff --git a/policy-endpoints/src/main/java/org/onap/policy/common/endpoints/event/comm/bus/internal/BusTopicParams.java b/policy-endpoints/src/main/java/org/onap/policy/common/endpoints/event/comm/bus/internal/BusTopicParams.java index 6e3c2632..b9817abf 100644 --- a/policy-endpoints/src/main/java/org/onap/policy/common/endpoints/event/comm/bus/internal/BusTopicParams.java +++ b/policy-endpoints/src/main/java/org/onap/policy/common/endpoints/event/comm/bus/internal/BusTopicParams.java @@ -1,6 +1,6 @@ /* * ============LICENSE_START======================================================= - * policy-endpoints + * ONAP * ================================================================================ * Copyright (C) 2018 Samsung Electronics Co., Ltd. All rights reserved. * Modifications Copyright (C) 2018-2019 AT&T Intellectual Property. All rights reserved. @@ -51,6 +51,7 @@ public class BusTopicParams { private List servers; private Map additionalProps; private String topic; + private String effectiveTopic; private String apiKey; private String apiSecret; private String consumerGroup; @@ -122,6 +123,10 @@ public class BusTopicParams { return topic; } + public String getEffectiveTopic() { + return effectiveTopic; + } + public String getApiKey() { return apiKey; } @@ -276,6 +281,11 @@ public class BusTopicParams { return this; } + public TopicParamsBuilder effectiveTopic(String effectiveTopic) { + this.params.effectiveTopic = effectiveTopic; + return this; + } + public TopicParamsBuilder apiKey(String apiKey) { this.params.apiKey = apiKey; return this; diff --git a/policy-endpoints/src/main/java/org/onap/policy/common/endpoints/event/comm/bus/internal/InlineDmaapTopicSink.java b/policy-endpoints/src/main/java/org/onap/policy/common/endpoints/event/comm/bus/internal/InlineDmaapTopicSink.java index 01531055..ba556bb8 100644 --- a/policy-endpoints/src/main/java/org/onap/policy/common/endpoints/event/comm/bus/internal/InlineDmaapTopicSink.java +++ b/policy-endpoints/src/main/java/org/onap/policy/common/endpoints/event/comm/bus/internal/InlineDmaapTopicSink.java @@ -1,8 +1,8 @@ /*- * ============LICENSE_START======================================================= - * policy-endpoints + * ONAP * ================================================================================ - * Copyright (C) 2017-2018 AT&T Intellectual Property. All rights reserved. + * Copyright (C) 2017-2019 AT&T Intellectual Property. All rights reserved. * Modified Copyright (C) 2018 Samsung Electronics Co., Ltd. * ================================================================================ * Licensed under the Apache License, Version 2.0 (the "License"); @@ -87,7 +87,7 @@ public class InlineDmaapTopicSink extends InlineBusTopicSink implements DmaapTop if (allNullOrEmpty(this.environment, this.aftEnvironment, this.latitude, this.longitude, this.partner)) { this.publisher = new BusPublisher.CambriaPublisherWrapper(BusTopicParams.builder() .servers(this.servers) - .topic(this.topic) + .topic(this.effectiveTopic) .apiKey(this.apiKey) .apiSecret(this.apiSecret) .userName(this.userName) @@ -98,7 +98,7 @@ public class InlineDmaapTopicSink extends InlineBusTopicSink implements DmaapTop } else { this.publisher = new BusPublisher.DmaapDmePublisherWrapper(BusTopicParams.builder() .servers(this.servers) - .topic(this.topic) + .topic(this.effectiveTopic) .userName(this.userName) .password(this.password) .environment(this.environment) diff --git a/policy-endpoints/src/main/java/org/onap/policy/common/endpoints/event/comm/bus/internal/InlineUebTopicSink.java b/policy-endpoints/src/main/java/org/onap/policy/common/endpoints/event/comm/bus/internal/InlineUebTopicSink.java index f989f808..f258d5d9 100644 --- a/policy-endpoints/src/main/java/org/onap/policy/common/endpoints/event/comm/bus/internal/InlineUebTopicSink.java +++ b/policy-endpoints/src/main/java/org/onap/policy/common/endpoints/event/comm/bus/internal/InlineUebTopicSink.java @@ -1,8 +1,8 @@ /* * ============LICENSE_START======================================================= - * policy-endpoints + * ONAP * ================================================================================ - * Copyright (C) 2017-2018 AT&T Intellectual Property. All rights reserved. + * Copyright (C) 2017-2019 AT&T Intellectual Property. All rights reserved. * Modified Copyright (C) 2018 Samsung Electronics Co., Ltd. * ================================================================================ * Licensed under the Apache License, Version 2.0 (the "License"); @@ -63,7 +63,7 @@ public class InlineUebTopicSink extends InlineBusTopicSink implements UebTopicSi this.publisher = new BusPublisher.CambriaPublisherWrapper(BusTopicParams.builder() .servers(this.servers) - .topic(this.topic) + .topic(this.effectiveTopic) .apiKey(this.apiKey) .apiSecret(this.apiSecret) .useHttps(this.useHttps) diff --git a/policy-endpoints/src/main/java/org/onap/policy/common/endpoints/event/comm/bus/internal/SingleThreadedDmaapTopicSource.java b/policy-endpoints/src/main/java/org/onap/policy/common/endpoints/event/comm/bus/internal/SingleThreadedDmaapTopicSource.java index e4064c5d..e5d08a2a 100644 --- a/policy-endpoints/src/main/java/org/onap/policy/common/endpoints/event/comm/bus/internal/SingleThreadedDmaapTopicSource.java +++ b/policy-endpoints/src/main/java/org/onap/policy/common/endpoints/event/comm/bus/internal/SingleThreadedDmaapTopicSource.java @@ -1,8 +1,8 @@ /*- * ============LICENSE_START======================================================= - * policy-endpoints + * ONAP * ================================================================================ - * Copyright (C) 2017-2018 AT&T Intellectual Property. All rights reserved. + * Copyright (C) 2017-2019 AT&T Intellectual Property. All rights reserved. * Modifications Copyright (C) 2018-2019 Samsung Electronics Co., Ltd. * ================================================================================ * Licensed under the Apache License, Version 2.0 (the "License"); @@ -89,7 +89,7 @@ public class SingleThreadedDmaapTopicSource extends SingleThreadedBusTopicSource public void init() throws MalformedURLException { BusTopicParams.TopicParamsBuilder builder = BusTopicParams.builder() .servers(this.servers) - .topic(this.topic) + .topic(this.effectiveTopic) .apiKey(this.apiKey) .apiSecret(this.apiSecret) .consumerGroup(this.consumerGroup) diff --git a/policy-endpoints/src/main/java/org/onap/policy/common/endpoints/event/comm/bus/internal/SingleThreadedUebTopicSource.java b/policy-endpoints/src/main/java/org/onap/policy/common/endpoints/event/comm/bus/internal/SingleThreadedUebTopicSource.java index f6d4b531..e210762d 100644 --- a/policy-endpoints/src/main/java/org/onap/policy/common/endpoints/event/comm/bus/internal/SingleThreadedUebTopicSource.java +++ b/policy-endpoints/src/main/java/org/onap/policy/common/endpoints/event/comm/bus/internal/SingleThreadedUebTopicSource.java @@ -1,8 +1,8 @@ /* * ============LICENSE_START======================================================= - * policy-endpoints + * ONAP * ================================================================================ - * Copyright (C) 2017-2018 AT&T Intellectual Property. All rights reserved. + * Copyright (C) 2017-2019 AT&T Intellectual Property. All rights reserved. * Modifications Copyright (C) 2018-2019 Samsung Electronics Co., Ltd. * ================================================================================ * Licensed under the Apache License, Version 2.0 (the "License"); @@ -38,7 +38,6 @@ public class SingleThreadedUebTopicSource extends SingleThreadedBusTopicSource i */ public SingleThreadedUebTopicSource(BusTopicParams busTopicParams) { super(busTopicParams); - this.init(); } @@ -49,7 +48,7 @@ public class SingleThreadedUebTopicSource extends SingleThreadedBusTopicSource i public void init() { this.consumer = new BusConsumer.CambriaConsumerWrapper(BusTopicParams.builder() .servers(this.servers) - .topic(this.topic) + .topic(this.effectiveTopic) .apiKey(this.apiKey) .apiSecret(this.apiSecret) .consumerGroup(this.consumerGroup) diff --git a/policy-endpoints/src/main/java/org/onap/policy/common/endpoints/event/comm/bus/internal/TopicBase.java b/policy-endpoints/src/main/java/org/onap/policy/common/endpoints/event/comm/bus/internal/TopicBase.java index 80664554..6f07df1b 100644 --- a/policy-endpoints/src/main/java/org/onap/policy/common/endpoints/event/comm/bus/internal/TopicBase.java +++ b/policy-endpoints/src/main/java/org/onap/policy/common/endpoints/event/comm/bus/internal/TopicBase.java @@ -1,8 +1,8 @@ /* * ============LICENSE_START======================================================= - * policy-endpoints + * ONAP * ================================================================================ - * Copyright (C) 2017-2018 AT&T Intellectual Property. All rights reserved. + * Copyright (C) 2017-2019 AT&T Intellectual Property. 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. @@ -44,7 +44,12 @@ public abstract class TopicBase implements Topic { /** * Topic. */ - protected String topic; + protected final String topic; + + /** + * Topic Alias. + */ + protected final String effectiveTopic; /** * Event cache. @@ -78,6 +83,18 @@ public abstract class TopicBase implements Topic { * @throws IllegalArgumentException if invalid parameters are present */ public TopicBase(List servers, String topic) { + this(servers, topic, topic); + } + + /** + * Instantiates a new Topic Base. + * + * @param servers list of servers + * @param topic topic name + * + * @throws IllegalArgumentException if invalid parameters are present + */ + public TopicBase(List servers, String topic, String effectiveTopic) { if (servers == null || servers.isEmpty()) { throw new IllegalArgumentException("Server(s) must be provided"); @@ -87,8 +104,16 @@ public abstract class TopicBase implements Topic { throw new IllegalArgumentException("A Topic must be provided"); } + String effectiveTopicCopy; + if (effectiveTopic == null || effectiveTopic.isEmpty()) { + effectiveTopicCopy = topic; + } else { + effectiveTopicCopy = effectiveTopic; + } + this.servers = servers; this.topic = topic; + this.effectiveTopic = effectiveTopicCopy; } @Override @@ -203,6 +228,11 @@ public abstract class TopicBase implements Topic { return topic; } + @Override + public String getEffectiveTopic() { + return effectiveTopic; + } + @Override public boolean isAlive() { return this.alive; @@ -222,7 +252,12 @@ public abstract class TopicBase implements Topic { @Override public String toString() { - return "TopicBase [servers=" + servers + ", topic=" + topic + ", #recentEvents=" + recentEvents.size() - + ", locked=" + locked + ", #topicListeners=" + topicListeners.size() + "]"; + return "TopicBase [servers=" + servers + + ", topic=" + topic + + ", effectiveTopic=" + effectiveTopic + + ", #recentEvents=" + recentEvents.size() + + ", locked=" + locked + + ", #topicListeners=" + topicListeners.size() + + "]"; } } -- cgit 1.2.3-korg