Repository navigation
Dubbo-Go 可观测字段梳理 #3766
AsperforMias
started this conversation in
General
Replies: 1 comment
|
Thanks for revising the audit and moving it here. I rechecked the current text against the pinned
I independently reran the nine packages listed in Verification from a clean archive of that exact commit, with Go 1.25.0 on darwin/arm64 and I have no remaining blocking comments on this documentation audit. This satisfies the documentation deliverable in #3720; the runtime gaps listed in the follow-up matrix remain separate implementation work. |
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
For #3720. This audit uses
develop@9af40a2b; the source and test links use the same revision.Metric
interfaceand OTelrpc.serviceboth useURL.Service(). The main differences are in generic-call method names, error fields and log correlation.RPC fields
application_namefrom URLapplicationservice.namefrom application nameapplication_versionfrom URLapp.versionservice.versionfrom application versioninterface=URL.Service()rpc.service=URL.Service()method=MethodName()rpc.method=MethodName(); span name =ActualMethodName()group/versiondubbo.group/dubbo.version, when non-emptydubbo_provider_*/dubbo_consumer_*namesrpc.systemisapache_dubboip,hostnameSources: RPC labels, metric families, OTel filter, resource setup, application configuration. Tests: labels, span attributes.
RPC failures use separate timeout, limit, unavailable, business and unknown counter families, with no
error_typelabel. The classifier handles Triple/gRPC codes; Dubbo-protocol errors fall into unknown. Network and codec categories are declared but not produced. The collector updates the counters. The OTel filter records an error status anderr.Error()as its description, without callingRecordErroron that path.Logs
Trace integration defaults to false. With the context-aware Zap or Logrus adapter, a
Ctx*call addstrace_id,span_idandtrace_flagsfrom a valid span context. Ordinary calls and contexts without a valid span omit those fields. Service, method, protocol, side and error category are not added automatically.CtxError*can record errors on a recording span when configured. See the extractor, Zap tests and Logrus tests.AccessLog copies a fixed set of attachments: interface (with path fallback), method, version, group, timestamp,
local-addrandremote-addr. It derivestypesandargumentsfrominvocation.Arguments(). Its builder and formatter ignoretrace_id,span_idandtraceparent, even when those keys are attached.Metadata
The catalog stores the application in
MetadataInfo.App.ServiceInfocontains name, group, service version, protocol, port, path and params; method names are in themethodsparameter. It has no calling-side or error-category field.Mapping metrics use application tags plus
interfaceandgroupfrom attachments. A non-empty attachmentapplicationoverridesapplication_name; otherwise the application-level value is retained. There is no method or service-version label.Register/remove use
Succto count success. Get/listen useSucc && !Partial, so partial success increments the failed counter. Each operation also records its total count and RT. Fetch addsprovider_app,result,sourceandstorage_type; cache addsprovider_appwith hit/miss counters. See definitions and tests.Compatibility and follow-ups
Keep existing metric names/labels and the registration/routing meaning of
ServiceKey(). That key has the formgroup/interface:versionand omits version0.0.0; the telemetry version fields retain the raw value. Trace/span IDs, revisions, URLs, payloads and error messages should stay out of default metric labels.rpc.method$invokewith its actual method name#3551 proposes span-name and attribute changes; those are not present at this pin. Update, 2026-10-16: #3743 and #3744 merged after the audited revision, adding Path-fallback and dynamic logger regression tests. #3763 proposes further logger assertions.
Verification
The nine packages below passed on 2026-10-16 with Go 1.25.0 / darwin/arm64. The audit branch changes documentation only; its runtime/test code remains at the audited revision.
GOTOOLCHAIN=go1.25.0 go test -mod=readonly -count=1 \ ./metrics/rpc ./filter/otel/trace ./filter/metrics \ ./logger ./logger/core/zap ./logger/core/logrus \ ./filter/accesslog ./metadata/info ./metrics/metadataAll reactions