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

Workers can run log_status so ask for the right pid #16460

Merged
merged 1 commit into from
Nov 14, 2017

Conversation

jrafanie
Copy link
Member

@jrafanie jrafanie commented Nov 13, 2017

If no argument is provided, processInfo will get the current process'
memory information, which when run from a queue worker, will not be the
server's pid.

https://bugzilla.redhat.com/show_bug.cgi?id=1519953

When run on an appliance with a bloated MiqServer process:

Before (uses the current Process's memory information):

irb(main):001:0> MiqServer.my_server.process_status
=> {:memory_usage=>148525056, :memory_size=>439468032, :percent_memory=>0.89, :cpu_time=>779, :percent_cpu=>0.0, :proportional_set_size=>139434000, :os_priority=>20}

After:

irb(main):001:0> MiqServer.my_server.process_status
=> {:memory_usage=>3902767104, :memory_size=>4303794176, :percent_memory=>23.44, :cpu_time=>15366516, :percent_cpu=>9.78, :proportional_set_size=>1431006000, :os_priority=>20}

@dmetzger57 @NickLaMuro don't trust any MiqServer.log_status log lines, they're most likely wrong.

If no argument is provided, processInfo will get the current process'
memory information, which when run from a queue worker, will not be the
server's pid.
@miq-bot
Copy link
Member

miq-bot commented Nov 13, 2017

Checked commit jrafanie@38b66e6 with ruby 2.3.3, rubocop 0.47.1, and haml-lint 0.20.0
1 file checked, 0 offenses detected
Everything looks fine. 👍

Copy link
Member

@gtanzillo gtanzillo left a comment

Choose a reason for hiding this comment

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

👍

Copy link
Member

@NickLaMuro NickLaMuro left a comment

Choose a reason for hiding this comment

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

Good catch!

@chessbyte chessbyte self-assigned this Nov 14, 2017
@chessbyte chessbyte merged commit 974e360 into ManageIQ:master Nov 14, 2017
@chessbyte chessbyte added this to the Sprint 74 Ending Nov 27, 2017 milestone Nov 14, 2017
@jrafanie jrafanie deleted the get_server_process_info branch November 27, 2017 15:05
@jrafanie
Copy link
Member Author

@miq-bot add_label gaprindashvili/yes
@miq-bot add_label euwe/yes
@miq-bot add_label fine/yes

simaishi pushed a commit that referenced this pull request Nov 29, 2017
Workers can run log_status so ask for the right pid
(cherry picked from commit 974e360)
@simaishi
Copy link
Contributor

Gaprindashvili backport details:

$ git log -1
commit 084c26523be624a44d7b45fb1a4ae1e1f5cee707
Author: Oleg Barenboim <chessbyte@gmail.com>
Date:   Tue Nov 14 17:19:34 2017 +0200

    Merge pull request #16460 from jrafanie/get_server_process_info
    
    Workers can run log_status so ask for the right pid
    (cherry picked from commit 974e36052bdf98dc46637f821db8026295759062)

@simaishi
Copy link
Contributor

simaishi commented Dec 1, 2017

@jrafanie Please add BZ link.

@jrafanie
Copy link
Member Author

jrafanie commented Dec 1, 2017

Added link above @simaishi

simaishi pushed a commit that referenced this pull request Dec 1, 2017
Workers can run log_status so ask for the right pid
(cherry picked from commit 974e360)

https://bugzilla.redhat.com/show_bug.cgi?id=1519987
@simaishi
Copy link
Contributor

simaishi commented Dec 1, 2017

Fine backport details:

$ git log -1
commit a093979fa911b8944d362e479bef5bce7072e701
Author: Oleg Barenboim <chessbyte@gmail.com>
Date:   Tue Nov 14 17:19:34 2017 +0200

    Merge pull request #16460 from jrafanie/get_server_process_info
    
    Workers can run log_status so ask for the right pid
    (cherry picked from commit 974e36052bdf98dc46637f821db8026295759062)
    
    https://bugzilla.redhat.com/show_bug.cgi?id=1519987

simaishi pushed a commit that referenced this pull request Feb 26, 2018
Workers can run log_status so ask for the right pid
(cherry picked from commit 974e360)

Fixes https://bugzilla.redhat.com/show_bug.cgi?id=1519988
@simaishi
Copy link
Contributor

Euwe backport details:

$ git log -1
commit 46b761ca782a7772ad94529a9e858251eecf20b5
Author: Oleg Barenboim <chessbyte@gmail.com>
Date:   Tue Nov 14 17:19:34 2017 +0200

    Merge pull request #16460 from jrafanie/get_server_process_info
    
    Workers can run log_status so ask for the right pid
    (cherry picked from commit 974e36052bdf98dc46637f821db8026295759062)
    
    Fixes https://bugzilla.redhat.com/show_bug.cgi?id=1519988

d-m-u pushed a commit to d-m-u/manageiq that referenced this pull request Jun 6, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

6 participants