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

Separate server process for each file? #73

Open
zachmccormick opened this issue Sep 19, 2018 · 2 comments
Open

Separate server process for each file? #73

zachmccormick opened this issue Sep 19, 2018 · 2 comments

Comments

@zachmccormick
Copy link

I may be mistakenly reading the logs/results I'm getting, but it seems like this boots a totally separate server process for each file that it needs to template, meaning that unless you use Spring to cache classes in memory, this will be rather slow.

My project necessitates that I can't do that. Would it be too difficult to start a Ruby process, load in the Rails configuration, then just keep that process around, running the ERB template process inside of the same process each time? If it's something that seems possible I'll try to make a PR in the next few weeks for it.

@zachmccormick
Copy link
Author

I should have browsed the closed comments before this. #66 is fairly relevant

@rhys-vdw
Copy link
Collaborator

rhys-vdw commented Sep 19, 2018

Yeah as I mentioned in #66 (which I didn't realize had been closed) I think that would be ideal.

I think that solution will be possible. I guess we could just "lock" the process and send the files one at a time. Alternatively there could be a pool of processes.

The irony of the current behavior is that spring actually causes hangs so even though it's unbearable to disable it, it's often required.

I'd love it if you could take a look at implementing such a thing. I've also been considering dropping the ancient JS approach and moving to TypeScript. LMK if you'd like me to do that before you start. Might make editing more ergonomic.

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

No branches or pull requests

2 participants