Make get_metadata(Topic) return only topic metadata

This commit is contained in:
Matias Fontanini
2016-06-18 08:45:33 -07:00
parent 84d98b38e5
commit a3b311fe00
6 changed files with 22 additions and 6 deletions

View File

@@ -37,7 +37,6 @@
#include <mutex>
#include <tuple>
#include <librdkafka/rdkafka.h>
#include "metadata.h"
#include "topic_partition.h"
#include "topic_partition_list.h"
#include "topic_configuration.h"
@@ -46,6 +45,8 @@
namespace cppkafka {
class Topic;
class Metadata;
class TopicMetadata;
/**
* Base class for kafka consumer/producer
@@ -137,7 +138,7 @@ public:
*
* \param topic The topic to fetch information for
*/
Metadata get_metadata(const Topic& topic) const;
TopicMetadata get_metadata(const Topic& topic) const;
/**
* Returns the kafka handle name

View File

@@ -89,6 +89,11 @@ public:
*/
std::string get_error_string() const;
/**
* Utility function to check for get_error() == RD_KAFKA_RESP_ERR__PARTITION_EOF
*/
bool is_eof() const;
/**
* Gets the topic that this message belongs to
*/