Skip to content
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

Quoted fields #28

Closed
timbray opened this issue May 6, 2024 · 1 comment
Closed

Quoted fields #28

timbray opened this issue May 6, 2024 · 1 comment

Comments

@timbray
Copy link
Owner

timbray commented May 6, 2024

Personally, I mostly use tf on apache https access_log files and have used the default space-separation. This mostly works, but sometimes not, see the two following lines:

i577a483c.versanet.de - - [12/Mar/2007:08:03:37 -0800] "GET /ongoing/ongoing.atom HTTP/1.1" 304 - "-" "NetNewsWire/2.1 (Mac OS X; http://ranchero.com/netnewswire/)"
105.66.1.178 - - [19/Apr/2020:06:38:44 -0700] "-" 408 156 "-" "-"

In the first one, the target URL is (space-separated) field number 7. In the second one, which I believe represents someone connecting to the server and not doing anything till it times out, there is no HTTP verb and field 7 is the HTTP status signaling timeout.

If topfew could recognize quoted fields, then field 6 in the first example would be GET /ongoing/ongoing.atom and in the second would be -, which would be more correct from the point of topfew processing. So I think there needs to be a -q option, or some such, to ask topfew to process quote-delimited space-separated fields properly.

timbray added a commit that referenced this issue May 11, 2024
addresses #28 and #27

Signed-off-by: Tim Bray <tbray@textuality.com>
@timbray
Copy link
Owner Author

timbray commented May 11, 2024

Fixed in #29

@timbray timbray closed this as completed May 11, 2024
timbray added a commit that referenced this issue May 12, 2024
* kaizen: add -q option for quoted fields

addresses #28 and #27

Signed-off-by: Tim Bray <tbray@textuality.com>

* add missing test data

Signed-off-by: Tim Bray <tbray@textuality.com>

---------

Signed-off-by: Tim Bray <tbray@textuality.com>
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

No branches or pull requests

1 participant