)]}'
{"/COMMIT_MSG":[{"author":{"_account_id":16222,"name":"witek","email":"witold.bedyk@suse.com","username":"witek"},"change_message_id":"4892590e1a694a448e487a473c06b88226b0b3e7","unresolved":false,"context_lines":[{"line_number":6,"context_line":""},{"line_number":7,"context_line":"Add debug output for libvirt ping checks"},{"line_number":8,"context_line":""},{"line_number":9,"context_line":"This patch adds some extra debug options to the ping check. It uses"},{"line_number":10,"context_line":"subprocess.check_output to capture the data from the ping cmd."},{"line_number":11,"context_line":"This extra check is only run when the log_level is set to DEBUG."},{"line_number":12,"context_line":"In order for the libvirt pluging to access the full set of \"config\""},{"line_number":13,"context_line":"values in agent.yml, the agent_config dict was changed to include"},{"line_number":14,"context_line":"the \"Api\" and \"Logging\" sections."},{"line_number":15,"context_line":""},{"line_number":16,"context_line":"Change-Id: Ife9a1d409a8326fb9ff07b1b04508cd11f899d10"}],"source_content_type":"text/x-gerrit-commit-message","patch_set":1,"id":"1f493fa4_76c45f41","line":14,"range":{"start_line":9,"start_character":0,"end_line":14,"end_character":33},"updated":"2020-05-04 15:36:48.000000000","message":"Please update accordingly to the code changes.","commit_id":"ae3652fc876f300df1da9918db9e5ad16a84c632"},{"author":{"_account_id":1916,"name":"Guang Yee","email":"gyee@suse.com","username":"guang-yee"},"change_message_id":"d0c112873f06bf84029c57d51b38d48064b77466","unresolved":false,"context_lines":[{"line_number":12,"context_line":"In order for the libvirt pluging to access the full set of \"config\""},{"line_number":13,"context_line":"values in agent.yml, the agent_config dict was changed to include"},{"line_number":14,"context_line":"the \"Api\" and \"Logging\" sections."},{"line_number":15,"context_line":""},{"line_number":16,"context_line":"Change-Id: Ife9a1d409a8326fb9ff07b1b04508cd11f899d10"}],"source_content_type":"text/x-gerrit-commit-message","patch_set":1,"id":"1f493fa4_441a7b16","line":15,"updated":"2020-04-30 19:53:37.000000000","message":"Not sure if we need a bug/task reference here.","commit_id":"ae3652fc876f300df1da9918db9e5ad16a84c632"},{"author":{"_account_id":16222,"name":"witek","email":"witold.bedyk@suse.com","username":"witek"},"change_message_id":"4892590e1a694a448e487a473c06b88226b0b3e7","unresolved":false,"context_lines":[{"line_number":12,"context_line":"In order for the libvirt pluging to access the full set of \"config\""},{"line_number":13,"context_line":"values in agent.yml, the agent_config dict was changed to include"},{"line_number":14,"context_line":"the \"Api\" and \"Logging\" sections."},{"line_number":15,"context_line":""},{"line_number":16,"context_line":"Change-Id: Ife9a1d409a8326fb9ff07b1b04508cd11f899d10"}],"source_content_type":"text/x-gerrit-commit-message","patch_set":1,"id":"1f493fa4_36cad74e","line":15,"in_reply_to":"1f493fa4_441a7b16","updated":"2020-05-04 15:36:48.000000000","message":"Yes. that wouldn\u0027t hurt.\nAlso, if we fix the log level configuration we could cherry-pick it to stable branches.","commit_id":"ae3652fc876f300df1da9918db9e5ad16a84c632"}],"monasca_agent/collector/checks/check.py":[{"author":{"_account_id":14892,"name":"Keith Berger","email":"keith.berger@suse.com","username":"kberger"},"change_message_id":"7470558f69de405214c05e7c92b0541ec4bde7f8","unresolved":false,"context_lines":[{"line_number":46,"context_line":"        self.white_list \u003d init_config.get(\u0027white_list\u0027, None)"},{"line_number":47,"context_line":"        self.hostname \u003d util.get_hostname()"},{"line_number":48,"context_line":"        self.log \u003d logging.getLogger(\u0027%s.%s\u0027 % (__name__, name))"},{"line_number":49,"context_line":"        self.log.setLevel(logging.root.level)"},{"line_number":50,"context_line":"        threshold \u003d agent_config.get(\u0027recent_point_threshold\u0027, None)"},{"line_number":51,"context_line":"        tenant_id \u003d agent_config.get(\u0027global_delegated_tenant\u0027, None)"},{"line_number":52,"context_line":"        self.aggregator \u003d ("}],"source_content_type":"text/x-python","patch_set":5,"id":"1f493fa4_ec0213b4","line":49,"updated":"2020-05-07 19:59:07.000000000","message":"What do you expect the log to be. I am seeing when it is DEBUG it is \u002710\u0027. \n\n2020-05-07 19:54:48 UTC | INFO | collector | monasca_agent.collector.checks.check.ntp(check.py:49) | AgentLogLevel is: 10\n\nself.log.setLevel(logging.root.level)\nself.log.info(\"AgentLogLevel is: {}\".format(self.log.level))","commit_id":"cd0fd4e0a2266b5ee4cc4d9381fd3fdfa03d0038"},{"author":{"_account_id":16222,"name":"witek","email":"witold.bedyk@suse.com","username":"witek"},"change_message_id":"0414eb4fa346f6987c5ad00282676f9c8e5a803f","unresolved":false,"context_lines":[{"line_number":46,"context_line":"        self.white_list \u003d init_config.get(\u0027white_list\u0027, None)"},{"line_number":47,"context_line":"        self.hostname \u003d util.get_hostname()"},{"line_number":48,"context_line":"        self.log \u003d logging.getLogger(\u0027%s.%s\u0027 % (__name__, name))"},{"line_number":49,"context_line":"        self.log.setLevel(logging.root.level)"},{"line_number":50,"context_line":"        threshold \u003d agent_config.get(\u0027recent_point_threshold\u0027, None)"},{"line_number":51,"context_line":"        tenant_id \u003d agent_config.get(\u0027global_delegated_tenant\u0027, None)"},{"line_number":52,"context_line":"        self.aggregator \u003d ("}],"source_content_type":"text/x-python","patch_set":5,"id":"1f493fa4_09d487bc","line":49,"in_reply_to":"1f493fa4_ec0213b4","updated":"2020-05-08 10:57:52.000000000","message":"That\u0027s correct.\nhttps://docs.python.org/3/library/logging.html#levels","commit_id":"cd0fd4e0a2266b5ee4cc4d9381fd3fdfa03d0038"}],"monasca_agent/collector/checks_d/libvirt.py":[{"author":{"_account_id":16222,"name":"witek","email":"witold.bedyk@suse.com","username":"witek"},"change_message_id":"985287b960692d0a3abecf6178eb94b22a193d49","unresolved":false,"context_lines":[{"line_number":80,"context_line":"        self.metric_cache_file \u003d \"{0}/{1}\".format(self.init_config.get(\u0027cache_dir\u0027),"},{"line_number":81,"context_line":"                                                  \u0027libvirt_metrics.json\u0027)"},{"line_number":82,"context_line":"        self.use_bits \u003d self.init_config.get(\u0027network_use_bits\u0027)"},{"line_number":83,"context_line":"        self.log_level \u003d str(agent_config.get(\u0027log_level\u0027)).lower()"},{"line_number":84,"context_line":""},{"line_number":85,"context_line":"        self._collect_intervals \u003d {}"},{"line_number":86,"context_line":"        self._host_aggregate \u003d None"}],"source_content_type":"text/x-python","patch_set":1,"id":"1f493fa4_c5586957","line":83,"updated":"2020-04-30 09:24:31.000000000","message":"I\u0027d rather configure the logger correctly in AgentCheck constructor [1] and add a line:\n  \n from monasca_agent.collector import daemon\n\n self.log.setLevel(daemon.log.level)\n\nThis way all the checks will get proper log level configuration. Not tested though.\n\n[1] https://opendev.org/openstack/monasca-agent/src/branch/master/monasca_agent/collector/checks/check.py#L48","commit_id":"ae3652fc876f300df1da9918db9e5ad16a84c632"},{"author":{"_account_id":16222,"name":"witek","email":"witold.bedyk@suse.com","username":"witek"},"change_message_id":"985287b960692d0a3abecf6178eb94b22a193d49","unresolved":false,"context_lines":[{"line_number":715,"context_line":"        dims_customer_ip[\u0027ip\u0027] \u003d net[\u0027ip\u0027]"},{"line_number":716,"context_line":"        dims_operations_ip[\u0027ip\u0027] \u003d net[\u0027ip\u0027]"},{"line_number":717,"context_line":"        with open(os.devnull, \"w\") as fnull:"},{"line_number":718,"context_line":"            if self.log_level \u003d\u003d \u0027debug\u0027:"},{"line_number":719,"context_line":"                try:"},{"line_number":720,"context_line":"                    output \u003d subprocess.check_output(ping_cmd, stderr\u003dsubprocess.STDOUT)"},{"line_number":721,"context_line":"                    self.log.debug(\"Output from ping command is: {}\".format(output))"}],"source_content_type":"text/x-python","patch_set":1,"id":"1f493fa4_402447af","line":718,"updated":"2020-04-30 09:24:31.000000000","message":"Here we can check then:\n\n self.log.level \u003d\u003d logging.DEBUG","commit_id":"ae3652fc876f300df1da9918db9e5ad16a84c632"},{"author":{"_account_id":16222,"name":"witek","email":"witold.bedyk@suse.com","username":"witek"},"change_message_id":"985287b960692d0a3abecf6178eb94b22a193d49","unresolved":false,"context_lines":[{"line_number":728,"context_line":"                                      stderr\u003dfnull)"},{"line_number":729,"context_line":"                tenant_id \u003d instance_cache.get(inst_name)[\u0027tenant_id\u0027]"},{"line_number":730,"context_line":"                hostname \u003d instance_cache.get(inst_name)[\u0027hostname\u0027]"},{"line_number":731,"context_line":"                self.log.debug(\"Metric value of ping check {0} is: {1}\".format"},{"line_number":732,"context_line":"                               (\u0027 \u0027.join(ping_cmd), res))"},{"line_number":733,"context_line":"                return (res, dims_customer_ip, dims_operations_ip, tenant_id,"},{"line_number":734,"context_line":"                        hostname)"}],"source_content_type":"text/x-python","patch_set":1,"id":"1f493fa4_a06c2bce","line":731,"updated":"2020-04-30 09:24:31.000000000","message":"Please note that now it will be logged independently of configured log_level because of wrongly initialized logger. Currently we have `self.log.level \u003d 0`","commit_id":"ae3652fc876f300df1da9918db9e5ad16a84c632"}],"monasca_agent/common/util.py":[{"author":{"_account_id":16222,"name":"witek","email":"witold.bedyk@suse.com","username":"witek"},"change_message_id":"985287b960692d0a3abecf6178eb94b22a193d49","unresolved":false,"context_lines":[],"source_content_type":"","patch_set":1,"id":"1f493fa4_2d5da246","updated":"2020-04-30 09:24:31.000000000","message":"All the changes in this module are not needed. Please revert.","commit_id":"ae3652fc876f300df1da9918db9e5ad16a84c632"}]}
