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

Speed improvements in manifest writing/deployment #435

Closed
slodge opened this issue Jun 10, 2020 · 7 comments
Closed

Speed improvements in manifest writing/deployment #435

slodge opened this issue Jun 10, 2020 · 7 comments

Comments

@slodge
Copy link

slodge commented Jun 10, 2020

In our environment we're experiencing a lot of user complaints about how slow RStudio Connect is.

Their current issues mainly seem to be linke with "deployment time" - which I think is mainly down to packrat.

We've made some investigations locally and I've made one suggestion for packrat - see rstudio/packrat#603

I'd also be interested in seeing #404 - as this might help us improve deployment times too.

Are there other things we can try in order to improve performance?

@kevinushey
Copy link
Contributor

I think the best thing we could do here is switch to using renv for deployments. (We could have renv create a Packrat-compatible lockfile to help ease the change)

@slodge
Copy link
Author

slodge commented Jun 10, 2020

Thanks. I agree that renv feels like the right direction for a proper fix/improvement.

However, I 'm assuming that renv integration is going to take a little longer to achieve, so was wondering if there are other measures I can take (like the PR above) to make things better in the short term for my complaining users.

@kevinushey
Copy link
Contributor

kevinushey commented Jun 10, 2020

You're correct. I took a quick look at your PR, and given that it doesn't change the default behavior I'm happy to take it. Thanks!

I think the main caveat is that users who take advantage of this feature may have to explicitly list their recursive package dependencies in addition to their top-level dependencies, though (e.g. in a file dependencies.R).

@aronatkins
Copy link
Contributor

@slodge - With rstudio/packrat#615, packrat does a much better job at avoiding repeatedly processing the same package dependency. Are you able to test performance against the latest GitHub version of packrat?

@slodge
Copy link
Author

slodge commented Jan 27, 2021 via email

@slodge
Copy link
Author

slodge commented Jan 28, 2021

More experiments today.

Similar sort of scale of results
e.g. 1m40 down to 9 seconds

No functional change observed.

These builds are done within "clean" Docker container images so feel quite a solid platform.

@aronatkins
Copy link
Contributor

@slodge Thanks so much for those experiments! This feels like enough of an improvement that I'm going to close this issue tracking the underlying performance problem with the packrat dependency analysis. Use of renv by rsconnect is tracked separately (including #471).

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

5 participants