adevinta / zoe

The Kafka CLI for humans
https://adevinta.github.io/zoe
MIT License
287 stars 21 forks source link

It doesn't work for me #2

Closed octavz closed 4 years ago

octavz commented 4 years ago

Hi, Seems like a nice tool but it has really bad configuration, and basically no defaults. I spent 10-20 mins trying to make this work to no avail.

I understand that your needs included having runners, I am using Kafka for years and I never felt the need to have this option, if you want to make it friendlier split the config in 2, one with basic things like kafka hosts and if you must the ser/de and move the runners part somewhere else, most people will only need to run it locally.

Even more having a switch zoe -h mykafka:9092 overriding any configuration, would make it even more usable, in my setup I sometimes run multiple kafka (integration tests) on the same machine, attached to random ports, it would be impossible for me to edit a configuration each time I want to see if my tests created the proper topics.

See my crash below.

My config:

---
runners:
  default: "local"
  config:
    lambda:
      deploy: null
      credentials:
        type: "default"
      awsRegion: null
      enabled: false
    kubernetes:
      namespace: "default"
      context: null
      deletePodAfterCompletion: true
      cpu: "1"
      memory: "512M"
      timeoutMs: 300000
      image:
        registry: "docker.io"
        image: "adevinta/zoe-core"
        tag: null
    local:
      enabled: true
storage: null
secrets: null
expressions: {}
clusters:
  default:
    props:
      bootstrap.servers: "xxx:9092"
      key.deserializer: "org.apache.kafka.common.serialization.StringDeserializer"
      value.deserializer: "org.apache.kafka.common.serialization.StringDeserializer"
      key.serializer: "org.apache.kafka.common.serialization.StringSerializer"
      value.serializer: "org.apache.kafka.common.serialization.ByteArraySerializer"
    groups: {}

Running:

 zoe topics list

leads to

loading config from url : file:/home/xxx/.zoe/config/default.yml
2020-06-19 17:34:29 INFO zoe: requesting topics...
failure: runner 'local' failed 
cause:
  failure: Instantiation of [simple type, class com.adevinta.oss.zoe.core.functions.CreateTopicRequest] value failed for JSON property name due to missing (therefore NULL) value for creator parameter name which is a non-nullable type
   at [Source: (byte[])"{"props":{"bootstrap.servers":"xxx:9092","key.deserializer":"org.apache.kafka.common.serialization.StringDeserializer","value.deserializer":"org.apache.kafka.common.serialization.StringDeserializer","key.serializer":"org.apache.kafka.common.serialization.StringSerializer","value.serializer":"org.apache.kafka.common.serialization.ByteArraySerializer"}}"; line: 1, column: 379] (through reference chain: com.adevinta.oss.zoe.core.functions.CreateTopicRequest["name"])

Thank you

wlezzar commented 4 years ago

Hi! And thanks for raising the issue!

You are stumbling into a regression that has already been fixed: https://github.com/adevinta/zoe/issues/1

Can you update zoe to the last version and try again?

octavz commented 4 years ago

Hi, ty for answering, with the latest version works, apart from the bug the rest of the stuff is still nice to have or even required for me.

wlezzar commented 4 years ago

Thanks a lot @octavz for the feedback. We will soon make it available to override any configuration from the command call :+1: