)]}'
{"ceilometer/compute/pollsters/cpu.py":[{"author":{"_account_id":4491,"name":"Lianhao Lu","email":"llh_misc@outlook.com","username":"lianhao-lu"},"change_message_id":"ece119951040ccff9add964135b35628ed94b66e","unresolved":false,"context_lines":[{"line_number":121,"context_line":"                             \u0027%(instance_id)s, non-fatal reason: %(exc)s\u0027),"},{"line_number":122,"context_line":"                            {\u0027pollster\u0027: self.__class__.__name__,"},{"line_number":123,"context_line":"                             \u0027instance_id\u0027: instance.id, \u0027exc\u0027: e})"},{"line_number":124,"context_line":"                raise plugin_base.PollsterPermanentError(resources)"},{"line_number":125,"context_line":"            except ceilometer.NotImplementedError:"},{"line_number":126,"context_line":"                # Selected inspector does not implement this pollster."},{"line_number":127,"context_line":"                LOG.debug(\u0027Obtaining cache usage is not implemented for %s\u0027,"}],"source_content_type":"text/x-python","patch_set":7,"id":"5a9d85d2_b11c73c2","line":124,"range":{"start_line":124,"start_character":66,"end_line":124,"end_character":67},"updated":"2016-06-21 07:21:58.000000000","message":"should we","commit_id":"a2dbcaf80d8a40700a53e94f59c7639d9cf6f816"}],"ceilometer/compute/virt/libvirt/inspector.py":[{"author":{"_account_id":8358,"name":"zhangguoqing","email":"zhang.guoqing@99cloud.net","username":"zhangguoqing"},"change_message_id":"8ea58491b4ddc6578c2994c2acfb1ccd65516f3b","unresolved":false,"context_lines":[{"line_number":119,"context_line":""},{"line_number":120,"context_line":"    def inspect_cpu_l3_cache(self, instance):"},{"line_number":121,"context_line":"        domain \u003d self._lookup_by_uuid(instance)"},{"line_number":122,"context_line":"        stats \u003d self._get_connection().domainListGetStats([domain], 64)"},{"line_number":123,"context_line":"        perf \u003d stats[0][1]"},{"line_number":124,"context_line":"        cache_usage \u003d perf[\"perf.cmt\"]"},{"line_number":125,"context_line":"        return virt_inspector.CPUL3CacheUsageStats(l3_cache_usage\u003dcache_usage)"}],"source_content_type":"text/x-python","patch_set":3,"id":"7aa08908_d9d1b2cd","line":122,"range":{"start_line":122,"start_character":8,"end_line":122,"end_character":71},"updated":"2016-06-15 05:51:44.000000000","message":"The parameter 64 mean the domain perf event info that I find it difficult at http://libvirt.org/html/libvirt-libvirt-domain.html#virDomainStatsTypes.\n\nSo, adding the line like \"VIR_DOMAIN_STATS_PERF \u003d 64\" at the above or some comments are better for reviewer. What do you think about?  Thank you.:)\n\n\nNOTE:\nenum virDomainStatsTypes {\nVIR_DOMAIN_STATS_STATE\t\u003d\t1\t\nreturn domain state\nVIR_DOMAIN_STATS_CPU_TOTAL\t\u003d\t2\t\nreturn domain CPU info\nVIR_DOMAIN_STATS_BALLOON\t\u003d\t4\t\nreturn domain balloon info\nVIR_DOMAIN_STATS_VCPU\t\u003d\t8\t\nreturn domain virtual CPU info\nVIR_DOMAIN_STATS_INTERFACE\t\u003d\t16\t\nreturn domain interfaces info\nVIR_DOMAIN_STATS_BLOCK\t\u003d\t32\t\nreturn domain block info\nVIR_DOMAIN_STATS_PERF\t\u003d\t64\t\nreturn domain perf event info\n}\n\n\n(Pdb) libvirt.VIR_DOMAIN_STATS_STATE\n1\n(Pdb) libvirt.VIR_DOMAIN_STATS_CPU_TOTAL\n2\n(Pdb) libvirt.VIR_DOMAIN_STATS_BALLOON\n4\n(Pdb) libvirt.VIR_DOMAIN_STATS_VCPU\n8\n(Pdb) libvirt.VIR_DOMAIN_STATS_INTERFACE\n16\n(Pdb) libvirt.VIR_DOMAIN_STATS_BLOCK\n32\n(Pdb) libvirt.VIR_DOMAIN_STATS_PERF\n*** AttributeError: \u0027module\u0027 object has no attribute \u0027VIR_DOMAIN_STATS_PERF\u0027\n\n\n[stack@dev ceilometer]$ pip list | grep libvirt-python\nlibvirt-python (1.3.3)\nI can not get the libvirt.VIR_DOMAIN_STATS_PERF in my test env, so it may the low version of the libvirt-python, and you should point the lowest version for cpu_l3_cache.","commit_id":"95d47b360cd05e6db6c9df77f673ce5a223697f5"},{"author":{"_account_id":4491,"name":"Lianhao Lu","email":"llh_misc@outlook.com","username":"lianhao-lu"},"change_message_id":"43655cf2b994614af9fbe788dc0c23831aedab1c","unresolved":false,"context_lines":[{"line_number":119,"context_line":""},{"line_number":120,"context_line":"    def inspect_cpu_l3_cache(self, instance):"},{"line_number":121,"context_line":"        domain \u003d self._lookup_by_uuid(instance)"},{"line_number":122,"context_line":"        stats \u003d self._get_connection().domainListGetStats([domain], 64)"},{"line_number":123,"context_line":"        perf \u003d stats[0][1]"},{"line_number":124,"context_line":"        cache_usage \u003d perf[\"perf.cmt\"]"},{"line_number":125,"context_line":"        return virt_inspector.CPUL3CacheUsageStats(l3_cache_usage\u003dcache_usage)"}],"source_content_type":"text/x-python","patch_set":3,"id":"7aa08908_39fa7675","line":122,"range":{"start_line":122,"start_character":70,"end_line":122,"end_character":71},"updated":"2016-06-15 05:46:02.000000000","message":"what if the libvirt version is not new enough to support this feature? Can we detect that and in that case throw exception PollsterPermantError(https://github.com/openstack/ceilometer/blob/master/ceilometer/agent/plugin_base.py#L140), so the pollster won\u0027t be called repeatedly","commit_id":"95d47b360cd05e6db6c9df77f673ce5a223697f5"},{"author":{"_account_id":9581,"name":"Ren Qiaowei","email":"qiaowei.ren@intel.com","username":"qiaowei"},"change_message_id":"2f0bc08bbace0196026d175214f9045ea96f01bf","unresolved":false,"context_lines":[{"line_number":119,"context_line":""},{"line_number":120,"context_line":"    def inspect_cpu_l3_cache(self, instance):"},{"line_number":121,"context_line":"        domain \u003d self._lookup_by_uuid(instance)"},{"line_number":122,"context_line":"        stats \u003d self._get_connection().domainListGetStats([domain], 64)"},{"line_number":123,"context_line":"        perf \u003d stats[0][1]"},{"line_number":124,"context_line":"        cache_usage \u003d perf[\"perf.cmt\"]"},{"line_number":125,"context_line":"        return virt_inspector.CPUL3CacheUsageStats(l3_cache_usage\u003dcache_usage)"}],"source_content_type":"text/x-python","patch_set":3,"id":"7aa08908_864822b5","line":122,"range":{"start_line":122,"start_character":70,"end_line":122,"end_character":71},"in_reply_to":"7aa08908_39fa7675","updated":"2016-06-16 08:59:47.000000000","message":"Done","commit_id":"95d47b360cd05e6db6c9df77f673ce5a223697f5"},{"author":{"_account_id":4491,"name":"Lianhao Lu","email":"llh_misc@outlook.com","username":"lianhao-lu"},"change_message_id":"2232874554643fbd5b05ba22bc6aa454a59350b0","unresolved":false,"context_lines":[{"line_number":121,"context_line":"        domain \u003d self._lookup_by_uuid(instance)"},{"line_number":122,"context_line":"        try:"},{"line_number":123,"context_line":"            stats \u003d self.connection.domainListGetStats("},{"line_number":124,"context_line":"                [domain], libvirt.VIR_DOMAIN_STATS_PERF)"},{"line_number":125,"context_line":"            perf \u003d stats[0][1]"},{"line_number":126,"context_line":"            usage \u003d perf[\"perf.cmt\"]"},{"line_number":127,"context_line":"            return virt_inspector.CPUL3CacheUsageStats(l3_cache_usage\u003dusage)"}],"source_content_type":"text/x-python","patch_set":5,"id":"7aa08908_becb7749","line":124,"range":{"start_line":124,"start_character":55,"end_line":124,"end_character":56},"updated":"2016-06-17 01:48:08.000000000","message":"If the existence of libvirt.VIR_DOMAIN_STATS_PERF is a way to check whether this version of libvirt support l3_cache_usage date, we should catch this AttributeError and throw PollsterPermenantError. There is no meaning to running the pollster again and again when we\u0027re sure that nothing but exception will be thrown every time.","commit_id":"e3f7a3a58101f4f46db9b63f4424943d757b01ac"}],"ceilometer/tests/unit/compute/virt/libvirt/test_inspector.py":[{"author":{"_account_id":6924,"name":"Pradeep Kilambi","email":"pkilambi@redhat.com","username":"pkilambi"},"change_message_id":"fddcf69a60290c7f5aae9f0071e130cfcd7bb50b","unresolved":false,"context_lines":[{"line_number":72,"context_line":"                                  self.instance)"},{"line_number":73,"context_line":""},{"line_number":74,"context_line":"    def test_inspect_cpu_l3_cache(self):"},{"line_number":75,"context_line":"        fake_stats \u003d [({}, {\u0027perf.cmt\u0027: 90112L})]"},{"line_number":76,"context_line":"        connection \u003d self.inspector.connection"},{"line_number":77,"context_line":"        with contextlib.ExitStack() as stack:"},{"line_number":78,"context_line":"            stack.enter_context(mock.patch.object(connection,"}],"source_content_type":"text/x-python","patch_set":2,"id":"7aa08908_34898acb","line":75,"range":{"start_line":75,"start_character":40,"end_line":75,"end_character":46},"updated":"2016-06-10 14:06:32.000000000","message":"this wont work in py3","commit_id":"66bc07a355695915d87eb2f4bbae81029b385b8f"}]}
