-
Notifications
You must be signed in to change notification settings - Fork 1.3k
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
Non-application-protocol error codes #895
Comments
I would suggest numerical codes outside the http response code range. It can be confusing to have 4xx and 5xx mean the http response code and 100-399 have a completely different meaning than the corresponding http error codes. I would suggest simply adding 1000 to all of the suggestions (with the exception of 0 which has special meaning) would solve the predicament I am worried about here at least. |
@micsjo Yeah, we discussed this internally this morning as well. We'll offset the error codes by a 1000. |
This currently only supports http and the errors currently codified are based on what errors were seen the most. Some errors have new custom messages - this has been done to errors with changing messages with the new custom message primarely removing the changing parts, usually ip/ports and such.
This currently only supports http and the errors currently codified are based on what errors were seen the most. Some errors have new custom messages - this has been done to errors with changing messages with the new custom message primarely removing the changing parts, usually ip/ports and such.
This currently only supports http and the errors currently codified are based on what errors were seen the most. Some errors have new custom messages - this has been done to errors with changing messages with the new custom message primarely removing the changing parts, usually ip/ports and such.
This currently only supports http and the errors currently codified are based on what errors were seen the most. Some errors have new custom messages - this has been done to errors with changing messages with the new custom message primarely removing the changing parts, usually ip/ports and such.
This currently only supports http and the errors currently codified are based on what errors were seen the most. Some errors have new custom messages - this has been done to errors with changing messages with the new custom message primarely removing the changing parts, usually ip/ports and such.
This currently only supports http and the errors currently codified are based on what errors were seen the most. Some errors have new custom messages - this has been done to errors with changing messages with the new custom message primarely removing the changing parts, usually ip/ports and such.
This also sets the error tag to the now more non dynamic messages. This also changes a little bit of the behaviour specifically in that if there is an error while making the http request that is not from the RoundTripper than we consider this to be exception worthy now and independantly of `throw` it will result in a exception. This should not be ... common at all: the only error that is suppose to be able to happen is if a redirect has an unparsable/missing location.
…lErrorCodes Implement non application error codes fix #895
When there's a non-application-protocol error for a HTTP request or WebSocket connection today k6 sets a status of 0 (property
status
in response object and metric output tags) and adds a Go stdlib message to theerror
property in the response object as well as the metrics output tags.This presents a number of problems when trying to analyze the data, whether manually or computer-aided:
error
messages contain randomly selected src and dest TCP port numbers, meaning each message is unique although reporting the same issueI therefore propose we introduce a new property
error_code
. A pre-defined numeric value that we map to the list of possible errors that k6 can run into. This solves the problems mentioned above; it will make it much easier to aggregate and present error stats and we can provide much more end-user digestible error messages.I think we should also define ranges of values for different categories/layers of errors like: DNS, TCP, TLS, HTTP etc.
The gist of the proposal:
error_code
property to the Response object [1].error_code
tag in the metrics outputerror
Response property and metrics tag to a new, user friendlier error message written by us for each of the possible error codes[1] - https://docs.k6.io/docs/response-k6http
[2] - #66 (the original issue regarding this topic, with the discussion that resulted in the current solution with
status: 0
anderror: message
)The text was updated successfully, but these errors were encountered: