Skip to content

config: add sample config in text proto format.#1657

Closed
PiotrSikora wants to merge 2 commits intoenvoyproxy:masterfrom
PiotrSikora:pb_text
Closed

config: add sample config in text proto format.#1657
PiotrSikora wants to merge 2 commits intoenvoyproxy:masterfrom
PiotrSikora:pb_text

Conversation

@PiotrSikora
Copy link
Copy Markdown
Contributor

Support for parsing configs in the text proto was added in commit
ca8572e, but there were no tests
or examples that verified that this feature really works.

Support for parsing configs in the text proto was added in commit
ca8572e, but there were no tests
or examples that verified that this feature really works.

Signed-off-by: Piotr Sikora <piotrsikora@google.com>
@PiotrSikora
Copy link
Copy Markdown
Contributor Author

@htuch this is pretty ugly, any ideas if there are @type tricks for the text proto? I couldn't find any myself.

@htuch
Copy link
Copy Markdown
Member

htuch commented Sep 15, 2017

There aren't, @jmillikin-stripe has proposed we adopt Any for well-known protos. I'm unconvinced that proto text is desirable in general; it's not properly standardized and we already have a well supported text format (which Google is preferring going forward for proto text representation). I would drop this review for this reason.

@mattklein123
Copy link
Copy Markdown
Member

+1 I'm not sure we really want to demonstrate this to people. IMO we should push people towards JSON/YAML. It looks much nicer.

@PiotrSikora
Copy link
Copy Markdown
Contributor Author

I agree that due to use of google.protobuf.Struct the text format is pretty ugly and most people willl prefer JSON/YAML... But if we don't want to support text proto, then we should revert #1593, IMHO. We either support it (and have this trivial test that verifies it works) or not.

@jmillikin-stripe
Copy link
Copy Markdown
Contributor

jmillikin-stripe commented Sep 15, 2017

Even though using google.protobuf.Struct to encode normal messages is unpleasant, it's good to have a config format that both (1) has comments and (2) doesn't have a rich history of code execution vulnerabilities. Text protobufs are a nicely inert format that can still be documented.

@mattklein123
Copy link
Copy Markdown
Member

I don't really have a super strong opinion about this. As long as the proto library supports this we can support it. I don't want to really encourage people to use this though. @htuch ?

@PiotrSikora I think you need to push an empty commit to kick the DCO bot.

Signed-off-by: Piotr Sikora <piotrsikora@google.com>
@htuch
Copy link
Copy Markdown
Member

htuch commented Sep 18, 2017

Let's resolve #1680 first so we can decide where we want to go with proto text.

@mattklein123
Copy link
Copy Markdown
Member

What's our current thinking on this one? Personally I'm tempted to skip it. Note that @jmillikin-stripe did add test coverage for a basic proto text test, it's just written out in code. @PiotrSikora @htuch @jmillikin-stripe ? (This doesn't mean not supporting it via load, it just doesn't mean publicizing it).

@jmillikin-stripe
Copy link
Copy Markdown
Contributor

I'm fine with not having an example.

@htuch
Copy link
Copy Markdown
Member

htuch commented Sep 25, 2017

Let's make #1680 happen first, then we can support an example/test which will be readable.

@mattklein123
Copy link
Copy Markdown
Member

Let's make #1680 happen first, then we can support an example/test which will be readable.

It's not actually clear to me that we should fix that issue, but let's discuss there.

@htuch
Copy link
Copy Markdown
Member

htuch commented Sep 28, 2017

Let's close this out for now, feel free to reopen when we have some progress on #1680.

@htuch htuch closed this Sep 28, 2017
rshriram pushed a commit to rshriram/envoy that referenced this pull request Oct 30, 2018
rshriram pushed a commit to rshriram/envoy that referenced this pull request Oct 30, 2018
* Update_Dependencies (envoyproxy#1657)

* Use mTLS mode enum to decide authentication result.

* Clang

* Use NOT_REACHED macros for default case.

* Clang
jpsim pushed a commit that referenced this pull request Nov 28, 2022
Description: Exposes a StreamIntel struct on all response callbacks. Currently set up to contain stream ID, connection ID and attempt count, but eventually can furnish a variety of stream properties, context, and metrics.
Risk Level: Moderate
Testing: Local & CI
Docs Changes: Upcoming in separate PR

Signed-off-by: Mike Schore <mike.schore@gmail.com>
Signed-off-by: JP Simard <jp@jpsim.com>
jpsim pushed a commit that referenced this pull request Nov 29, 2022
Description: Exposes a StreamIntel struct on all response callbacks. Currently set up to contain stream ID, connection ID and attempt count, but eventually can furnish a variety of stream properties, context, and metrics.
Risk Level: Moderate
Testing: Local & CI
Docs Changes: Upcoming in separate PR

Signed-off-by: Mike Schore <mike.schore@gmail.com>
Signed-off-by: JP Simard <jp@jpsim.com>
mathetake pushed a commit that referenced this pull request Mar 3, 2026
**Description**

Store inter-token latency as float64 seconds instead of `time.Duration`
to prevent truncation when small durations are divided by large token
counts.

**Related Issues/PRs (if applicable)**

Fixes #1420
Obviates #1656

Signed-off-by: Adrian Cole <adrian@tetrate.io>
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.

4 participants