-
Notifications
You must be signed in to change notification settings - Fork 69
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
Checking in the Producer #160
Comments
Hey @rodrigotheodoropsv, I understand what you mean. In the current version, the errors are raised as exceptions, hence you need to use |
I'm trying to imagine how I can use k6's checks to check if my produce writes the message or get some error, just to create my metrics in base of this. Like the version v0.11, that the method produce return a error and normally we used the check about the return of the method. Sorry if my questions are silly or base. |
Like, is it possible to get the metrics from kafka "Metric: k.metrics.WriterErrors" and "Metric: k.metrics.WriterMessages" in my JS script? If it is, so I just need to learn how and I can go forward about it. |
This is a valid point, and I'll make a ticket for it to export metrics. |
I'll try to come up with an example script, soon. |
Hello @mostafa.
First of all sorry for my english, I hope you understand my goal here.
I was thinking and trying to implement the extension, I've already used the last versions (v0.11 and before) that the script had a different implementation and I could check if the producer catch some error when it tried to write the message in the topic.
Could be interesting if we implement a step to return an error just to continuing to check it? I saw in the file " producer.go" at line 296 after the "Ifs" it will be interesting to return error and check it, because sometimes we are not testing the kafka, but we are tesnting the application that is consuming the messages that we are producing. That way we can just return the error and check in the script.js if the error != undefined we understand the produce got an error when it tried to write in the topic (Like the old way).
What do you think about?
Regards, Rodrigo.
The text was updated successfully, but these errors were encountered: