Skip to content

Instantly share code, notes, and snippets.

@shiumachi
Last active December 23, 2015 11:33
Show Gist options
  • Star 1 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save shiumachi/4743578 to your computer and use it in GitHub Desktop.
Save shiumachi/4743578 to your computer and use it in GitHub Desktop.

LTSV

What is LTSV?

  • an extended format of TSV
  • you can label each field like this:
label:value<TAB>label:value<TAB>label:value ...

Why LTSV?

  • very simple!
  • flexibility for expanding
  • you can insert a record with new label without changing any metadata
  • very easy to generate log
  • In Apache HTTP Server, LogFormat directive can generate LTSV format log
  • nginx can do as well
  • why do you generate log in json format, or convert the log into json format?
  • very easy to parse log

    • because it's just TSV!
    • you can parse LTSV with standard unix commands e.g. cut, split, etc.
    • do you like to parse json without library?
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment