)]}'
{"/COMMIT_MSG":[{"author":{"_account_id":4393,"name":"Dan Smith","email":"dms@danplanet.com","username":"danms"},"change_message_id":"edb56ff515c3d59dede716441f72a5afda29c363","unresolved":false,"context_lines":[{"line_number":4,"context_line":"Commit:     tanlin \u003clin.tan@intel.com\u003e"},{"line_number":5,"context_line":"CommitDate: 2014-01-02 17:26:22 +0800"},{"line_number":6,"context_line":""},{"line_number":7,"context_line":"Modify SecurityGroup and Instance Object"},{"line_number":8,"context_line":""},{"line_number":9,"context_line":"1.Update SecurityGroup fields and add ensure()"},{"line_number":10,"context_line":"2.Add Instance add_security_group() and remove_security_group()"}],"source_content_type":"text/x-gerrit-commit-message","patch_set":4,"id":"AAAAT3%2F%2FrcI%3D","line":7,"updated":"2014-01-03 16:36:46.000000000","message":"This is not a reasonable summary line, IMHO.","commit_id":"29872bc8f659d0b0d6708f800dd74ec8de7f9cc2"},{"author":{"_account_id":4393,"name":"Dan Smith","email":"dms@danplanet.com","username":"danms"},"change_message_id":"edb56ff515c3d59dede716441f72a5afda29c363","unresolved":false,"context_lines":[{"line_number":7,"context_line":"Modify SecurityGroup and Instance Object"},{"line_number":8,"context_line":""},{"line_number":9,"context_line":"1.Update SecurityGroup fields and add ensure()"},{"line_number":10,"context_line":"2.Add Instance add_security_group() and remove_security_group()"},{"line_number":11,"context_line":""},{"line_number":12,"context_line":"Implements: blueprint icehouse-objects"},{"line_number":13,"context_line":"Related to blueprint icehouse-objects"}],"source_content_type":"text/x-gerrit-commit-message","patch_set":4,"id":"AAAAT3%2F%2FrcA%3D","line":10,"updated":"2014-01-03 16:36:46.000000000","message":"These look like summaries of two separate patches. Perhaps that means something :)","commit_id":"29872bc8f659d0b0d6708f800dd74ec8de7f9cc2"},{"author":{"_account_id":9407,"name":"tan0","email":"tano.tum@gmail.com","username":"tanlin"},"change_message_id":"ce703b7a455fb8a776c4b0a31174ee0a516b15ac","unresolved":false,"context_lines":[{"line_number":7,"context_line":"Modify SecurityGroup and Instance Object"},{"line_number":8,"context_line":""},{"line_number":9,"context_line":"1.Update SecurityGroup fields and add ensure()"},{"line_number":10,"context_line":"2.Add Instance add_security_group() and remove_security_group()"},{"line_number":11,"context_line":""},{"line_number":12,"context_line":"Implements: blueprint icehouse-objects"},{"line_number":13,"context_line":"Related to blueprint icehouse-objects"}],"source_content_type":"text/x-gerrit-commit-message","patch_set":4,"id":"AAAAUH%2F%2F%2BJM%3D","line":10,"in_reply_to":"AAAAT3%2F%2FrcA%3D","updated":"2014-01-06 06:50:55.000000000","message":"Because I add an extra column in SecurityGroup.save(), which needs a minor modification in test_instance, so I put them together.  I can separate them into two patches","commit_id":"29872bc8f659d0b0d6708f800dd74ec8de7f9cc2"}],"nova/objects/instance.py":[{"author":{"_account_id":4393,"name":"Dan Smith","email":"dms@danplanet.com","username":"danms"},"change_message_id":"edb56ff515c3d59dede716441f72a5afda29c363","unresolved":false,"context_lines":[{"line_number":542,"context_line":"                self.security_groups.objects.remove(group)"},{"line_number":543,"context_line":"        db.instance_remove_security_group(context.elevated(),"},{"line_number":544,"context_line":"                                          self.uuid,"},{"line_number":545,"context_line":"                                          secgroup.id)"},{"line_number":546,"context_line":""},{"line_number":547,"context_line":""},{"line_number":548,"context_line":"def _make_instance_list(context, inst_list, db_inst_list, expected_attrs):"}],"source_content_type":"text/x-python","patch_set":4,"id":"AAAAT3%2F%2Frb0%3D","line":545,"updated":"2014-01-03 16:36:46.000000000","message":"These need version bumps and don\u0027t modify the instance itself, which will be stale after the call.","commit_id":"29872bc8f659d0b0d6708f800dd74ec8de7f9cc2"},{"author":{"_account_id":9407,"name":"tan0","email":"tano.tum@gmail.com","username":"tanlin"},"change_message_id":"ce703b7a455fb8a776c4b0a31174ee0a516b15ac","unresolved":false,"context_lines":[{"line_number":542,"context_line":"                self.security_groups.objects.remove(group)"},{"line_number":543,"context_line":"        db.instance_remove_security_group(context.elevated(),"},{"line_number":544,"context_line":"                                          self.uuid,"},{"line_number":545,"context_line":"                                          secgroup.id)"},{"line_number":546,"context_line":""},{"line_number":547,"context_line":""},{"line_number":548,"context_line":"def _make_instance_list(context, inst_list, db_inst_list, expected_attrs):"}],"source_content_type":"text/x-python","patch_set":4,"id":"AAAAUH%2F%2F9%2Fs%3D","line":545,"in_reply_to":"AAAAT3%2F%2Frb0%3D","updated":"2014-01-06 06:50:55.000000000","message":"Done","commit_id":"29872bc8f659d0b0d6708f800dd74ec8de7f9cc2"}],"nova/objects/security_group.py":[{"author":{"_account_id":4393,"name":"Dan Smith","email":"dms@danplanet.com","username":"danms"},"change_message_id":"edb56ff515c3d59dede716441f72a5afda29c363","unresolved":false,"context_lines":[{"line_number":20,"context_line":"class SecurityGroup(base.NovaPersistentObject, base.NovaObject):"},{"line_number":21,"context_line":"    # Version 1.0: Initial version"},{"line_number":22,"context_line":"    # Version 1.1: String attributes updated to support unicode"},{"line_number":23,"context_line":"    # Version 1.2: Set attributes to be nullable and added ensure()"},{"line_number":24,"context_line":"    VERSION \u003d \u00271.2\u0027"},{"line_number":25,"context_line":""},{"line_number":26,"context_line":"    fields \u003d {"}],"source_content_type":"text/x-python","patch_set":4,"id":"AAAAT3%2F%2Frbk%3D","line":23,"updated":"2014-01-03 16:36:46.000000000","message":"Why oh why? Fewer nullable attributes are better, IMHO.","commit_id":"29872bc8f659d0b0d6708f800dd74ec8de7f9cc2"},{"author":{"_account_id":9407,"name":"tan0","email":"tano.tum@gmail.com","username":"tanlin"},"change_message_id":"ce703b7a455fb8a776c4b0a31174ee0a516b15ac","unresolved":false,"context_lines":[{"line_number":20,"context_line":"class SecurityGroup(base.NovaPersistentObject, base.NovaObject):"},{"line_number":21,"context_line":"    # Version 1.0: Initial version"},{"line_number":22,"context_line":"    # Version 1.1: String attributes updated to support unicode"},{"line_number":23,"context_line":"    # Version 1.2: Set attributes to be nullable and added ensure()"},{"line_number":24,"context_line":"    VERSION \u003d \u00271.2\u0027"},{"line_number":25,"context_line":""},{"line_number":26,"context_line":"    fields \u003d {"}],"source_content_type":"text/x-python","patch_set":4,"id":"AAAAUH%2F%2F%2BFI%3D","line":23,"in_reply_to":"AAAAT3%2F%2Frbk%3D","updated":"2014-01-06 06:50:55.000000000","message":"EC2 Api revoke_security_group_ingress() and authorize_security_group_ingress()  give only \u0027name\u0027 and \u0027project_id\u0027 to create SecurityGroup and they are also nullable in DB, so I change them.","commit_id":"29872bc8f659d0b0d6708f800dd74ec8de7f9cc2"},{"author":{"_account_id":4393,"name":"Dan Smith","email":"dms@danplanet.com","username":"danms"},"change_message_id":"762586288befa4eec282812d0bbf63491d9cab3c","unresolved":false,"context_lines":[{"line_number":20,"context_line":"class SecurityGroup(base.NovaPersistentObject, base.NovaObject):"},{"line_number":21,"context_line":"    # Version 1.0: Initial version"},{"line_number":22,"context_line":"    # Version 1.1: String attributes updated to support unicode"},{"line_number":23,"context_line":"    # Version 1.2: Set attributes to be nullable and added ensure()"},{"line_number":24,"context_line":"    VERSION \u003d \u00271.2\u0027"},{"line_number":25,"context_line":""},{"line_number":26,"context_line":"    fields \u003d {"}],"source_content_type":"text/x-python","patch_set":4,"id":"AAAAUH%2F%2Fx1w%3D","line":23,"in_reply_to":"AAAAUH%2F%2F%2BFI%3D","updated":"2014-01-08 15:30:16.000000000","message":"So name and project_id should not be nullable!","commit_id":"29872bc8f659d0b0d6708f800dd74ec8de7f9cc2"},{"author":{"_account_id":9407,"name":"tan0","email":"tano.tum@gmail.com","username":"tanlin"},"change_message_id":"88bb8777f94759d04dd3c446407c7f9f4490d3f6","unresolved":false,"context_lines":[{"line_number":20,"context_line":"class SecurityGroup(base.NovaPersistentObject, base.NovaObject):"},{"line_number":21,"context_line":"    # Version 1.0: Initial version"},{"line_number":22,"context_line":"    # Version 1.1: String attributes updated to support unicode"},{"line_number":23,"context_line":"    # Version 1.2: Set attributes to be nullable and added ensure()"},{"line_number":24,"context_line":"    VERSION \u003d \u00271.2\u0027"},{"line_number":25,"context_line":""},{"line_number":26,"context_line":"    fields \u003d {"}],"source_content_type":"text/x-python","patch_set":4,"id":"AAAAUH%2F%2FvVU%3D","line":23,"in_reply_to":"AAAAUH%2F%2Fx1w%3D","updated":"2014-01-09 03:45:27.000000000","message":"Done","commit_id":"29872bc8f659d0b0d6708f800dd74ec8de7f9cc2"},{"author":{"_account_id":4393,"name":"Dan Smith","email":"dms@danplanet.com","username":"danms"},"change_message_id":"edb56ff515c3d59dede716441f72a5afda29c363","unresolved":false,"context_lines":[{"line_number":40,"context_line":"        return secgroup"},{"line_number":41,"context_line":""},{"line_number":42,"context_line":"    @base.remotable_classmethod"},{"line_number":43,"context_line":"    def get(cls, context, secgroup_id, columns_to_join\u003dNone):"},{"line_number":44,"context_line":"        db_secgroup \u003d db.security_group_get(context, secgroup_id,"},{"line_number":45,"context_line":"                                            columns_to_join)"},{"line_number":46,"context_line":"        return cls._from_db_object(context, cls(), db_secgroup)"}],"source_content_type":"text/x-python","patch_set":4,"id":"AAAAT3%2F%2FraM%3D","line":43,"updated":"2014-01-03 16:36:46.000000000","message":"This adds columns, but doesn\u0027t modify from_db_object to take advantage/load them?","commit_id":"29872bc8f659d0b0d6708f800dd74ec8de7f9cc2"},{"author":{"_account_id":9407,"name":"tan0","email":"tano.tum@gmail.com","username":"tanlin"},"change_message_id":"ce703b7a455fb8a776c4b0a31174ee0a516b15ac","unresolved":false,"context_lines":[{"line_number":40,"context_line":"        return secgroup"},{"line_number":41,"context_line":""},{"line_number":42,"context_line":"    @base.remotable_classmethod"},{"line_number":43,"context_line":"    def get(cls, context, secgroup_id, columns_to_join\u003dNone):"},{"line_number":44,"context_line":"        db_secgroup \u003d db.security_group_get(context, secgroup_id,"},{"line_number":45,"context_line":"                                            columns_to_join)"},{"line_number":46,"context_line":"        return cls._from_db_object(context, cls(), db_secgroup)"}],"source_content_type":"text/x-python","patch_set":4,"id":"AAAAUH%2F%2F%2BFY%3D","line":43,"in_reply_to":"AAAAT3%2F%2FraM%3D","updated":"2014-01-06 06:50:55.000000000","message":"It only used by trigger_members_refresh() in compute/api to add \u0027instances\u0027 in order to make use of joinedload_all(column), I didn\u0027t see the advantage in from_db_object","commit_id":"29872bc8f659d0b0d6708f800dd74ec8de7f9cc2"},{"author":{"_account_id":4393,"name":"Dan Smith","email":"dms@danplanet.com","username":"danms"},"change_message_id":"762586288befa4eec282812d0bbf63491d9cab3c","unresolved":false,"context_lines":[{"line_number":40,"context_line":"        return secgroup"},{"line_number":41,"context_line":""},{"line_number":42,"context_line":"    @base.remotable_classmethod"},{"line_number":43,"context_line":"    def get(cls, context, secgroup_id, columns_to_join\u003dNone):"},{"line_number":44,"context_line":"        db_secgroup \u003d db.security_group_get(context, secgroup_id,"},{"line_number":45,"context_line":"                                            columns_to_join)"},{"line_number":46,"context_line":"        return cls._from_db_object(context, cls(), db_secgroup)"}],"source_content_type":"text/x-python","patch_set":4,"id":"AAAAUH%2F%2Fx2E%3D","line":43,"in_reply_to":"AAAAUH%2F%2F%2BFY%3D","updated":"2014-01-08 15:30:16.000000000","message":"Because if you don\u0027t include them in the db object and from_db_object doesn\u0027t know to exclude them, then they will get lazy-loaded anyway, making the performance much worse than it should be.","commit_id":"29872bc8f659d0b0d6708f800dd74ec8de7f9cc2"},{"author":{"_account_id":9407,"name":"tan0","email":"tano.tum@gmail.com","username":"tanlin"},"change_message_id":"ade40caae8ca4b9ba5d9cdea23edff9b2d30b90d","unresolved":false,"context_lines":[{"line_number":40,"context_line":"        return secgroup"},{"line_number":41,"context_line":""},{"line_number":42,"context_line":"    @base.remotable_classmethod"},{"line_number":43,"context_line":"    def get(cls, context, secgroup_id, columns_to_join\u003dNone):"},{"line_number":44,"context_line":"        db_secgroup \u003d db.security_group_get(context, secgroup_id,"},{"line_number":45,"context_line":"                                            columns_to_join)"},{"line_number":46,"context_line":"        return cls._from_db_object(context, cls(), db_secgroup)"}],"source_content_type":"text/x-python","patch_set":4,"id":"AAAAUH%2F%2Fo7E%3D","line":43,"in_reply_to":"AAAAUH%2F%2Fx2E%3D","updated":"2014-01-10 07:40:29.000000000","message":"@ Dan Smith\nI make use of the columns in the latest patch to avoid lazy-loading. And we can access instances by SecurityGroup[\u0027instancs\u0027].\nIs that what you mean?","commit_id":"29872bc8f659d0b0d6708f800dd74ec8de7f9cc2"},{"author":{"_account_id":9407,"name":"tan0","email":"tano.tum@gmail.com","username":"tanlin"},"change_message_id":"88bb8777f94759d04dd3c446407c7f9f4490d3f6","unresolved":false,"context_lines":[{"line_number":40,"context_line":"        return secgroup"},{"line_number":41,"context_line":""},{"line_number":42,"context_line":"    @base.remotable_classmethod"},{"line_number":43,"context_line":"    def get(cls, context, secgroup_id, columns_to_join\u003dNone):"},{"line_number":44,"context_line":"        db_secgroup \u003d db.security_group_get(context, secgroup_id,"},{"line_number":45,"context_line":"                                            columns_to_join)"},{"line_number":46,"context_line":"        return cls._from_db_object(context, cls(), db_secgroup)"}],"source_content_type":"text/x-python","patch_set":4,"id":"AAAAUH%2F%2Fu%2Bo%3D","line":43,"in_reply_to":"AAAAUH%2F%2Fx2E%3D","updated":"2014-01-09 03:45:27.000000000","message":"OK, I get understood. But then the question is do we need to add the column here? \nBefore object model, SecurityGroup has attribute \u0027instances\u0027, and this can help to reduce db query. \nNow in trigger_members_refresh(), I call InstanceLikst.get_by_security_group() to get instances instead of security_group[\u0027instances\u0027].  \nSo we don\u0027t need this anymore.","commit_id":"29872bc8f659d0b0d6708f800dd74ec8de7f9cc2"},{"author":{"_account_id":4393,"name":"Dan Smith","email":"dms@danplanet.com","username":"danms"},"change_message_id":"edb56ff515c3d59dede716441f72a5afda29c363","unresolved":false,"context_lines":[{"line_number":54,"context_line":""},{"line_number":55,"context_line":"    @base.remotable_classmethod"},{"line_number":56,"context_line":"    def ensure(cls, context):"},{"line_number":57,"context_line":"        return db.security_group_ensure_default(context)"},{"line_number":58,"context_line":""},{"line_number":59,"context_line":"    @base.remotable"},{"line_number":60,"context_line":"    def in_use(self, context):"}],"source_content_type":"text/x-python","patch_set":4,"id":"AAAAT3%2F%2FrbU%3D","line":57,"updated":"2014-01-03 16:36:46.000000000","message":"Why does this need to be remotable? And, it doesn\u0027t return an instance of the object like everything else.","commit_id":"29872bc8f659d0b0d6708f800dd74ec8de7f9cc2"},{"author":{"_account_id":9407,"name":"tan0","email":"tano.tum@gmail.com","username":"tanlin"},"change_message_id":"ce703b7a455fb8a776c4b0a31174ee0a516b15ac","unresolved":false,"context_lines":[{"line_number":54,"context_line":""},{"line_number":55,"context_line":"    @base.remotable_classmethod"},{"line_number":56,"context_line":"    def ensure(cls, context):"},{"line_number":57,"context_line":"        return db.security_group_ensure_default(context)"},{"line_number":58,"context_line":""},{"line_number":59,"context_line":"    @base.remotable"},{"line_number":60,"context_line":"    def in_use(self, context):"}],"source_content_type":"text/x-python","patch_set":4,"id":"AAAAUH%2F%2F%2BH0%3D","line":57,"in_reply_to":"AAAAT3%2F%2FrbU%3D","updated":"2014-01-06 06:50:55.000000000","message":"Done","commit_id":"29872bc8f659d0b0d6708f800dd74ec8de7f9cc2"},{"author":{"_account_id":4393,"name":"Dan Smith","email":"dms@danplanet.com","username":"danms"},"change_message_id":"94e371c6e976a6038e552db7b87ab282b69d2485","unresolved":false,"context_lines":[{"line_number":28,"context_line":"        \u0027id\u0027: fields.IntegerField(),"},{"line_number":29,"context_line":"        \u0027name\u0027: fields.StringField(),"},{"line_number":30,"context_line":"        \u0027description\u0027: fields.StringField(nullable\u003dTrue),"},{"line_number":31,"context_line":"        \u0027user_id\u0027: fields.StringField(nullable\u003dTrue),"},{"line_number":32,"context_line":"        \u0027project_id\u0027: fields.StringField(),"},{"line_number":33,"context_line":"        }"},{"line_number":34,"context_line":""}],"source_content_type":"text/x-python","patch_set":10,"id":"AAAAU3%2F%2Fark%3D","line":31,"updated":"2014-02-26 19:16:52.000000000","message":"So what happens if I try to send this to a node that has an older version where these properties are not nullable? It will crash. You don\u0027t have a obj_make_compatible() here to handle this.","commit_id":"dd582ad3ffe407da1d5cef4c36409ffdfbfc6b74"},{"author":{"_account_id":4393,"name":"Dan Smith","email":"dms@danplanet.com","username":"danms"},"change_message_id":"94e371c6e976a6038e552db7b87ab282b69d2485","unresolved":false,"context_lines":[{"line_number":47,"context_line":"        if columns_to_join is None:"},{"line_number":48,"context_line":"            columns_to_join \u003d []"},{"line_number":49,"context_line":"        for column in columns_to_join:"},{"line_number":50,"context_line":"            if column.startswith(\u0027instances\u0027):"},{"line_number":51,"context_line":"                # Keep consistent with InstanceList.get_by_security_group_id"},{"line_number":52,"context_line":"                from nova.objects import instance"},{"line_number":53,"context_line":"                cls._cached_instances \u003d instance._make_instance_list("}],"source_content_type":"text/x-python","patch_set":10,"id":"AAAAU3%2F%2Fans%3D","line":50,"updated":"2014-02-26 19:16:52.000000000","message":"Um, what\u0027s the name of the column? I don\u0027t see how it makes sense to fuzzy-match this.","commit_id":"dd582ad3ffe407da1d5cef4c36409ffdfbfc6b74"},{"author":{"_account_id":4393,"name":"Dan Smith","email":"dms@danplanet.com","username":"danms"},"change_message_id":"94e371c6e976a6038e552db7b87ab282b69d2485","unresolved":false,"context_lines":[{"line_number":65,"context_line":"    @staticmethod"},{"line_number":66,"context_line":"    def ensure(context):"},{"line_number":67,"context_line":"        \"\"\"Ensure default security group exists for a project_id.\"\"\""},{"line_number":68,"context_line":"        db.security_group_ensure_default(context)"},{"line_number":69,"context_line":""},{"line_number":70,"context_line":"    @base.remotable"},{"line_number":71,"context_line":"    def in_use(self, context):"}],"source_content_type":"text/x-python","patch_set":10,"id":"AAAAU3%2F%2FamM%3D","line":68,"updated":"2014-02-26 19:16:52.000000000","message":"Just to be clear, this method cannot be run by anything that is prohibited from talking to the database. That means no compute nodes, soon no nova-network nodes, etc. Is that what you want? If it\u0027s only to be used by a remotable method, then it probably needs to start with an underscore so it is clearly not an external interface. However, I don\u0027t see it used anywhere here.","commit_id":"dd582ad3ffe407da1d5cef4c36409ffdfbfc6b74"},{"author":{"_account_id":4393,"name":"Dan Smith","email":"dms@danplanet.com","username":"danms"},"change_message_id":"94e371c6e976a6038e552db7b87ab282b69d2485","unresolved":false,"context_lines":[{"line_number":85,"context_line":"            db_secgroup \u003d db.security_group_update(context,"},{"line_number":86,"context_line":"                                                   self.id,"},{"line_number":87,"context_line":"                                                   updates,"},{"line_number":88,"context_line":"                                                   columns_to_join)"},{"line_number":89,"context_line":"            SecurityGroup._from_db_object(context, self, db_secgroup)"},{"line_number":90,"context_line":"        self.obj_reset_changes()"},{"line_number":91,"context_line":""}],"source_content_type":"text/x-python","patch_set":10,"id":"AAAAU3%2F%2FakQ%3D","line":88,"updated":"2014-02-26 19:16:52.000000000","message":"We should be able to calculate the columns_to_join from the data we have in the object. Making save() take this argument is not a good idea, IMHO.","commit_id":"dd582ad3ffe407da1d5cef4c36409ffdfbfc6b74"},{"author":{"_account_id":4393,"name":"Dan Smith","email":"dms@danplanet.com","username":"danms"},"change_message_id":"94e371c6e976a6038e552db7b87ab282b69d2485","unresolved":false,"context_lines":[{"line_number":107,"context_line":"            self._cached_instances \u003d (instance.InstanceList."},{"line_number":108,"context_line":"                                       get_by_security_group_id(self._context,"},{"line_number":109,"context_line":"                                                                self.id))"},{"line_number":110,"context_line":"        return self._cached_instances"},{"line_number":111,"context_line":""},{"line_number":112,"context_line":""},{"line_number":113,"context_line":"def _make_secgroup_list(context, secgroup_list, db_secgroup_list):"}],"source_content_type":"text/x-python","patch_set":10,"id":"AAAAU3%2F%2FajI%3D","line":110,"updated":"2014-02-26 19:16:52.000000000","message":"This doesn\u0027t work remotely and thus shouldn\u0027t be here, IMHO.","commit_id":"dd582ad3ffe407da1d5cef4c36409ffdfbfc6b74"}]}
