otelbin icon indicating copy to clipboard operation
otelbin copied to clipboard

How are the autocompleted options for a component chosen?

Open aabmass opened this issue 2 years ago • 2 comments

First off thanks for working on this, it's pretty cool.

I'm wondering how the autocompleted options for a component are chosen. When I type googlecloud<TAB> in the exporters section, it automatically adds the following config keys:

  googlecloud:
    project: 
    user_agent: opentelemetry-collector-contrib {{version}}
    destination_project_quota: false
    timeout: "12s"

All but project are not options that users would normally want to tweak. It seems like the defaults come maybe come from the mapconfig default struct tag? I would guess that options with a default are usually the least relevant to users.

aabmass avatar Nov 01 '23 20:11 aabmass

Hey @aabmass,

we currently rely on a JSON schema and monaco-yaml to generate the autocompletion.

Agree w.r.t. the behavior. I have opened an issue with monaco-yaml to understand whether there is a way to change this behavior.

bripkens avatar Nov 02 '23 19:11 bripkens

Got it, thanks for looking into this!

aabmass avatar Nov 02 '23 20:11 aabmass