Closed kessler closed 8 years ago
hmm I'm not a huge fan of replacing methods as a way to facilitate extension personally
Hi TJ, Thanks for replying. I just thought it would be an efficient way to replace net.createServer with something like tls.createServer without duplicating much code. Client sockets can probably be dealt with but it makes it easier too. We are working on a secure-axon extension...
Is it because you think inheritance breaks encapsulation? or is there another reason?
/cc @arielbadichi
@tj what do you think about adding { secure: TLSOptionsObj }
, as configuration passed when creating a socket? It seems like this could be a useful feature for people doing this outside of an internal network. I'll flesh out a PR
@jcrugzz we already got something in the works as a plugin, but it could be easily integrated into the code, maybe you want to use that ?
@kessler I'd like to see what it looks like. I just agree with @tj that overwriting functions on the prototype is meh.
@jcrugzz I will merge the code from the plugin to a fork during the weekend and ping you, ok?
sounds good
@kessler can you please close the issue if it's no longer required?
@TEugen Hey, sorry for letting this slip, let me do a quick check regarding the status of the work I did back then and update this thread
Code is in WIP state, closing this for now