Confluent Kafka library for Robot Framework
Project description
Robot Framework - ConfluentKafkaLibrary
ConfluentKafkaLibrary library is a wrapper for the confluent-kafka-python.
ConfluentKafkaLibrary is compatible with the latest version of confluent-kafka-python, where the library versions have a 1:1 correspondence (e.g., ConfluentKafkaLibrary 2.9.0 corresponds to confluent-kafka-python 2.9.0). Bug fixes and updates are denoted by a post-release identifier, such as 2.9.0.post1.
Documentation
The keyword documentation for ConfluentKafkaLibrary can be found here
To generate the documentation, use the following command:
python -m robot.libdoc -f html src/ConfluentKafkaLibrary docs/index.html
Installation
To install the library, run the following command:
pip install robotframework-confluentkafkalibrary
Extra packages:
-
[avro]=['fastavro >= 1.3.2', 'avro >= 1.11.1'] -
[json]=['jsonschema >= 3.2.0', 'pyrsistent >= 0.20.0'] -
[protobuf]=['protobuf >= 4.22.0', 'googleapis-common-protos >= 1.66.0'] -
[schemaregistry]=['httpx>=0.26', 'cachetools >= 5.5.0', 'attrs >= 24.3.0'] -
To install all dependencies use
[all]extension like:
pip install robotframework-confluentkafkalibrary[all]
Usage
In most cases, you can refer to the confluent-kafka-python documentation for guidance. Every keyword in ConfluentKafkaLibrary is designed to match the corresponding Python functions. If you are unsure about the pre-configured keywords, please visit the robotframework-ConfluentKafkaLibrary documentation. The Kafka team maintains the up-to-date documentation for configuration properties and their values here.
- You can find basic usage examples in the ./examples/test.robot
- For more complex examples, such as handling byte data from a topic, using multiple consumers, or running threaded avro consumers, please refer to the documentation.
Testing
- The library is tested using black-box tests written in Robot Framework.
- You can find the test files in the examples/ directory directory.
- For testing, a dockerized enterprise Kafka platform with schema registry support and REST proxy is used. The platform is deployed and tested for each pull request and merge to the master branch.
- See docker-compose.yml file with the necessary configuration.
- Tests are divided into the following files:
- test.robot - Basic tests to verify functionality of the Consumer and Producer.
- test_adminclient.robot - Verifications of admin client functionality.
- test_avro.robot - Verifications of avro and serializers functionality.
- Not executable example of oauth usage can be found here
- Update of deployment https://github.com/robooo/robotframework-ConfluentKafkaLibrary/issues/21 is required.
- The core testing logic involves producing data to Kafka, connecting one consumer in a thread, and working with the results in specific test cases.
Known Limitations:
- Unable to install robotframework-confluentkafkalibrary on Amazon EC2 graviton instance type
- see the steps to resolve
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file robotframework_confluentkafkalibrary-2.12.2.post1.tar.gz.
File metadata
- Download URL: robotframework_confluentkafkalibrary-2.12.2.post1.tar.gz
- Upload date:
- Size: 17.2 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.1.0 CPython/3.13.7
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
e8fbfe8951afc47f6a72b97624afb47eeaedb78f26636d72bd46ede658bdf1f2
|
|
| MD5 |
4086dba9ba506d268dc71f648821aec8
|
|
| BLAKE2b-256 |
d84f7c728bf12a9e16776eca13136f9ad85487d971014644c4460ea8eda6b068
|
File details
Details for the file robotframework_confluentkafkalibrary-2.12.2.post1-py3-none-any.whl.
File metadata
- Download URL: robotframework_confluentkafkalibrary-2.12.2.post1-py3-none-any.whl
- Upload date:
- Size: 17.8 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.1.0 CPython/3.13.7
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
6ea7a6d147ea37497ad9b443d0a3ee0b3efa5fb876931a029bf962fde2225918
|
|
| MD5 |
1b645c931f965c9622b0c9e9c0d1eb7f
|
|
| BLAKE2b-256 |
3d05992012d682f83db574b631be087ae8469557835da7632667f8b502764bf8
|