)]}'
{"monasca_agent/collector/checks_d/http_check.py":[{"author":{"_account_id":15027,"name":"Michael Hoppal","email":"michael.jam.hoppal@hpe.com","username":"michael-hoppal"},"change_message_id":"26d589e66378192b97270de468e31d3b91a22eba","unresolved":false,"context_lines":[{"line_number":77,"context_line":"        global response_not_ready"},{"line_number":78,"context_line":"        global general_exception"},{"line_number":79,"context_line":"        global invalid_token"},{"line_number":80,"context_line":"        global warning_msg"},{"line_number":81,"context_line":""},{"line_number":82,"context_line":"        addr, username, password, timeout, headers, response_time, \\"},{"line_number":83,"context_line":"            disable_ssl_validation, use_keystone, keystone_config, \\"}],"source_content_type":"text/x-python","patch_set":1,"id":"9abb7d3a_c4b9257b","line":80,"range":{"start_line":80,"start_character":15,"end_line":80,"end_character":26},"updated":"2016-05-31 16:26:26.000000000","message":"should we just not log at all? We are reporting a down metric when we get an error back. Could we throw the error message in the value meta instead? \n\nWhat do you think is better?","commit_id":"b256b6f4fce757a0de707ba69b20a560434603fe"},{"author":{"_account_id":18179,"name":"Kaiyan Sheng","email":"kaiyan.sheng@hpe.com","username":"kaiyan-sheng"},"change_message_id":"28df594b48f6af6ae4854858c09e25bb8100b109","unresolved":false,"context_lines":[{"line_number":77,"context_line":"        global response_not_ready"},{"line_number":78,"context_line":"        global general_exception"},{"line_number":79,"context_line":"        global invalid_token"},{"line_number":80,"context_line":"        global warning_msg"},{"line_number":81,"context_line":""},{"line_number":82,"context_line":"        addr, username, password, timeout, headers, response_time, \\"},{"line_number":83,"context_line":"            disable_ssl_validation, use_keystone, keystone_config, \\"}],"source_content_type":"text/x-python","patch_set":1,"id":"9abb7d3a_bf44e81a","line":80,"range":{"start_line":80,"start_character":15,"end_line":80,"end_character":26},"in_reply_to":"9abb7d3a_c4b9257b","updated":"2016-05-31 16:30:36.000000000","message":"Hmm if people used to go into the log to find error messages then I think making these error messages to show up once is good.","commit_id":"b256b6f4fce757a0de707ba69b20a560434603fe"},{"author":{"_account_id":15027,"name":"Michael Hoppal","email":"michael.jam.hoppal@hpe.com","username":"michael-hoppal"},"change_message_id":"d17b121a082336f29bd61ece0084eaf5cec0039e","unresolved":false,"context_lines":[{"line_number":176,"context_line":"        if not success:"},{"line_number":177,"context_line":"            self.gauge(\u0027http_status\u0027,"},{"line_number":178,"context_line":"                       1,"},{"line_number":179,"context_line":"                       dimensions\u003ddimensions)"},{"line_number":180,"context_line":"            return services_checks.Status.DOWN, result_string"},{"line_number":181,"context_line":""},{"line_number":182,"context_line":"        if pattern is not None:"}],"source_content_type":"text/x-python","patch_set":2,"id":"9abb7d3a_f86bf382","line":179,"range":{"start_line":179,"start_character":34,"end_line":179,"end_character":44},"updated":"2016-06-01 14:24:43.000000000","message":"lets add error message as a value meta here","commit_id":"bc459b699606da1cdc0865ac7e75edda3672b971"},{"author":{"_account_id":2419,"name":"Roland Hochmuth","email":"roland.hochmuth@hpe.com","username":"roland-hochmuth-s"},"change_message_id":"2f2b9db642e3a7b7e30c7e0b148415b13d390c97","unresolved":false,"context_lines":[{"line_number":22,"context_line":"response_not_ready \u003d set()"},{"line_number":23,"context_line":"general_exception \u003d set()"},{"line_number":24,"context_line":"invalid_token \u003d set()"},{"line_number":25,"context_line":"warning_msg \u003d set()"},{"line_number":26,"context_line":""},{"line_number":27,"context_line":""},{"line_number":28,"context_line":"class HTTPCheck(services_checks.ServicesCheck):"}],"source_content_type":"text/x-python","patch_set":3,"id":"1aa78d24_4bb7eff4","line":25,"range":{"start_line":25,"start_character":0,"end_line":25,"end_character":11},"updated":"2016-07-06 18:35:18.000000000","message":"Was just wondering if you wanted to make all the global variables listed above private members of the class HTTPCheck?","commit_id":"016eee1aa7192fde22efdebdf435969679e18ea1"},{"author":{"_account_id":18179,"name":"Kaiyan Sheng","email":"kaiyan.sheng@hpe.com","username":"kaiyan-sheng"},"change_message_id":"bf7945fde1726ac744849fc70ffb70da73ccba8f","unresolved":false,"context_lines":[{"line_number":22,"context_line":"response_not_ready \u003d set()"},{"line_number":23,"context_line":"general_exception \u003d set()"},{"line_number":24,"context_line":"invalid_token \u003d set()"},{"line_number":25,"context_line":"warning_msg \u003d set()"},{"line_number":26,"context_line":""},{"line_number":27,"context_line":""},{"line_number":28,"context_line":"class HTTPCheck(services_checks.ServicesCheck):"}],"source_content_type":"text/x-python","patch_set":3,"id":"1aa78d24_b3e08597","line":25,"range":{"start_line":25,"start_character":0,"end_line":25,"end_character":11},"in_reply_to":"1aa78d24_4bb7eff4","updated":"2016-07-06 20:16:42.000000000","message":"Yes hmm is that ok?","commit_id":"016eee1aa7192fde22efdebdf435969679e18ea1"},{"author":{"_account_id":14273,"name":"Joe Keen","email":"joe.keen@hpe.com","username":"jkeen"},"change_message_id":"548a515c4bac21b82304a465115b121ec3b94e44","unresolved":false,"context_lines":[{"line_number":22,"context_line":"response_not_ready \u003d set()"},{"line_number":23,"context_line":"general_exception \u003d set()"},{"line_number":24,"context_line":"invalid_token \u003d set()"},{"line_number":25,"context_line":"warning_msg \u003d set()"},{"line_number":26,"context_line":""},{"line_number":27,"context_line":""},{"line_number":28,"context_line":"class HTTPCheck(services_checks.ServicesCheck):"}],"source_content_type":"text/x-python","patch_set":3,"id":"1aa78d24_ce9128f3","line":25,"range":{"start_line":25,"start_character":0,"end_line":25,"end_character":11},"in_reply_to":"1aa78d24_930e2939","updated":"2016-07-06 20:36:37.000000000","message":"There\u0027s also https://review.openstack.org/#/c/301339/3/monasca_agent/collector/checks_d/disk.py where we did put it inside the class.  We\u0027re very consistent.","commit_id":"016eee1aa7192fde22efdebdf435969679e18ea1"},{"author":{"_account_id":14273,"name":"Joe Keen","email":"joe.keen@hpe.com","username":"jkeen"},"change_message_id":"b556a7c4edcd444b8b09f27fb8fa4445a55afda9","unresolved":false,"context_lines":[{"line_number":22,"context_line":"response_not_ready \u003d set()"},{"line_number":23,"context_line":"general_exception \u003d set()"},{"line_number":24,"context_line":"invalid_token \u003d set()"},{"line_number":25,"context_line":"warning_msg \u003d set()"},{"line_number":26,"context_line":""},{"line_number":27,"context_line":""},{"line_number":28,"context_line":"class HTTPCheck(services_checks.ServicesCheck):"}],"source_content_type":"text/x-python","patch_set":3,"id":"1aa78d24_f3696dfa","line":25,"range":{"start_line":25,"start_character":0,"end_line":25,"end_character":11},"in_reply_to":"1aa78d24_b3e08597","updated":"2016-07-06 20:19:11.000000000","message":"We haven\u0027t done that on other checks where we\u0027ve implemented the once per launch logging but I don\u0027t remember why.","commit_id":"016eee1aa7192fde22efdebdf435969679e18ea1"},{"author":{"_account_id":11809,"name":"Craig Bryant","email":"craig.bryant@hpe.com","username":"craig-bryant"},"change_message_id":"d46ef3c397c509e802557ebb656b9c1d228294e4","unresolved":false,"context_lines":[{"line_number":22,"context_line":"response_not_ready \u003d set()"},{"line_number":23,"context_line":"general_exception \u003d set()"},{"line_number":24,"context_line":"invalid_token \u003d set()"},{"line_number":25,"context_line":"warning_msg \u003d set()"},{"line_number":26,"context_line":""},{"line_number":27,"context_line":""},{"line_number":28,"context_line":"class HTTPCheck(services_checks.ServicesCheck):"}],"source_content_type":"text/x-python","patch_set":3,"id":"1aa78d24_e9c21ee8","line":25,"range":{"start_line":25,"start_character":0,"end_line":25,"end_character":11},"in_reply_to":"1aa78d24_ce9128f3","updated":"2016-07-06 20:58:56.000000000","message":"I vote for it inside the class. No need to court problems with globals","commit_id":"016eee1aa7192fde22efdebdf435969679e18ea1"},{"author":{"_account_id":18179,"name":"Kaiyan Sheng","email":"kaiyan.sheng@hpe.com","username":"kaiyan-sheng"},"change_message_id":"fae75d4f5f60b9dd0edf70dd43ba34a6fdd5caa4","unresolved":false,"context_lines":[{"line_number":22,"context_line":"response_not_ready \u003d set()"},{"line_number":23,"context_line":"general_exception \u003d set()"},{"line_number":24,"context_line":"invalid_token \u003d set()"},{"line_number":25,"context_line":"warning_msg \u003d set()"},{"line_number":26,"context_line":""},{"line_number":27,"context_line":""},{"line_number":28,"context_line":"class HTTPCheck(services_checks.ServicesCheck):"}],"source_content_type":"text/x-python","patch_set":3,"id":"1aa78d24_19a89376","line":25,"range":{"start_line":25,"start_character":0,"end_line":25,"end_character":11},"in_reply_to":"1aa78d24_e9c21ee8","updated":"2016-07-06 23:08:35.000000000","message":"Done","commit_id":"016eee1aa7192fde22efdebdf435969679e18ea1"},{"author":{"_account_id":18179,"name":"Kaiyan Sheng","email":"kaiyan.sheng@hpe.com","username":"kaiyan-sheng"},"change_message_id":"c85f2752edb8bd3a91276fd3397183f7a289e682","unresolved":false,"context_lines":[{"line_number":22,"context_line":"response_not_ready \u003d set()"},{"line_number":23,"context_line":"general_exception \u003d set()"},{"line_number":24,"context_line":"invalid_token \u003d set()"},{"line_number":25,"context_line":"warning_msg \u003d set()"},{"line_number":26,"context_line":""},{"line_number":27,"context_line":""},{"line_number":28,"context_line":"class HTTPCheck(services_checks.ServicesCheck):"}],"source_content_type":"text/x-python","patch_set":3,"id":"1aa78d24_930e2939","line":25,"range":{"start_line":25,"start_character":0,"end_line":25,"end_character":11},"in_reply_to":"1aa78d24_f3696dfa","updated":"2016-07-06 20:21:20.000000000","message":"https://review.openstack.org/#/c/296036/3/monasca_agent/collector/checks_d/directory.py is this the one you are talking about?","commit_id":"016eee1aa7192fde22efdebdf435969679e18ea1"},{"author":{"_account_id":11809,"name":"Craig Bryant","email":"craig.bryant@hpe.com","username":"craig-bryant"},"change_message_id":"d46ef3c397c509e802557ebb656b9c1d228294e4","unresolved":false,"context_lines":[{"line_number":114,"context_line":"                length \u003d int((time.time() - start) * 1000)"},{"line_number":115,"context_line":"                warn_string \u003d \u0027{0} is DOWN, error: {1}. Connection failed\u0027 \\"},{"line_number":116,"context_line":"                              \u0027after {2} ms\u0027.format(addr, repr(e), length)"},{"line_number":117,"context_line":"                if addr not in socket_errors:"},{"line_number":118,"context_line":"                    socket_errors.add(addr)"},{"line_number":119,"context_line":"                    self.log.warn(warn_string)"},{"line_number":120,"context_line":"                return False, warn_string"},{"line_number":121,"context_line":""}],"source_content_type":"text/x-python","patch_set":3,"id":"1aa78d24_240c4d3a","line":118,"range":{"start_line":117,"start_character":0,"end_line":118,"end_character":43},"updated":"2016-07-06 20:58:56.000000000","message":"My concern with all of these is in the case where the url is responding, then it fails, then it succeeds again, then it fails again. I think it would be better to see an error logged the first time it fails, either after startup or after it succeeds at least once.","commit_id":"016eee1aa7192fde22efdebdf435969679e18ea1"},{"author":{"_account_id":18179,"name":"Kaiyan Sheng","email":"kaiyan.sheng@hpe.com","username":"kaiyan-sheng"},"change_message_id":"fae75d4f5f60b9dd0edf70dd43ba34a6fdd5caa4","unresolved":false,"context_lines":[{"line_number":114,"context_line":"                length \u003d int((time.time() - start) * 1000)"},{"line_number":115,"context_line":"                warn_string \u003d \u0027{0} is DOWN, error: {1}. Connection failed\u0027 \\"},{"line_number":116,"context_line":"                              \u0027after {2} ms\u0027.format(addr, repr(e), length)"},{"line_number":117,"context_line":"                if addr not in socket_errors:"},{"line_number":118,"context_line":"                    socket_errors.add(addr)"},{"line_number":119,"context_line":"                    self.log.warn(warn_string)"},{"line_number":120,"context_line":"                return False, warn_string"},{"line_number":121,"context_line":""}],"source_content_type":"text/x-python","patch_set":3,"id":"1aa78d24_39c46f3e","line":118,"range":{"start_line":117,"start_character":0,"end_line":118,"end_character":43},"in_reply_to":"1aa78d24_240c4d3a","updated":"2016-07-06 23:08:35.000000000","message":"Agree. So if it succeeds, I will make sure that address get removed from those sets.","commit_id":"016eee1aa7192fde22efdebdf435969679e18ea1"},{"author":{"_account_id":11809,"name":"Craig Bryant","email":"craig.bryant@hpe.com","username":"craig-bryant"},"change_message_id":"d46ef3c397c509e802557ebb656b9c1d228294e4","unresolved":false,"context_lines":[{"line_number":177,"context_line":"            self.gauge(\u0027http_status\u0027,"},{"line_number":178,"context_line":"                       1,"},{"line_number":179,"context_line":"                       dimensions\u003ddimensions,"},{"line_number":180,"context_line":"                       value_meta\u003d{\u0027error\u0027: result_string[:2048]})"},{"line_number":181,"context_line":"            return services_checks.Status.DOWN, result_string"},{"line_number":182,"context_line":""},{"line_number":183,"context_line":"        if pattern is not None:"}],"source_content_type":"text/x-python","patch_set":3,"id":"1aa78d24_29eb8679","line":180,"range":{"start_line":180,"start_character":58,"end_line":180,"end_character":63},"updated":"2016-07-06 20:58:56.000000000","message":"The actual value meta validation is that the whole value_meta stored as json has a length \u003c\u003d 2048, for example {\u0027error\u0027:\u0027\u0027}. So, you also have to account for \u0027error\u0027, the opening { and closing } and the : and the single quotes. Along with any escape characters that are needed. I would cut this down to 1024 or so, so we don\u0027t clutter the database too much","commit_id":"016eee1aa7192fde22efdebdf435969679e18ea1"},{"author":{"_account_id":18179,"name":"Kaiyan Sheng","email":"kaiyan.sheng@hpe.com","username":"kaiyan-sheng"},"change_message_id":"fae75d4f5f60b9dd0edf70dd43ba34a6fdd5caa4","unresolved":false,"context_lines":[{"line_number":177,"context_line":"            self.gauge(\u0027http_status\u0027,"},{"line_number":178,"context_line":"                       1,"},{"line_number":179,"context_line":"                       dimensions\u003ddimensions,"},{"line_number":180,"context_line":"                       value_meta\u003d{\u0027error\u0027: result_string[:2048]})"},{"line_number":181,"context_line":"            return services_checks.Status.DOWN, result_string"},{"line_number":182,"context_line":""},{"line_number":183,"context_line":"        if pattern is not None:"}],"source_content_type":"text/x-python","patch_set":3,"id":"1aa78d24_56378afe","line":180,"range":{"start_line":180,"start_character":58,"end_line":180,"end_character":63},"in_reply_to":"1aa78d24_29eb8679","updated":"2016-07-06 23:08:35.000000000","message":"Done","commit_id":"016eee1aa7192fde22efdebdf435969679e18ea1"}]}
