)]}'
{"cinder/db/sqlalchemy/api.py":[{"author":{"_account_id":21144,"name":"Xinli Guan","email":"xinli@us.ibm.com","username":"xinli"},"change_message_id":"7eee09431a59f6f25c9f32308c1da891e932ccfe","unresolved":false,"context_lines":[{"line_number":2862,"context_line":"                           models.QualityOfServiceSpecs,"},{"line_number":2863,"context_line":"                           qos_specs_id):"},{"line_number":2864,"context_line":"        raise exception.QoSSpecsNotFound(specs_id\u003dqos_specs_id)"},{"line_number":2865,"context_line":"    vts \u003d (model_query(context, models.VolumeTypes, read_deleted\u003dread_deleted)."},{"line_number":2866,"context_line":"           options(joinedload(\u0027extra_specs\u0027))."},{"line_number":2867,"context_line":"           filter_by(qos_specs_id\u003dqos_specs_id).all())"},{"line_number":2868,"context_line":"    return vts"}],"source_content_type":"text/x-python","patch_set":1,"id":"fad55976_1ae45e39","line":2865,"updated":"2016-07-16 15:46:04.000000000","message":"Michal;\n\nCould you please explain why the options part gets removed from the model_query?","commit_id":"217eadb2ce315970ba5ad93308ffc73bb3b5a767"},{"author":{"_account_id":11600,"name":"Michał Dulko","email":"michal.dulko@gmail.com","username":"dulek"},"change_message_id":"8d2857282a3c6187ab1d44aefe4060aa01a9d48f","unresolved":false,"context_lines":[{"line_number":2862,"context_line":"                           models.QualityOfServiceSpecs,"},{"line_number":2863,"context_line":"                           qos_specs_id):"},{"line_number":2864,"context_line":"        raise exception.QoSSpecsNotFound(specs_id\u003dqos_specs_id)"},{"line_number":2865,"context_line":"    vts \u003d (model_query(context, models.VolumeTypes, read_deleted\u003dread_deleted)."},{"line_number":2866,"context_line":"           options(joinedload(\u0027extra_specs\u0027))."},{"line_number":2867,"context_line":"           filter_by(qos_specs_id\u003dqos_specs_id).all())"},{"line_number":2868,"context_line":"    return vts"}],"source_content_type":"text/x-python","patch_set":1,"id":"dada55a8_cba533b6","line":2865,"in_reply_to":"fad55976_1ae45e39","updated":"2016-07-18 10:00:20.000000000","message":"Actually I\u0027m adding `options(joinedload())` here. It\u0027s to make sure extra_specs field loadable - somehow our SQLAlchemy objects are disconnected from the DB session after `all()`. I don\u0027t quite understand why, but this fixes the issue.","commit_id":"217eadb2ce315970ba5ad93308ffc73bb3b5a767"}],"cinder/volume/qos_specs.py":[{"author":{"_account_id":6491,"name":"xing-yang","email":"xingyang105@gmail.com","username":"xing-yang"},"change_message_id":"0fb70b01ab950c7409a4f69de87322b9d4b745af","unresolved":false,"context_lines":[{"line_number":135,"context_line":"def get_associations(context, qos_specs_id):"},{"line_number":136,"context_line":"    \"\"\"Get all associations of given qos specs.\"\"\""},{"line_number":137,"context_line":"    try:"},{"line_number":138,"context_line":"        types \u003d objects.VolumeTypeList.get_all_types_for_qos(context,"},{"line_number":139,"context_line":"                                                             qos_specs_id)"},{"line_number":140,"context_line":"    except db_exc.DBError:"},{"line_number":141,"context_line":"        LOG.exception(_LE(\u0027DB error:\u0027))"}],"source_content_type":"text/x-python","patch_set":1,"id":"fad55976_c74c1179","line":138,"updated":"2016-07-15 17:06:31.000000000","message":"There is a new pylint error caused by this line:\n\ncinder/volume/qos_specs.py:138: [E1101, get_associations] Module \u0027cinder.objects\u0027 has no \u0027VolumeTypeList\u0027 member","commit_id":"217eadb2ce315970ba5ad93308ffc73bb3b5a767"},{"author":{"_account_id":11600,"name":"Michał Dulko","email":"michal.dulko@gmail.com","username":"dulek"},"change_message_id":"84724e19f4bc653a81db99875cd7bff390b0030c","unresolved":false,"context_lines":[{"line_number":135,"context_line":"def get_associations(context, qos_specs_id):"},{"line_number":136,"context_line":"    \"\"\"Get all associations of given qos specs.\"\"\""},{"line_number":137,"context_line":"    try:"},{"line_number":138,"context_line":"        types \u003d objects.VolumeTypeList.get_all_types_for_qos(context,"},{"line_number":139,"context_line":"                                                             qos_specs_id)"},{"line_number":140,"context_line":"    except db_exc.DBError:"},{"line_number":141,"context_line":"        LOG.exception(_LE(\u0027DB error:\u0027))"}],"source_content_type":"text/x-python","patch_set":1,"id":"dada55a8_6b5ec746","line":138,"in_reply_to":"dada55a8_eb03d774","updated":"2016-07-18 10:05:52.000000000","message":"@Xinli: Okay, paste loaded. You\u0027re talking about pylint error, which is related only to the fact that we\u0027re doing some magic in cinder.objects.__init__ module. [1]\n\n[1] https://github.com/openstack/cinder/blob/master/cinder/objects/__init__.py#L35","commit_id":"217eadb2ce315970ba5ad93308ffc73bb3b5a767"},{"author":{"_account_id":11600,"name":"Michał Dulko","email":"michal.dulko@gmail.com","username":"dulek"},"change_message_id":"8d2857282a3c6187ab1d44aefe4060aa01a9d48f","unresolved":false,"context_lines":[{"line_number":135,"context_line":"def get_associations(context, qos_specs_id):"},{"line_number":136,"context_line":"    \"\"\"Get all associations of given qos specs.\"\"\""},{"line_number":137,"context_line":"    try:"},{"line_number":138,"context_line":"        types \u003d objects.VolumeTypeList.get_all_types_for_qos(context,"},{"line_number":139,"context_line":"                                                             qos_specs_id)"},{"line_number":140,"context_line":"    except db_exc.DBError:"},{"line_number":141,"context_line":"        LOG.exception(_LE(\u0027DB error:\u0027))"}],"source_content_type":"text/x-python","patch_set":1,"id":"dada55a8_eb03d774","line":138,"in_reply_to":"fad55976_5c9c13c0","updated":"2016-07-18 10:00:20.000000000","message":"paste.openstack.org is unfortunately offline now, but I think we do have volume_types in QualityOfServiceSpec object [1]. I don\u0027t understand the comment.\n\nMain purpose of this change is to save us on DB queries - previous way would generate one query to get QoS spec, and then another to lazy-load volume_types in there.\n\n[1] https://github.com/openstack/cinder/blob/217eadb2ce315970ba5ad93308ffc73bb3b5a767/cinder/objects/qos_specs.py#L44-L44","commit_id":"217eadb2ce315970ba5ad93308ffc73bb3b5a767"},{"author":{"_account_id":11600,"name":"Michał Dulko","email":"michal.dulko@gmail.com","username":"dulek"},"change_message_id":"8d2857282a3c6187ab1d44aefe4060aa01a9d48f","unresolved":false,"context_lines":[{"line_number":135,"context_line":"def get_associations(context, qos_specs_id):"},{"line_number":136,"context_line":"    \"\"\"Get all associations of given qos specs.\"\"\""},{"line_number":137,"context_line":"    try:"},{"line_number":138,"context_line":"        types \u003d objects.VolumeTypeList.get_all_types_for_qos(context,"},{"line_number":139,"context_line":"                                                             qos_specs_id)"},{"line_number":140,"context_line":"    except db_exc.DBError:"},{"line_number":141,"context_line":"        LOG.exception(_LE(\u0027DB error:\u0027))"}],"source_content_type":"text/x-python","patch_set":1,"id":"dada55a8_2b35ef45","line":138,"in_reply_to":"fad55976_c74c1179","updated":"2016-07-18 10:00:20.000000000","message":"@xing-yang: Sure!","commit_id":"217eadb2ce315970ba5ad93308ffc73bb3b5a767"},{"author":{"_account_id":21144,"name":"Xinli Guan","email":"xinli@us.ibm.com","username":"xinli"},"change_message_id":"7eee09431a59f6f25c9f32308c1da891e932ccfe","unresolved":false,"context_lines":[{"line_number":135,"context_line":"def get_associations(context, qos_specs_id):"},{"line_number":136,"context_line":"    \"\"\"Get all associations of given qos specs.\"\"\""},{"line_number":137,"context_line":"    try:"},{"line_number":138,"context_line":"        types \u003d objects.VolumeTypeList.get_all_types_for_qos(context,"},{"line_number":139,"context_line":"                                                             qos_specs_id)"},{"line_number":140,"context_line":"    except db_exc.DBError:"},{"line_number":141,"context_line":"        LOG.exception(_LE(\u0027DB error:\u0027))"}],"source_content_type":"text/x-python","patch_set":1,"id":"fad55976_5c9c13c0","line":138,"in_reply_to":"fad55976_c74c1179","updated":"2016-07-16 15:46:04.000000000","message":"Michal; \nIn 251989, we add the relationship qos-specs/VolumeType, \nhttps://review.openstack.org/#/c/251989/22/cinder/objects/volume_type.py@43\n\nBut this error shows that it missing the relationship qos_specs / VolumeTypeList.\nhttp://paste.openstack.org/show/533959/","commit_id":"217eadb2ce315970ba5ad93308ffc73bb3b5a767"}]}
