)]}'
{"monasca_log_api/common/services.py":[{"author":{"_account_id":12200,"name":"Sebastian Kalinowski","email":"sebastian@kalinowski.eu","username":"prmtl"},"change_message_id":"91b3f8b1ccc1af9e7dec3b729ba101ea42f6d9c2","unresolved":false,"context_lines":[{"line_number":33,"context_line":"LOG \u003d log.getLogger(__name__)"},{"line_number":34,"context_line":""},{"line_number":35,"context_line":""},{"line_number":36,"context_line":"class _ServiceInfo:"},{"line_number":37,"context_line":"    def __init__(self):"},{"line_number":38,"context_line":"        pass"},{"line_number":39,"context_line":""}],"source_content_type":"text/x-python","patch_set":1,"id":"9a1a9d01_4b980a78","line":36,"updated":"2015-10-01 11:42:32.000000000","message":"Inherit from \u0027object\u0027 so it will be new style class.\n\n class _ServiceInfo(object)","commit_id":"83361a0e26cbf9ca7345532b96bf02c4f22a055a"},{"author":{"_account_id":12200,"name":"Sebastian Kalinowski","email":"sebastian@kalinowski.eu","username":"prmtl"},"change_message_id":"91b3f8b1ccc1af9e7dec3b729ba101ea42f6d9c2","unresolved":false,"context_lines":[{"line_number":34,"context_line":""},{"line_number":35,"context_line":""},{"line_number":36,"context_line":"class _ServiceInfo:"},{"line_number":37,"context_line":"    def __init__(self):"},{"line_number":38,"context_line":"        pass"},{"line_number":39,"context_line":""},{"line_number":40,"context_line":"    @property"}],"source_content_type":"text/x-python","patch_set":1,"id":"9a1a9d01_8ba94292","line":37,"updated":"2015-10-01 11:42:32.000000000","message":"Not needed.","commit_id":"83361a0e26cbf9ca7345532b96bf02c4f22a055a"},{"author":{"_account_id":12200,"name":"Sebastian Kalinowski","email":"sebastian@kalinowski.eu","username":"prmtl"},"change_message_id":"91b3f8b1ccc1af9e7dec3b729ba101ea42f6d9c2","unresolved":false,"context_lines":[{"line_number":47,"context_line":""},{"line_number":48,"context_line":"    @property"},{"line_number":49,"context_line":"    def supported_metrics(self):"},{"line_number":50,"context_line":"        return getattr(self, \u0027_metrics_name\u0027, {})"},{"line_number":51,"context_line":""},{"line_number":52,"context_line":"    def is_valid_dimension_name(self, dimension):"},{"line_number":53,"context_line":"        return dimension in self.supported_dimensions"}],"source_content_type":"text/x-python","patch_set":1,"id":"9a1a9d01_cb7bbaf3","line":50,"updated":"2015-10-01 11:42:32.000000000","message":"Maybe instead of calling getattr on this class, just make them class attributes like in child classes?\n\n class _ServiceInfo(object):\n    supported_metrics \u003d {}\n    supported_dimensions \u003d {}\n    ...","commit_id":"83361a0e26cbf9ca7345532b96bf02c4f22a055a"},{"author":{"_account_id":12200,"name":"Sebastian Kalinowski","email":"sebastian@kalinowski.eu","username":"prmtl"},"change_message_id":"91b3f8b1ccc1af9e7dec3b729ba101ea42f6d9c2","unresolved":false,"context_lines":[{"line_number":53,"context_line":"        return dimension in self.supported_dimensions"},{"line_number":54,"context_line":""},{"line_number":55,"context_line":"    def is_valid_dimension(self, name, value):"},{"line_number":56,"context_line":"        raise NotImplementedError"},{"line_number":57,"context_line":""},{"line_number":58,"context_line":"    def is_valid_metric_name(self, metric):"},{"line_number":59,"context_line":"        return metric in self.supported_metrics"}],"source_content_type":"text/x-python","patch_set":1,"id":"9a1a9d01_0b4d32c3","line":56,"updated":"2015-10-01 11:42:32.000000000","message":"Maybe make it an absctractmethod?","commit_id":"83361a0e26cbf9ca7345532b96bf02c4f22a055a"},{"author":{"_account_id":12200,"name":"Sebastian Kalinowski","email":"sebastian@kalinowski.eu","username":"prmtl"},"change_message_id":"91b3f8b1ccc1af9e7dec3b729ba101ea42f6d9c2","unresolved":false,"context_lines":[{"line_number":130,"context_line":"    _resource_id_dim \u003d \u0027container\u0027"},{"line_number":131,"context_line":""},{"line_number":132,"context_line":"    def __init__(self):"},{"line_number":133,"context_line":"        LOG.info(\u0027Initializing ObjectStoreServiceInfo\u0027)"},{"line_number":134,"context_line":"        _ServiceInfo.__init__(self)"},{"line_number":135,"context_line":""},{"line_number":136,"context_line":"    def is_valid_dimension(self, name, value):"}],"source_content_type":"text/x-python","patch_set":1,"id":"9a1a9d01_8bae227f","line":133,"updated":"2015-10-01 11:42:32.000000000","message":"You can move it to _ServiceInfo __init__ like:\n\n def __init__(self):\n   LOG.info(\u0027Initializing %s\u0027, cls.__class__)","commit_id":"83361a0e26cbf9ca7345532b96bf02c4f22a055a"},{"author":{"_account_id":2419,"name":"Roland Hochmuth","email":"roland.hochmuth@hpe.com","username":"roland-hochmuth-s"},"change_message_id":"ae094fd11a3ba55dc4ba01722e0a957eaa196eed","unresolved":false,"context_lines":[{"line_number":23,"context_line":""},{"line_number":24,"context_line":"COMPUTE_SERVICE \u003d \u0027hpcs.compute\u0027"},{"line_number":25,"context_line":"VOLUME_SERVICE \u003d \u0027hpcs.volume\u0027"},{"line_number":26,"context_line":"OBJECT_STORE_SERVICE \u003d \u0027hpcs.object-store\u0027"},{"line_number":27,"context_line":""},{"line_number":28,"context_line":"SERVICE_DIMENSION \u003d \u0027service\u0027"},{"line_number":29,"context_line":"RESERVED_SERVICE_PREFIX \u003d \u0027hpcs.\u0027"}],"source_content_type":"text/x-python","patch_set":2,"id":"7a2fa921_0a108000","line":26,"updated":"2015-10-07 03:53:13.000000000","message":"Should delete these variables. This is old deprecated stuff from HP.","commit_id":"4679d46ad345418c658be3f3006a4886d0dee9a1"},{"author":{"_account_id":16168,"name":"Tomasz Trębski","email":"kornicameister@gmail.com","username":"trebskit"},"change_message_id":"974d32745b6f58284e07932c81ffa3418653572a","unresolved":false,"context_lines":[{"line_number":23,"context_line":""},{"line_number":24,"context_line":"COMPUTE_SERVICE \u003d \u0027hpcs.compute\u0027"},{"line_number":25,"context_line":"VOLUME_SERVICE \u003d \u0027hpcs.volume\u0027"},{"line_number":26,"context_line":"OBJECT_STORE_SERVICE \u003d \u0027hpcs.object-store\u0027"},{"line_number":27,"context_line":""},{"line_number":28,"context_line":"SERVICE_DIMENSION \u003d \u0027service\u0027"},{"line_number":29,"context_line":"RESERVED_SERVICE_PREFIX \u003d \u0027hpcs.\u0027"}],"source_content_type":"text/x-python","patch_set":2,"id":"7a2fa921_15d42045","line":26,"in_reply_to":"7a2fa921_0a108000","updated":"2015-10-07 08:46:35.000000000","message":"Ok, good to know. Along with removing those lines I believe the classes with metrics and dimensions like ComputeServiceInfo correlated with COMPUTE_SERVICE will be dropped. No point having them without these constants.","commit_id":"4679d46ad345418c658be3f3006a4886d0dee9a1"},{"author":{"_account_id":2419,"name":"Roland Hochmuth","email":"roland.hochmuth@hpe.com","username":"roland-hochmuth-s"},"change_message_id":"ae094fd11a3ba55dc4ba01722e0a957eaa196eed","unresolved":false,"context_lines":[{"line_number":26,"context_line":"OBJECT_STORE_SERVICE \u003d \u0027hpcs.object-store\u0027"},{"line_number":27,"context_line":""},{"line_number":28,"context_line":"SERVICE_DIMENSION \u003d \u0027service\u0027"},{"line_number":29,"context_line":"RESERVED_SERVICE_PREFIX \u003d \u0027hpcs.\u0027"},{"line_number":30,"context_line":""},{"line_number":31,"context_line":"_UUID_PATTERN \u003d re.compile(\u0027\\\\w{8}-\\\\w{4}-\\\\w{4}-\\\\w{4}-\\\\w{12}\u0027)"},{"line_number":32,"context_line":""}],"source_content_type":"text/x-python","patch_set":2,"id":"7a2fa921_eaf504cb","line":29,"updated":"2015-10-07 03:53:13.000000000","message":"These too. hpcs. stood for hp cloud services, but that is no longer required.","commit_id":"4679d46ad345418c658be3f3006a4886d0dee9a1"},{"author":{"_account_id":16168,"name":"Tomasz Trębski","email":"kornicameister@gmail.com","username":"trebskit"},"change_message_id":"974d32745b6f58284e07932c81ffa3418653572a","unresolved":false,"context_lines":[{"line_number":26,"context_line":"OBJECT_STORE_SERVICE \u003d \u0027hpcs.object-store\u0027"},{"line_number":27,"context_line":""},{"line_number":28,"context_line":"SERVICE_DIMENSION \u003d \u0027service\u0027"},{"line_number":29,"context_line":"RESERVED_SERVICE_PREFIX \u003d \u0027hpcs.\u0027"},{"line_number":30,"context_line":""},{"line_number":31,"context_line":"_UUID_PATTERN \u003d re.compile(\u0027\\\\w{8}-\\\\w{4}-\\\\w{4}-\\\\w{4}-\\\\w{12}\u0027)"},{"line_number":32,"context_line":""}],"source_content_type":"text/x-python","patch_set":2,"id":"7a2fa921_75c5548c","line":29,"in_reply_to":"7a2fa921_eaf504cb","updated":"2015-10-07 08:46:35.000000000","message":"Ok, I will have it removed.","commit_id":"4679d46ad345418c658be3f3006a4886d0dee9a1"},{"author":{"_account_id":2419,"name":"Roland Hochmuth","email":"roland.hochmuth@hpe.com","username":"roland-hochmuth-s"},"change_message_id":"ae094fd11a3ba55dc4ba01722e0a957eaa196eed","unresolved":false,"context_lines":[{"line_number":34,"context_line":""},{"line_number":35,"context_line":""},{"line_number":36,"context_line":"@six.add_metaclass(abc.ABCMeta)"},{"line_number":37,"context_line":"class _ServiceInfo(object):"},{"line_number":38,"context_line":""},{"line_number":39,"context_line":"    def __init__(self):"},{"line_number":40,"context_line":"        LOG.info(\u0027Initializing %s\u0027, self.__class__.__name__)"}],"source_content_type":"text/x-python","patch_set":2,"id":"7a2fa921_aa162cef","line":37,"updated":"2015-10-07 03:53:13.000000000","message":"Was just wondering why you were using the \"_\" prefix. I\u0027m assuming to somehow tag as private or internal?","commit_id":"4679d46ad345418c658be3f3006a4886d0dee9a1"},{"author":{"_account_id":16168,"name":"Tomasz Trębski","email":"kornicameister@gmail.com","username":"trebskit"},"change_message_id":"974d32745b6f58284e07932c81ffa3418653572a","unresolved":false,"context_lines":[{"line_number":34,"context_line":""},{"line_number":35,"context_line":""},{"line_number":36,"context_line":"@six.add_metaclass(abc.ABCMeta)"},{"line_number":37,"context_line":"class _ServiceInfo(object):"},{"line_number":38,"context_line":""},{"line_number":39,"context_line":"    def __init__(self):"},{"line_number":40,"context_line":"        LOG.info(\u0027Initializing %s\u0027, self.__class__.__name__)"}],"source_content_type":"text/x-python","patch_set":2,"id":"7a2fa921_75b0f443","line":37,"in_reply_to":"7a2fa921_aa162cef","updated":"2015-10-07 08:46:35.000000000","message":"Yes, that\u0027s purely to indicate privateness.","commit_id":"4679d46ad345418c658be3f3006a4886d0dee9a1"},{"author":{"_account_id":2419,"name":"Roland Hochmuth","email":"roland.hochmuth@hpe.com","username":"roland-hochmuth-s"},"change_message_id":"ae094fd11a3ba55dc4ba01722e0a957eaa196eed","unresolved":false,"context_lines":[{"line_number":59,"context_line":"        return dimension in self.supported_dimensions"},{"line_number":60,"context_line":""},{"line_number":61,"context_line":"    def is_valid_metric_name(self, metric):"},{"line_number":62,"context_line":"        return metric in self.supported_metrics"},{"line_number":63,"context_line":""},{"line_number":64,"context_line":""},{"line_number":65,"context_line":"class ComputeServiceInfo(_ServiceInfo):"}],"source_content_type":"text/x-python","patch_set":2,"id":"7a2fa921_4abbd8e5","line":62,"updated":"2015-10-07 03:53:13.000000000","message":"Was wondering if you will really want methods like is_valid_dimension, and is_valid_metric_name, to be member methods, rather than in an external class for validation of these value object, that could potentially be used by other classes, without requiring inheritance.","commit_id":"4679d46ad345418c658be3f3006a4886d0dee9a1"},{"author":{"_account_id":16168,"name":"Tomasz Trębski","email":"kornicameister@gmail.com","username":"trebskit"},"change_message_id":"974d32745b6f58284e07932c81ffa3418653572a","unresolved":false,"context_lines":[{"line_number":59,"context_line":"        return dimension in self.supported_dimensions"},{"line_number":60,"context_line":""},{"line_number":61,"context_line":"    def is_valid_metric_name(self, metric):"},{"line_number":62,"context_line":"        return metric in self.supported_metrics"},{"line_number":63,"context_line":""},{"line_number":64,"context_line":""},{"line_number":65,"context_line":"class ComputeServiceInfo(_ServiceInfo):"}],"source_content_type":"text/x-python","patch_set":2,"id":"7a2fa921_b5a52c05","line":62,"in_reply_to":"7a2fa921_4abbd8e5","updated":"2015-10-07 08:46:35.000000000","message":"That\u0027s good catch. Will be done.","commit_id":"4679d46ad345418c658be3f3006a4886d0dee9a1"},{"author":{"_account_id":2419,"name":"Roland Hochmuth","email":"roland.hochmuth@hpe.com","username":"roland-hochmuth-s"},"change_message_id":"ae094fd11a3ba55dc4ba01722e0a957eaa196eed","unresolved":false,"context_lines":[{"line_number":139,"context_line":"}"},{"line_number":140,"context_line":""},{"line_number":141,"context_line":""},{"line_number":142,"context_line":"class Services(object):"},{"line_number":143,"context_line":""},{"line_number":144,"context_line":"    @staticmethod"},{"line_number":145,"context_line":"    def get_resource_id_dimension(service):"}],"source_content_type":"text/x-python","patch_set":2,"id":"7a2fa921_eacae46d","line":142,"updated":"2015-10-07 03:53:13.000000000","message":"After reviewing this class, I\u0027m just wondering what the intended purpose of it was. Do we really need this class anymore???","commit_id":"4679d46ad345418c658be3f3006a4886d0dee9a1"},{"author":{"_account_id":16168,"name":"Tomasz Trębski","email":"kornicameister@gmail.com","username":"trebskit"},"change_message_id":"974d32745b6f58284e07932c81ffa3418653572a","unresolved":false,"context_lines":[{"line_number":139,"context_line":"}"},{"line_number":140,"context_line":""},{"line_number":141,"context_line":""},{"line_number":142,"context_line":"class Services(object):"},{"line_number":143,"context_line":""},{"line_number":144,"context_line":"    @staticmethod"},{"line_number":145,"context_line":"    def get_resource_id_dimension(service):"}],"source_content_type":"text/x-python","patch_set":2,"id":"7a2fa921_354cbc6f","line":142,"in_reply_to":"7a2fa921_eacae46d","updated":"2015-10-07 08:46:35.000000000","message":"I am not quire sure. Before I\u0027ve told that I had to port something from monasca-common [java] because it is used in java version for monasca-api, but I couldn\u0027t find that in python version of monasca-common.\n\nI guess I have to review it and decide what is actually needed here. I did not bother that before because I\u0027ve focused on different parts. After I confirm what is required I will upload next patch set. However it looks like when I remove constants you mentioned above that will be actually no need for this module.","commit_id":"4679d46ad345418c658be3f3006a4886d0dee9a1"}],"monasca_log_api/config.py":[{"author":{"_account_id":2419,"name":"Roland Hochmuth","email":"roland.hochmuth@hpe.com","username":"roland-hochmuth-s"},"change_message_id":"ae094fd11a3ba55dc4ba01722e0a957eaa196eed","unresolved":false,"context_lines":[{"line_number":15,"context_line":""},{"line_number":16,"context_line":"from kafka import conn"},{"line_number":17,"context_line":"from oslo_config import cfg"},{"line_number":18,"context_line":""},{"line_number":19,"context_line":""},{"line_number":20,"context_line":"def get_dispatcher_opts():"},{"line_number":21,"context_line":"    opts \u003d ["}],"source_content_type":"text/x-python","patch_set":2,"id":"7a2fa921_8a77b039","line":18,"updated":"2015-10-07 03:53:13.000000000","message":"I think is OK for now, but we\u0027ll probably want to re-factor how we handle opts. The pattern that I\u0027ve seen being used in other OpenStack projects is to have a opts class for each class or module, declared in a directory for the capability. For example, we\u0027ll eventually have a kafka directory in monasca-common. Within that directory, we\u0027ll have a file potentially producer.py, and one for opts like\n\nmonaca-common/monasca_common/\n    kafka\n        opts.py\n        producer.py\n        consumer.py","commit_id":"4679d46ad345418c658be3f3006a4886d0dee9a1"},{"author":{"_account_id":16168,"name":"Tomasz Trębski","email":"kornicameister@gmail.com","username":"trebskit"},"change_message_id":"974d32745b6f58284e07932c81ffa3418653572a","unresolved":false,"context_lines":[{"line_number":15,"context_line":""},{"line_number":16,"context_line":"from kafka import conn"},{"line_number":17,"context_line":"from oslo_config import cfg"},{"line_number":18,"context_line":""},{"line_number":19,"context_line":""},{"line_number":20,"context_line":"def get_dispatcher_opts():"},{"line_number":21,"context_line":"    opts \u003d ["}],"source_content_type":"text/x-python","patch_set":2,"id":"7a2fa921_95f590cc","line":18,"in_reply_to":"7a2fa921_8a77b039","updated":"2015-10-07 08:46:35.000000000","message":"Yeah, I was torn apart between putting them in modules or in central place. Central place seemed like a nice idea some time ago, but now I see its flaw and I will take care of refactoring it ASAP.","commit_id":"4679d46ad345418c658be3f3006a4886d0dee9a1"}],"monasca_log_api/publisher/exceptions.py":[{"author":{"_account_id":2419,"name":"Roland Hochmuth","email":"roland.hochmuth@hpe.com","username":"roland-hochmuth-s"},"change_message_id":"ae094fd11a3ba55dc4ba01722e0a957eaa196eed","unresolved":false,"context_lines":[{"line_number":14,"context_line":"# under the License."},{"line_number":15,"context_line":""},{"line_number":16,"context_line":""},{"line_number":17,"context_line":"class WrappingException(Exception):"},{"line_number":18,"context_line":"    def __init__(self, message, caught\u003dNone):"},{"line_number":19,"context_line":"        self._message \u003d message"},{"line_number":20,"context_line":"        self._caught \u003d caught"}],"source_content_type":"text/x-python","patch_set":2,"id":"7a2fa921_ea9f444e","line":17,"updated":"2015-10-07 03:53:13.000000000","message":"Would prefer ExceptionWrapper as the class name.","commit_id":"4679d46ad345418c658be3f3006a4886d0dee9a1"},{"author":{"_account_id":16168,"name":"Tomasz Trębski","email":"kornicameister@gmail.com","username":"trebskit"},"change_message_id":"974d32745b6f58284e07932c81ffa3418653572a","unresolved":false,"context_lines":[{"line_number":14,"context_line":"# under the License."},{"line_number":15,"context_line":""},{"line_number":16,"context_line":""},{"line_number":17,"context_line":"class WrappingException(Exception):"},{"line_number":18,"context_line":"    def __init__(self, message, caught\u003dNone):"},{"line_number":19,"context_line":"        self._message \u003d message"},{"line_number":20,"context_line":"        self._caught \u003d caught"}],"source_content_type":"text/x-python","patch_set":2,"id":"7a2fa921_3504bcbe","line":17,"in_reply_to":"7a2fa921_ea9f444e","updated":"2015-10-07 08:46:35.000000000","message":"Done","commit_id":"4679d46ad345418c658be3f3006a4886d0dee9a1"}]}
