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

Force shutdown policy #1836

Merged
merged 13 commits into from Sep 21, 2018

Conversation

@spring2maz
Copy link
Contributor

spring2maz commented Sep 18, 2018

No description provided.

@spring2maz spring2maz requested review from emqplus and turtleDeng Sep 18, 2018
@coveralls

This comment has been minimized.

Copy link

coveralls commented Sep 18, 2018

Pull Request Test Coverage Report for Build 3297

  • 16 of 36 (44.44%) changed or added relevant lines in 3 files are covered.
  • 2233 unchanged lines in 71 files lost coverage.
  • Overall coverage decreased (-54.2%) to 1.382%

Changes Missing Coverage Covered Lines Changed/Added Lines %
src/emqx_misc.erl 16 18 88.89%
src/emqx_connection.erl 0 9 0.0%
src/emqx_session.erl 0 9 0.0%
Files with Coverage Reduction New Missed Lines %
src/emqx_ctl.erl 1 29.17%
src/emqx_tables.erl 1 66.67%
src/emqx_config.erl 2 0.0%
src/emqx_local_bridge_sup_sup.erl 2 0.0%
src/emqx_reason_codes.erl 3 0.0%
src/emqx_session_sup.erl 3 0.0%
src/emqx_broker_helper.erl 4 0.0%
src/emqx_sys_sup.erl 4 0.0%
src/emqx_time.erl 4 0.0%
src/emqx_cm_sup.erl 4 0.0%
Totals Coverage Status
Change from base Build 3275: -54.2%
Covered Lines: 57
Relevant Lines: 4123

💛 - Coveralls
@emqplus emqplus self-assigned this Sep 19, 2018
@emqplus emqplus changed the title Shutdown policy Force shutdown policy Sep 19, 2018
{default, -1}, %% disabled by default
{datatype, integer}
]}.

This comment has been minimized.

Copy link
@emqplus

emqplus Sep 19, 2018

Contributor

{mapping, "zone.$name.force_shutdown_policy", "emqx.zones", [
{default, "msg_queue_len|total_heap_size"},
{datatype, string}
]}.

The implementation prior to this commit supports
only one gc enforcement policy which is message count threshold.
The new implementation introduces 1 more: volume threshold based
@spring2maz spring2maz force-pushed the more-gc-enforcement-policies branch from 955b789 to e940c1c Sep 19, 2018
spring2maz added 3 commits Sep 18, 2018
The hibernation behaviour is also changed (implicitly) in this commit:
Prior to this change, connection/session always hibernates after
the stats timer expires regardless of messages in mailbox.
After this commit, connection/session process only goes to hibernate
when the timer expires AND there is nothing left in the mailbox to
process
@spring2maz spring2maz force-pushed the shutdown-policy branch 3 times, most recently from 0f55274 to c7b384e Sep 19, 2018
@spring2maz spring2maz force-pushed the shutdown-policy branch from c7b384e to f58165d Sep 20, 2018
@spring2maz spring2maz changed the base branch from more-gc-enforcement-policies to emqx30 Sep 21, 2018
spring2maz added 4 commits Sep 18, 2018
The hibernation behaviour is also changed (implicitly) in this commit:
Prior to this change, connection/session always hibernates after
the stats timer expires regardless of messages in mailbox.
After this commit, connection/session process only goes to hibernate
when the timer expires AND there is nothing left in the mailbox to
process
@spring2maz spring2maz force-pushed the shutdown-policy branch from f58165d to b616153 Sep 21, 2018
@spring2maz

This comment has been minimized.

Copy link
Contributor Author

spring2maz commented Sep 21, 2018

rebased

Feng Lee and others added 4 commits Sep 21, 2018
Feng Lee
Feng Lee
Feng Lee
@emqplus emqplus merged commit 71c556b into emqx30 Sep 21, 2018
1 of 3 checks passed
1 of 3 checks passed
continuous-integration/travis-ci/pr The Travis CI build failed
Details
continuous-integration/travis-ci/push The Travis CI build failed
Details
coverage/coveralls Coverage remained the same at 1.382%
Details
@huangdan huangdan added this to the 3.0-beta.3 milestone Sep 23, 2018
@emqplus emqplus deleted the shutdown-policy branch Nov 30, 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.