Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

kafka-benchmark does not build #8

Open
wpwoodjr opened this issue Dec 13, 2019 · 1 comment
Open

kafka-benchmark does not build #8

wpwoodjr opened this issue Dec 13, 2019 · 1 comment

Comments

@wpwoodjr
Copy link

Here is output:

error[E0599]: no method named `wait` found for type `rdkafka::consumer::MessageStream<'_, rdkafka::consumer::DefaultConsumerContext>` in the current scope
   --> src/consumer/mod.rs:120:37
    |
120 |     for message in consumer.start().wait() {
    |                                     ^^^^ method not found in `rdkafka::consumer::MessageStream<'_, rdkafka::consumer::DefaultConsumerContext>`
    |
    = note: the method `wait` exists but the following trait bounds were not satisfied:
            `&mut rdkafka::consumer::MessageStream<'_, rdkafka::consumer::DefaultConsumerContext> : futures::Stream`

error[E0599]: no method named `send_copy` found for type `rdkafka::producer::BaseProducer<producer::BenchmarkProducerContext>` in the current scope
  --> src/producer/mod.rs:55:10
   |
55 |         .send_copy::<str, str>(&scenario.topic, None, Some("warmup"), None, (), None)
   |          ^^^^^^^^^ method not found in `rdkafka::producer::BaseProducer<producer::BenchmarkProducerContext>`

error[E0599]: no method named `send_copy` found for type `rdkafka::producer::BaseProducer<producer::BenchmarkProducerContext>` in the current scope
  --> src/producer/mod.rs:68:28
   |
68 |             match producer.send_copy::<[u8], [u8]>(
   |                            ^^^^^^^^^ method not found in `rdkafka::producer::BaseProducer<producer::BenchmarkProducerContext>`

error[E0599]: no method named `wait` found for type `rdkafka::producer::DeliveryFuture` in the current scope
  --> src/producer/mod.rs:96:22
   |
96 |         match future.wait() {
   |                      ^^^^ method not found in `rdkafka::producer::DeliveryFuture`
   |
   = note: the method `wait` exists but the following trait bounds were not satisfied:
           `&mut rdkafka::producer::DeliveryFuture : futures::Future`

error[E0599]: no method named `send_copy` found for type `rdkafka::producer::FutureProducer` in the current scope
   --> src/producer/mod.rs:119:10
    |
119 |         .send_copy::<str, str>(&scenario.topic, None, Some("warmup"), None, None, 1000)
    |          ^^^^^^^^^ method not found in `rdkafka::producer::FutureProducer`

error[E0599]: no method named `send_copy` found for type `rdkafka::producer::FutureProducer` in the current scope
   --> src/producer/mod.rs:131:31
    |
131 |         futures.push(producer.send_copy::<[u8], [u8]>(
    |                               ^^^^^^^^^ method not found in `rdkafka::producer::FutureProducer`

warning: unused import: `futures::Stream`
 --> src/consumer/mod.rs:4:5
  |
4 | use futures::Stream;
  |     ^^^^^^^^^^^^^^^
  |
  = note: `#[warn(unused_imports)]` on by default

warning: unused import: `Future`
 --> src/producer/mod.rs:1:21
  |
1 | use futures::{self, Future};
  |                     ^^^^^^

error: aborting due to 6 previous errors

For more information about this error, try `rustc --explain E0599`.
error: failed to compile `kafka-benchmark v0.2.0 (/mnt/c/Users/woodb000/OneDrive - GSK/projects/strimzi-kafka/kafka-benchmark)`, intermediate artifacts can be found at `/mnt/c/Users/woodb000/OneDrive - GSK/projects/strimzi-kafka/kafka-benchmark/target`

Caused by:
  could not compile `kafka-benchmark`.

To learn more, run the command again with --verbose.
@Arfey
Copy link

Arfey commented May 26, 2020

now rdkafka use a new async/.await syntax. If u wanna run benchmark u need to pinned version in Cargo.toml file to:

rdkafka = "~0.21"
rdkafka-sys = "1.0"

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants