question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Rename "request" to "sample", and refactor request_success/failure into one event

See original GitHub issue

The word request makes no sense for a lot of non-http protocols. Users could be reporting things like the reception of async WebSocket messages, or the time to run a script. The word sample is more appropriate.

Having separate events for request_success and request_failure make no sense either, so I suggest we deprecate those (but support them for a long time) and just use a single one, sample(with a boolean parameter success).

Perhaps this should be done at the same time https://github.com/locustio/locust/issues/1413

Issue Analytics

  • State:closed
  • Created 3 years ago
  • Comments:15 (5 by maintainers)

github_iconTop GitHub Comments

2reactions
heymancommented, Mar 10, 2021

What are your feelings about the other part, merging request_success/failure into a single event?

I don’t have a strong opinion about it. But if I were to choose today, I think I’d prefer a single event. So as long as we kept the old ones for backwards compatibility for a long time like you said, I think it’s a good idea to change it.

1reaction
cyberwcommented, Apr 15, 2021

@DennisKrone is working on a PR to add optional metadata to the event (basically anything you like, things like customer id is a good example).

We’ve also talked about adding the User object, and I think request/response make a lot of sense as well. We just need a sensible behaviour for non-http / custom clients as well.

Read more comments on GitHub >

github_iconTop Results From Across the Web

Xcode 9 refactoring gives "Rename failed" - Apple Developer
Hi. I wanted to change the name of a variable in XCode 9 9M136h. So, I selected the name, brought up the context...
Read more >
Refactoring the script | Visual Scripting | 1.5.2 - Unity - Manual
Renaming Members​​ To continue the previous example, to fix the failure, reopen the script file and map the new name to the previous...
Read more >
[65cat] Unsupported refactoring scenarios in GUI builder
Does renaming inside of an event handler method work? In the nightly build I'm working with right now(200706220000), when I try to refactor...
Read more >
Language Server Protocol Specification - 3.17
This document describes the 3.17.x version of the language server protocol. An implementation for node of the 3.17.x version of the protocol can...
Read more >
Rename and Refactoring to Make Changes to your Database ...
Learn about the Rename and Refactor menus in the Transact-SQL Editor. See how to rename types, switch object schemas, expand wildcards, ...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found