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

added: 'wss' to reloadReturn #148

Merged
merged 1 commit into from
Jun 11, 2018
Merged

added: 'wss' to reloadReturn #148

merged 1 commit into from
Jun 11, 2018

Conversation

valango
Copy link
Contributor

@valango valango commented Jan 11, 2018

Hi,

I put a brief explanation of the problem I was addressing, into README.

There is many solutions of course.

BR
Villem

@alallier
Copy link
Owner

Hey thanks @valango I have a couple of questions? Are you stopping the server and not ending the node process?

Can you provide a step by step example of what you are trying to achieve?

@valango
Copy link
Contributor Author

valango commented Feb 2, 2018

Hey @alallier, I'll explain.

My purpose was to speed up reloads in WebPack development environment. A typical set-up has instrumental js script (together w configs) in, say build/ directory, doing the following:

  1. building the front-end code (often taking a looong time);
  2. loading and running back-end (server app) code;
  3. monitoring the source files and restarting on file change.

When you work on back-end code, it's frustrating to wait for needless front-end recompilation every time. My solution was: on back-end source change, do NOT kill the process but just stop server, invalidate require() cache and reload/restart back-end code again while keeping front-end part as it is. It works now :)

The problem was the zombified web socket, which gave me EACCESS after reload. This was the problem I was addressing, but it matters in of dev/test environment only.

I will add a small example project, but it will take some time.

Sorry for being unresponsive for a week!

@alallier
Copy link
Owner

Going to take this, sorry it took so long @valango. I'm going to tweak the documentation a bit after I merge it so don't be alarmed vs. having to go back and forth with you

@alallier alallier merged commit f12cc4c into alallier:master Jun 11, 2018
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

Successfully merging this pull request may close these issues.

2 participants