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

fix: cancel timeouts on drop #42

Merged
merged 1 commit into from Oct 26, 2016
Merged

fix: cancel timeouts on drop #42

merged 1 commit into from Oct 26, 2016

Conversation

@zenlor
Copy link
Contributor

zenlor commented Oct 12, 2016

Clear timeouts if the item is being dropped. Timers were hanging the process in my tap tests.

ex:

test('Something important', t => co(function * () {
    const id = 'an-id';
    const segment = 'segment';

    // assume promisified methods
    yield cache.set({id, segment }, 'useless value', 1440000);
    yield cache.drop({ id, segment });

    cache.stop();
    t.end();
    // timeout at this point
}));
@hueniverse

This comment has been minimized.

Copy link
Member

hueniverse commented Oct 25, 2016

@geek ping.

@geek geek added the bug label Oct 26, 2016
@geek

This comment has been minimized.

Copy link
Member

geek commented Oct 26, 2016

@hueniverse yikes! Thanks for the ping. @aliem sorry for the delay.

@geek geek self-assigned this Oct 26, 2016
@geek geek added this to the 2.0.4 milestone Oct 26, 2016
@geek geek merged commit 4602bf6 into hapijs:master Oct 26, 2016
1 check passed
1 check passed
continuous-integration/travis-ci/pr The Travis CI build passed
Details
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
3 participants
You can’t perform that action at this time.