Class Library
Methods that relate to the native librdkafka library itself (do not require a Producer or Consumer broker connection).
Inherited Members
Namespace: Confluent.Kafka
Assembly: Confluent.Kafka.dll
Syntax
public static class Library
Properties
DebugContexts
Gets a list of the supported debug contexts.
Declaration
public static string[] DebugContexts { get; }
Property Value
Type | Description |
---|---|
string[] |
HandleCount
The total number librdkafka client instances that have been created and not yet disposed.
Declaration
public static int HandleCount { get; }
Property Value
Type | Description |
---|---|
int |
IsLoaded
true if librdkafka has been successfully loaded, false if not.
Declaration
public static bool IsLoaded { get; }
Property Value
Type | Description |
---|---|
bool |
Version
Gets the librdkafka version as an integer.
Interpreted as hex MM.mm.rr.xx: - MM = Major - mm = minor - rr = revision - xx = pre-release id (0xff is the final release)
E.g.: 0x000901ff = 0.9.1
Declaration
public static int Version { get; }
Property Value
Type | Description |
---|---|
int |
VersionString
Gets the librdkafka version as string.
Declaration
public static string VersionString { get; }
Property Value
Type | Description |
---|---|
string |
Methods
Load()
Loads the native librdkafka library. Does nothing if the library is already loaded.
Declaration
public static bool Load()
Returns
Type | Description |
---|---|
bool | true if librdkafka was loaded as a result of this call, false if the library has already been loaded. |
Remarks
You will not typically need to call this method - librdkafka is loaded automatically on first use of a Producer or Consumer instance.
Load(string)
Loads the native librdkafka library from the specified path (note: the specified path needs to include the filename). Does nothing if the library is already loaded.
Declaration
public static bool Load(string path)
Parameters
Type | Name | Description |
---|---|---|
string | path |
Returns
Type | Description |
---|---|
bool | true if librdkafka was loaded as a result of this call, false if the library has already been loaded. |
Remarks
You will not typically need to call this method - librdkafka is loaded automatically on first use of a Producer or Consumer instance.