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

Add is_running() method #910

Open
schloerke opened this issue Jun 29, 2023 · 0 comments
Open

Add is_running() method #910

schloerke opened this issue Jun 29, 2023 · 0 comments
Labels
difficulty: intermediate Enterprising community members could help effort: medium < 3 days of work help wanted Solution is well-specified enough that any community member could fix
Milestone

Comments

@schloerke
Copy link
Collaborator

From @nbenn in https://community.rstudio.com/t/determine-whether-code-is-being-run-as-part-of-a-plumber-api/169128

I am looking for a reliable way of determining if code is being run "under" plumber. Something like what I believe shiny::isRunning() provides.

Thanks!


I'd like for it to take pr as a value and have it default to something like get_current_router() (or something) that possibly returns the currently running server and checks for a flag.

Could also have a method to return currently running plumber routers (if non-blocking) is implemented. And then the length of the routers could be checked for > 0.

@meztez meztez added this to the v1.3.0 milestone Nov 24, 2023
@meztez meztez added difficulty: intermediate Enterprising community members could help effort: medium < 3 days of work help wanted Solution is well-specified enough that any community member could fix labels Nov 24, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
difficulty: intermediate Enterprising community members could help effort: medium < 3 days of work help wanted Solution is well-specified enough that any community member could fix
Projects
None yet
Development

No branches or pull requests

2 participants