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

APNS resend queue #39

Merged
merged 2 commits into from
Jan 5, 2015
Merged

APNS resend queue #39

merged 2 commits into from
Jan 5, 2015

Conversation

alexdruzhilov
Copy link

Fix for issue #17

Commit is adopted for version 1.0.2 from two commits:
altenwald@06431ef
altenwald@618e52c

{stop, normal, State};

handle_cast({in, Msg}, #state{max_entries=MaxEntries,queue=OldQueue}=State) ->
Queue = case MaxEntries =< ?QUEUE:len(OldQueue) of
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

We would prefer avoiding using macros for function or module names.

Guideline

@manuel-rubio
Copy link
Contributor

Fixed: altenwald/apns4erl@b59e7a0

@elbrujohalcon
Copy link
Member

@manuel-rubio somehow that commit did not get into the PR

@alexdruzhilov
Copy link
Author

Added into pull request


handle_cast({in, Msg}, #state{max_entries=MaxEntries,queue=OldQueue}=State) ->
Queue = case MaxEntries =< queue:len(OldQueue) of
true -> queue:liat(OldQueue);
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Just as a comment, I would avoid the Okasaki version of the queue api.

@igaray
Copy link
Member

igaray commented Jan 5, 2015

Looks good, some tests would be welcome :)

igaray added a commit that referenced this pull request Jan 5, 2015
@igaray igaray merged commit 7b7153e into inaka:master Jan 5, 2015
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.

None yet

4 participants