Thanks for pointing that out. A very interesting talk indeed.

I've started working on a small tool to make it safer and easier to
poke at a running node process (at least for me).

On Feb 17, 5:49 am, Jeroen Janssen <[email protected]> wrote:
> Hi,
>
> I recently watched some of the NodeConf 2011 talks and I think one of
> the talks also mentioned using repl in production (I believe it 
> washttp://blip.tv/jsconf/nodeconf-2011-matt-ranney-5951153).
> If I understand correctly, he adds 'hooks' that you can inject stuff
> in from a repl, but he has those hooks surrounded by try/catch to not
> crash stuff in case of mistakes.
>
> I hope this helps.
>
> Jeroen Janssen
>
> On Feb 16, 10:21 pm, Laurent Perrin <[email protected]> wrote:
>
>
>
>
>
>
>
> > I just had a bad surprise on a production server and thought I'd share it.
>
> > I have a complex node process that can open a REPL over a unix socket for 
> > debugging purposes. If I enter invalid code:
>
> > - If the code is executed immediately, it reports an error in the REPL and 
> > continues.
>
> > - However, if the code is in a different tick (e.g. 
> > setTimeout/setInterval), it crashes the whole process.
>
> > Now, I could add a process.uncaughtException, but I'd rather let the 
> > process crash if a "real" error happen somewhere else. It's not necessarily 
> > a node problem, but it makes the REPL a very dangerous tool to me.
>
> > Is there a safer way to inspect a running process ?
>
> > Btw, here's a simple example:http://pastebin.com/ad93YHdk
>
> > --
> > Laurent

-- 
Job Board: http://jobs.nodejs.org/
Posting guidelines: 
https://github.com/joyent/node/wiki/Mailing-List-Posting-Guidelines
You received this message because you are subscribed to the Google
Groups "nodejs" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to
[email protected]
For more options, visit this group at
http://groups.google.com/group/nodejs?hl=en?hl=en

Reply via email to