Allow more than 10 streams in es.concat #53

Closed
wants to merge 2 commits into
from

Conversation

Projects
None yet
3 participants

Without triggering the 'possible EventEmitter memory leak detected' warning.

jmerrifield added some commits Feb 27, 2014

@jmerrifield jmerrifield Allow more than 10 streams in a concat
Without triggering the 'possible EventEmitter memory leak detected' warning.
dcc16be
@jmerrifield jmerrifield Allow at least the default amount of listeners
For when we concat fewer than 10 streams. There doesn't seem to be a stable API for getting the current or default `maxListeners` count for a stream so just using 10 here.
803775a

oleics commented Mar 18, 2014

Same here.

with node v0.10.26, this DOES NOT work:

require('events').EventEmitter.defaultMaxListeners = 30;

but this works:

require('events').EventEmitter.prototype._maxListeners = 30;

It's a dirty workaround.

Owner

dominictarr commented Mar 18, 2014

don't set the max listeners globally in a module. If you do that in your application that is up to you, but don't mess with someone else's global state.

Owner

dominictarr commented Mar 18, 2014

Sorry I forgot about this, but can you make this a pull request to stream-combiner, not event-stream?

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