-
Notifications
You must be signed in to change notification settings - Fork 1.9k
feat(otel): Add bindOtel()
support
#4269
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
base: main
Are you sure you want to change the base?
Conversation
Introduces bindOtel() and withOtelShiny() to enable OpenTelemetry tracing for reactive objects and observers. Adds options shiny.otel.bindall and shiny.otel.graphlocked for automatic binding and graph locking. Updates reactiveVal, reactiveValues, reactive, and observe to support automatic OpenTelemetry binding. Documentation and NAMESPACE updated accordingly.
Included r-lib/otelsdk in the Remotes field to enable installation from GitHub. This supports dependencies required for development or testing.
bindOtel()
bindOtel()
support
* main: preemptively run revdepcheck. 5 failures. fix(scss): Remove updated scss files and restore R sass compilation (#4272)
…cent one is evaluated last
After live discussion with @schloerke:
|
… within the Shiny package
Using rstudio/promises#176, ✅ within Shiny. Works great! 🥳🥳 |
* main: update docs (#4285)
…passing weather chat app demo
R/otel.R
Outdated
if (!is.null(tracer)) { | ||
return(tracer) | ||
} | ||
if (testthat::is_testing()) { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Must also check if testthat is installed. No need to use a perfect / fast reproducible call here as it is only possibly repeated during testing.
Refactored label assignment to use rassignSrcrefToLabel for both reactiveVal and reactiveValues, ensuring a sensible default label is used when the assigned name cannot be easily determined from srcref. This change improves robustness and consistency in labeling reactive objects.
…. Makes otel clean
Related: #4258
Fixes #4265 -
bindOtel(x)
,withOtel(expr, ..., bind = "all")
Fixes #4268 -
options(shiny.otel.bind = "all")
(and"none"
)Possible future support:
Fixes #4268 -
options(shiny.otel.bind = c("reactiveVal", "reacitveValues", "reactiveExpr", "observe", "output")
Fixes #4266 -
options(shiny.otel.bind = "reactive-update")
Fixes #4282 -
options(shiny.otel.binnd = "session")