CrunchyData / pgnodemx

A PostgreSQL extension that provides SQL functions to allow capture of node OS metrics via SQL queries.
Apache License 2.0
49 stars 11 forks source link

fix: correct parsing issues with quoted strings #8

Closed pgguru closed 2 years ago

pgguru commented 2 years ago

An initial stab at fixing the parsing issues seen in issue #7.

pgguru commented 2 years ago

The string parser has been brought up-to-date with Go's particular method of quoting. Example of how things work now from the output with synthetic data (i.e., not directly in an annotated pod, but using the same file that you would):

image

pgguru commented 2 years ago

Note: when merging, we will want to merge and squash.

pgguru commented 2 years ago

For reference on parsing spec:

https://cs.opensource.google/go/go/+/refs/tags/go1.17.3:src/strconv/quote.go;drc=refs%2Ftags%2Fgo1.17.3;l=31