handling multiple users simulaneously in an R Shiny app

后端 未结 1 1507
我在风中等你
我在风中等你 2021-01-31 19:58

I have a simple shiny app that keeps track of the number of times the user has pushed a certain action button (actionButton()), and this total is reported back to t

相关标签:
1条回答
  • 2021-01-31 20:36

    I think you're mistaken. Shiny, by default, creates one process per Shiny app, but can facilitate an unlimited number of sessions (i.e. "user connections") in a single app/process.

    Checkout this chapter of the tutorial for more info on scoping: http://rstudio.github.io/shiny/tutorial/#scoping

    Basically, anything defined inside of the shinyServer() expression is going to be private to a single user's session. Any variables you put outside of shinySever will be globally shared between all users. So you can just keep your variables (e.g. a counter of clicks) inside of shinyServer() if you don't want them to be shared across sessions.

    0 讨论(0)
提交回复
热议问题