docs: TopicData getTopicData(Topic topic, String topicName) {
          TopicData topicData = null;
  
          if (topic != null) {
              topicData = topic.getTopicData();
          }
  
          if (topicData == null) {
              topicData = topicDataCache.get(topicName);
              if (topic != null && topicData != null) {
                  topic.setTopicDataReference(topicData.getReference());
              }
          }
  
          if (topicData == null) {
              synchronized (this) {
                  topicData = buildTopicData(topicName);
                  if (topic != null) {
                      topic.setTopicDataReference(topicData.getReference());
                  }
              }
          }
  
          return topicData;
      }