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

Update message expiry interval #1813

Merged
merged 1 commit into from Sep 14, 2018

Conversation

@gilbertwong96
Copy link
Contributor

gilbertwong96 commented Sep 12, 2018

Prior to this change, emqx did not update message expiry interval and
there are duplicated functions to verify whether the message is expired.

This change delete the duplicated functions and add update action for
unexpired message.

@gilbertwong96 gilbertwong96 requested a review from turtleDeng Sep 12, 2018
@gilbertwong96

This comment has been minimized.

Copy link
Contributor Author

gilbertwong96 commented Sep 12, 2018

This is the problem of travis-ci. I have run all the test case on my local machine
image

@gilbertwong96

This comment has been minimized.

Copy link
Contributor Author

gilbertwong96 commented Sep 12, 2018

Maybe travis-ci did not support the shell command pushd

@gilbertwong96 gilbertwong96 force-pushed the Fix-message-expiry-interval branch 8 times, most recently from 61ebbe9 to 1075cb4 Sep 12, 2018
@@ -668,8 +668,9 @@ retry_delivery(Force, [{Type, Msg0, Ts} | Msgs], Now,
emqx_metrics:inc('messages/expired'),
emqx_inflight:delete(PacketId, Inflight);
false ->
redeliver({PacketId, Msg}, State),
emqx_inflight:update(PacketId, {publish, {PacketId, Msg}, Now}, Inflight)
Msg1 = emqx_message:update_expiry(Msg),

This comment has been minimized.

Copy link
@emqplus

emqplus Sep 14, 2018

Contributor

Should not update expiry in session. Do it in connection(emqx_protoco).

Prior to this change, there are multiple deprecated functions.
@gilbertwong96 gilbertwong96 force-pushed the Fix-message-expiry-interval branch from 1075cb4 to 345fe71 Sep 14, 2018
@coveralls

This comment has been minimized.

Copy link

coveralls commented Sep 14, 2018

Pull Request Test Coverage Report for Build 3201

  • 0 of 0 changed or added relevant lines in 0 files are covered.
  • 1 unchanged line in 1 file lost coverage.
  • Overall coverage increased (+0.08%) to 54.771%

Files with Coverage Reduction New Missed Lines %
src/emqx_message.erl 1 28.13%
Totals Coverage Status
Change from base Build 3196: 0.08%
Covered Lines: 2227
Relevant Lines: 4066

💛 - Coveralls
@emqplus emqplus merged commit 45b2686 into emqx30 Sep 14, 2018
3 checks passed
3 checks passed
continuous-integration/travis-ci/pr The Travis CI build passed
Details
continuous-integration/travis-ci/push The Travis CI build passed
Details
coverage/coveralls Coverage increased (+0.1%) to 54.771%
Details
@emqplus emqplus self-assigned this Sep 14, 2018
@huangdan huangdan added this to the 3.0-beta.3 milestone Sep 23, 2018
@terry-xiaoyu terry-xiaoyu deleted the Fix-message-expiry-interval branch Sep 23, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
4 participants
You can’t perform that action at this time.