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

[connector/servicegraph] Update virtual node defaults and change feature gate to beta #31735

Merged
merged 15 commits into from
Apr 14, 2024

Conversation

ogxd
Copy link
Contributor

@ogxd ogxd commented Mar 13, 2024

Description:

  • Change default values to peer.service, db.name and db.system (in this order). These are compliant with conventions, and the same as the tempo service graph uses.
  • Switch the feature from "alpha" to "beta". Virtual nodes are working well on the tempo side, and feature could be disabled anyway by using an empty list if needed.
  • Reword documentation for improved clarity
  • Fix "processor" that should be "connector" instead since recent commit

Link to tracking Issue: #31734

Testing: No functional change requiring additional tests

Documentation: Updated documentation

@ogxd ogxd requested review from jpkrohling and a team as code owners March 13, 2024 20:29
Copy link

linux-foundation-easycla bot commented Mar 13, 2024

CLA Signed

The committers listed above are authorized under a signed CLA.

@ogxd ogxd force-pushed the servicegraphconnector-virtualnodes branch from 024fc6a to 69d2ab0 Compare March 13, 2024 20:56
Copy link
Contributor

@mapno mapno left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This a breaking change, but since the feature was in alpha I think it's still ok to change the attribute list. It now matches the Tempo defaults, so I'm good with the change. Thanks!

@ogxd ogxd force-pushed the servicegraphconnector-virtualnodes branch from 71cb827 to 201df8d Compare March 18, 2024 09:01
@ogxd
Copy link
Contributor Author

ogxd commented Mar 18, 2024

I have rebased + updated the defaults in the feature gate description as well

Copy link
Member

@JaredTan95 JaredTan95 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@ogxd
Copy link
Contributor Author

ogxd commented Mar 26, 2024

@jpkrohling can this be merged?

@Frapschen
Copy link
Contributor

@ogxd Sorry for the delay, I think we should add a changelog to notify users

@Frapschen
Copy link
Contributor

feature could be disabled anyway by using an empty list if needed.

I doubt that not work.

if virtualNodeFeatureGate.IsEnabled() {
e.ConnectionType = store.VirtualNode
if len(e.ClientService) == 0 && e.Key.SpanIDIsEmpty() {
e.ClientService = "user"
p.onComplete(e)
}
if len(e.ServerService) == 0 {
e.ServerService = p.getPeerHost(p.config.VirtualNodePeerAttributes, e.Peer)
p.onComplete(e)
}
}

func (p *serviceGraphConnector) getPeerHost(m []string, peers map[string]string) string {
peerStr := "unknown"
for _, s := range m {
if peer, ok := peers[s]; ok {
peerStr = peer
break
}
}
return peerStr
}

Even when the VirtualNodePeerAttributes is empty, a virtual node service named unknown will exist when this feature gate is enabled by default.

@ogxd
Copy link
Contributor Author

ogxd commented Apr 3, 2024

Indeed, I just added a check to disable the feature if virtual_node_peer_attributes is empty. I also updated the documentation and included a changelog entry.

Copy link
Contributor

@Frapschen Frapschen left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@ogxd
Copy link
Contributor Author

ogxd commented Apr 11, 2024

Please excuse me for the bothering 😅
Can this PR be merged? @Frapschen @jpkrohling

@dmitryax dmitryax merged commit 1259b63 into open-telemetry:main Apr 14, 2024
170 checks passed
@github-actions github-actions bot added this to the next release milestone Apr 14, 2024
@ogxd ogxd deleted the servicegraphconnector-virtualnodes branch April 15, 2024 12:56
rimitchell pushed a commit to rimitchell/opentelemetry-collector-contrib that referenced this pull request May 8, 2024
…ure gate to beta (open-telemetry#31735)

**Description:**

- Change default values to peer.service, db.name and db.system (in this
order). These are compliant with conventions, and the same as the tempo
service graph uses.
- Switch the feature from "alpha" to "beta". Virtual nodes are working
well on the tempo side, and feature could be disabled anyway by using an
empty list if needed.
- Reword documentation for improved clarity
- Fix "processor" that should be "connector" instead since recent commit

**Link to tracking Issue:**
open-telemetry#31734

**Testing:** No functional change requiring additional tests

**Documentation:** Updated documentation
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

6 participants