iggy-rs / iggy-python-client

Official Python client SDK for Iggy.rs message streaming.
MIT License
15 stars 6 forks source link

The example doesn't work for last version of Iggy #2

Closed pikhovkin closed 8 months ago

darioalessandro commented 10 months ago

Hey @pikhovkin can you please add more details? logs/ways to reproduce it?

pikhovkin commented 10 months ago

Just run all the steps in the README for the image iggyrs/iggy:0.0.45 image and the current repository version.

Logs for producer

stream error {} InvalidResponse(40)
topic error {} InvalidResponse(40)
Messages will be sent to stream: 1, topic: 1, partition: 1 with interval 500.0 ms.
exception: {} InvalidResponse(40)
Sent 10 message(s).
exception: {} InvalidResponse(40)
Sent 10 message(s).
exception: {} InvalidResponse(40)
Sent 10 message(s).
exception: {} InvalidResponse(40)
Sent 10 message(s).
exception: {} InvalidResponse(40)
Sent 10 message(s).

Logs for consumer

Messages will be consumed from stream: 1, topic: 1, partition: 1 with interval 500.0 ms.
exception: {} IoError(Custom { kind: UnexpectedEof, error: "early eof" })

Same problem with iggyrs/iggy:0.0.46 image.

spetz commented 10 months ago

@pikhovkin that's most likely due to the missing authentication support, as code 40 means unauthenticated.

pikhovkin commented 10 months ago

@pikhovkin that's most likely due to the missing authentication support, as code 40 means unauthenticated.

@spetz and? how can i solve the problem?

spetz commented 10 months ago

@pikhovkin the obligatory authentication on the server side has been introduced in the version 0.0.20, so the simplest way, would to be use an image with the tag < 0.0.20. Of course, that'd result in having less features and recent bug fixes until the Python client catches up to the latest SDK version.

@darioalessandro do you see it doable in the near future? It's a few additional commands related to the user auth & management (for TCP/UDP client it's just a matter of providing the valid credentials, only for the HTTP integration it'd require storing the additional JWT).

darioalessandro commented 10 months ago

I agree with @spetz

spetz commented 8 months ago

The 0.1.0 package has been finally released, and it does support the authentication.

hubcio commented 8 months ago

@pikhovkin FYI if you didn't notice ;)