Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Conversation

@erwinvaneyk
Copy link
Contributor

This change ensures that the offset of each request is stored (and printed when using csv) to allow users to visualize and analyze temporal relationships between requests.

As a flyby this change fixes a minor bug where the CSV output starts with an empty line.

@rakyll
Copy link
Owner

rakyll commented Sep 11, 2018

It would be good to document the CVS layout on the top of the output. Can you add the column names to the top of the file? Otherwise LGTM.

@erwinvaneyk
Copy link
Contributor Author

Thanks @rakyll for the quick reply - I added some comments to the top of the file to document the general structure

@rakyll
Copy link
Owner

rakyll commented Sep 18, 2018

Thanks!

@rakyll rakyll merged commit 3dd8421 into rakyll:master Sep 18, 2018
chunter0 pushed a commit to chunter0/hey that referenced this pull request Apr 8, 2024
`go-httpbin` was incorrectly returning `http` as the scheme for its URL
if you ran it with TLS specified via `HTTPS_CERT_FILE` and
`HTTPS_KEY_FILE`. Update it to return https as the scheme in this case
by checking if `r.TLS` is not nil

Before:

```
$ mkcert test
$ docker run -e HTTPS_CERT_FILE='/tmp/test.pem' -e HTTPS_KEY_FILE='/tmp/test-key.pem' -p 8080:8080 -v $(pwd):/tmp mccutchen/go-httpbin
$ curl -sk https://localhost:8080/get | jq -r .url
http://localhost:8080/get
```

After (TLS):

```
$ docker run -e HTTPS_CERT_FILE='/tmp/test.pem' -e HTTPS_KEY_FILE='/tmp/test-key.pem' -p 8080:8080 -v $(pwd):/tmp llimllib/go-httpbin
$ curl -sk https://localhost:8080/get | jq -r .url
https://localhost:8080/get
```

After (no TLS):

```
$ docker run -p 8080:8080 llimllib/go-httpbin
$ curl -sk http://localhost:8080/get | jq -r .url
http://localhost:8080/get
```

I got the idea for how to check the scheme from [this SO
post](https://stackoverflow.com/a/61446922/42559)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants