123

I've recently learned that R Shiny programs impose a maximum size restriction for file uploads by default (I don't know what the size is exactly, but I'm guessing it's 5,000 KB). I'd like to remove this restriction. How can I do so, and what is there a general rule of thumb for the size of user uploads?

In addition, this is on another note, but related: how can I save fie inputs by the user BY session? For example, there would be a file prompt in the application, in which the user can upload a file. Then, when the user chooses the file to display, he can pick among the files he has uploaded. If he exits the session, the list clears.

GSee
  • 48,880
  • 13
  • 125
  • 145
jeffrey
  • 3,196
  • 7
  • 26
  • 44
  • 6
    For the second part of your question, see http://rstudio.github.io/shiny/tutorial/#scoping (you will want to declare a `values <- reactiveValues(uploads=list())` in the per-session scope, and add new data to `values$uploads`). – Joe Cheng Aug 10 '13 at 04:33

1 Answers1

193

Quoting Joe Cheng from this shiny-discuss post

By default, Shiny limits file uploads to 5MB per file. You can modify this limit by using the shiny.maxRequestSize option. For example, adding options(shiny.maxRequestSize=30*1024^2) to the top of server.R would increase the limit to 30MB.

GSee
  • 48,880
  • 13
  • 125
  • 145