)]}'
{"trove/datastore/models.py":[{"author":{"_account_id":22608,"name":"zhanggang","email":"zhanggang@cmss.chinamobile.com","username":"zhanggang"},"change_message_id":"ebe9a8b67e65a5840a126bb9d6fb21df14d79748","unresolved":false,"context_lines":[{"line_number":736,"context_line":"                associated_flavors \u003d tuple(flavor_model(flavor\u003ditem)"},{"line_number":737,"context_line":"                                           for item in nova_flavors)"},{"line_number":738,"context_line":"            return associated_flavors"},{"line_number":739,"context_line":"        else:"},{"line_number":740,"context_line":"            msg \u003d _(\"Specify both the datastore and datastore_version_id.\")"},{"line_number":741,"context_line":"            raise exception.BadRequest(msg)"},{"line_number":742,"context_line":""}],"source_content_type":"text/x-python","patch_set":1,"id":"ff82abbf_dfcd66b7","line":739,"range":{"start_line":739,"start_character":12,"end_line":739,"end_character":13},"updated":"2017-11-29 01:24:08.000000000","message":"But I still think don\u0027t need add a new method, we can modify this method. If datastore and datastreo_version, in this else block, add your logic \"bound_flavors \u003d DBDatastoreVersionMetadata.find_all(deleted\u003dFalse)\"","commit_id":"e6531bf9aca76c32ed4877d8c0947557da8f26e4"},{"author":{"_account_id":22608,"name":"zhanggang","email":"zhanggang@cmss.chinamobile.com","username":"zhanggang"},"change_message_id":"35b52f754c7909f03b6fe9be781264bd27738ce4","unresolved":false,"context_lines":[{"line_number":741,"context_line":"            raise exception.BadRequest(msg)"},{"line_number":742,"context_line":""},{"line_number":743,"context_line":"    @classmethod"},{"line_number":744,"context_line":"    def list_associated_flavors(cls, context):"},{"line_number":745,"context_line":"        \"\"\""},{"line_number":746,"context_line":"        All nova flavors are permitted for a datastore_version unless"},{"line_number":747,"context_line":"        one or more entries are found in datastore_version_metadata,"}],"source_content_type":"text/x-python","patch_set":1,"id":"ff82abbf_5195db31","line":744,"range":{"start_line":744,"start_character":44,"end_line":744,"end_character":46},"updated":"2017-11-28 15:08:39.000000000","message":"why we need this, already have a method \"list_datastore_version_flavor_associations\" and a \n\"list_associated_flavors\" API in datastore/service.py","commit_id":"e6531bf9aca76c32ed4877d8c0947557da8f26e4"},{"author":{"_account_id":18418,"name":"Andy Botting","email":"andy@andybotting.com","username":"andybotting"},"change_message_id":"d9ae2d71319ec352078d21a9174d921be3087cd9","unresolved":false,"context_lines":[{"line_number":741,"context_line":"            raise exception.BadRequest(msg)"},{"line_number":742,"context_line":""},{"line_number":743,"context_line":"    @classmethod"},{"line_number":744,"context_line":"    def list_associated_flavors(cls, context):"},{"line_number":745,"context_line":"        \"\"\""},{"line_number":746,"context_line":"        All nova flavors are permitted for a datastore_version unless"},{"line_number":747,"context_line":"        one or more entries are found in datastore_version_metadata,"}],"source_content_type":"text/x-python","patch_set":1,"id":"ff82abbf_61b4c280","line":744,"range":{"start_line":744,"start_character":44,"end_line":744,"end_character":46},"in_reply_to":"ff82abbf_5195db31","updated":"2017-11-28 22:19:49.000000000","message":"Those other methods are datastore / datastore version specific. This is for listing flavours available for trove across all datastore / datastore versions, useful for when the user hasn\u0027t yet chosen a datastore like in the dashboard wizard. \n\nCurrently the \u0027launch instance\u0027 dashboard wizard shows all flavors, when it really should only show those which have been designated for trove to use.\n\nIn our case, we have a specific db.small flavor, which is the only flavor set for Trove to use. Without this patch, it lists all flavors, and is confusing for users.","commit_id":"e6531bf9aca76c32ed4877d8c0947557da8f26e4"},{"author":{"_account_id":22608,"name":"zhanggang","email":"zhanggang@cmss.chinamobile.com","username":"zhanggang"},"change_message_id":"36765d7d3ab3cfce0168b88fc12c5bf7288e294c","unresolved":false,"context_lines":[{"line_number":741,"context_line":"            raise exception.BadRequest(msg)"},{"line_number":742,"context_line":""},{"line_number":743,"context_line":"    @classmethod"},{"line_number":744,"context_line":"    def list_associated_flavors(cls, context):"},{"line_number":745,"context_line":"        \"\"\""},{"line_number":746,"context_line":"        All nova flavors are permitted for a datastore_version unless"},{"line_number":747,"context_line":"        one or more entries are found in datastore_version_metadata,"}],"source_content_type":"text/x-python","patch_set":1,"id":"ff82abbf_3f901295","line":744,"range":{"start_line":744,"start_character":44,"end_line":744,"end_character":46},"in_reply_to":"ff82abbf_61b4c280","updated":"2017-11-29 01:21:00.000000000","message":"I see... I use a prefix to create flavors for trove and filter in flavor/views.py in my own code, forget that master code return all nova flavors.","commit_id":"e6531bf9aca76c32ed4877d8c0947557da8f26e4"},{"author":{"_account_id":22608,"name":"zhanggang","email":"zhanggang@cmss.chinamobile.com","username":"zhanggang"},"change_message_id":"0ea0370362878307e2367d7ee276b72b9ee859b0","unresolved":false,"context_lines":[{"line_number":704,"context_line":"            exception.DatastoreFlavorAssociationNotFound)"},{"line_number":705,"context_line":""},{"line_number":706,"context_line":"    @classmethod"},{"line_number":707,"context_line":"    def list_datastore_version_flavor_associations(cls, context,"},{"line_number":708,"context_line":"                                                   datastore_type,"},{"line_number":709,"context_line":"                                                   datastore_version_id):"},{"line_number":710,"context_line":"        if datastore_type and datastore_version_id:"}],"source_content_type":"text/x-python","patch_set":3,"id":"ff82abbf_69fca06f","side":"PARENT","line":707,"range":{"start_line":707,"start_character":8,"end_line":707,"end_character":50},"updated":"2017-11-29 06:58:26.000000000","message":"In my opinion, this method name is better.","commit_id":"a6a9259d42ed7e10fc05bd2206371a31b90820dc"},{"author":{"_account_id":22608,"name":"zhanggang","email":"zhanggang@cmss.chinamobile.com","username":"zhanggang"},"change_message_id":"0ea0370362878307e2367d7ee276b72b9ee859b0","unresolved":false,"context_lines":[{"line_number":722,"context_line":"                key\u003d\u0027flavor\u0027, deleted\u003dFalse"},{"line_number":723,"context_line":"            )"},{"line_number":724,"context_line":"        else:"},{"line_number":725,"context_line":"            bound_flavors \u003d DBDatastoreVersionMetadata.find_all(deleted\u003dFalse)"},{"line_number":726,"context_line":""},{"line_number":727,"context_line":"        nova_flavors \u003d create_nova_client(context).flavors.list()"},{"line_number":728,"context_line":""}],"source_content_type":"text/x-python","patch_set":3,"id":"ff82abbf_69cee063","line":725,"range":{"start_line":725,"start_character":64,"end_line":725,"end_character":71},"updated":"2017-11-29 06:58:26.000000000","message":"miss key\u003d\u0027flavor\u0027","commit_id":"87d0f5de469b1d17a1023c0df23b242fca89168b"}],"trove/flavor/models.py":[{"author":{"_account_id":24739,"name":"Yao Wang","email":"wangyao@cmss.chinamobile.com","username":"wangyao"},"change_message_id":"1cc068e13333a939a248cb22508fe3a6f9f122d4","unresolved":false,"context_lines":[{"line_number":75,"context_line":"class Flavors(NovaRemoteModelBase):"},{"line_number":76,"context_line":""},{"line_number":77,"context_line":"    def __init__(self, context):"},{"line_number":78,"context_line":"        from trove.datastore.models import DatastoreVersionMetadata"},{"line_number":79,"context_line":"        self.flavors \u003d DatastoreVersionMetadata.list_associated_flavors("},{"line_number":80,"context_line":"            context)"},{"line_number":81,"context_line":""}],"source_content_type":"text/x-python","patch_set":1,"id":"ff82abbf_3fd90356","line":78,"range":{"start_line":78,"start_character":7,"end_line":78,"end_character":67},"updated":"2017-11-28 14:28:30.000000000","message":"you may put this on the top","commit_id":"e6531bf9aca76c32ed4877d8c0947557da8f26e4"},{"author":{"_account_id":18418,"name":"Andy Botting","email":"andy@andybotting.com","username":"andybotting"},"change_message_id":"97f20acb6ed2abda4638cd92fb5135e10c4c45e0","unresolved":false,"context_lines":[{"line_number":75,"context_line":"class Flavors(NovaRemoteModelBase):"},{"line_number":76,"context_line":""},{"line_number":77,"context_line":"    def __init__(self, context):"},{"line_number":78,"context_line":"        from trove.datastore.models import DatastoreVersionMetadata"},{"line_number":79,"context_line":"        self.flavors \u003d DatastoreVersionMetadata.list_associated_flavors("},{"line_number":80,"context_line":"            context)"},{"line_number":81,"context_line":""}],"source_content_type":"text/x-python","patch_set":1,"id":"ff82abbf_c13caee2","line":78,"range":{"start_line":78,"start_character":7,"end_line":78,"end_character":67},"in_reply_to":"ff82abbf_3fd90356","updated":"2017-11-28 22:24:35.000000000","message":"Traceback (most recent call last):\n  File \"/opt/pike/bin/trove-api\", line 10, in \u003cmodule\u003e\n    sys.exit(main())\n  File \"/opt/trove/trove/cmd/common.py\", line 62, in run\n    conf \u003d initialize(**kwargs)\n  File \"/opt/trove/trove/cmd/common.py\", line 50, in initialize\n    get_db_api().configure_db(conf)\n  File \"/opt/trove/trove/db/sqlalchemy/api.py\", line 90, in configure_db\n    session.configure_db(options)\n  File \"/opt/trove/trove/db/sqlalchemy/session.py\", line 41, in configure_db\n    from trove.backup import models as backup_models\n  File \"/opt/trove/trove/backup/models.py\", line 27, in \u003cmodule\u003e\n    from trove.datastore import models as datastore_models\n  File \"/opt/trove/trove/datastore/models.py\", line 28, in \u003cmodule\u003e\n    from trove.flavor.models import Flavor as flavor_model\n  File \"/opt/trove/trove/flavor/models.py\", line 24, in \u003cmodule\u003e\n    from trove.datastore.models import DatastoreVersionMetadata\nImportError: cannot import name DatastoreVersionMetadata","commit_id":"e6531bf9aca76c32ed4877d8c0947557da8f26e4"},{"author":{"_account_id":18418,"name":"Andy Botting","email":"andy@andybotting.com","username":"andybotting"},"change_message_id":"67214d963b9e8c525991bd26be462e0c8f2b10fb","unresolved":false,"context_lines":[{"line_number":75,"context_line":"class Flavors(NovaRemoteModelBase):"},{"line_number":76,"context_line":""},{"line_number":77,"context_line":"    def __init__(self, context):"},{"line_number":78,"context_line":"        from trove.datastore.models import DatastoreVersionMetadata"},{"line_number":79,"context_line":"        self.flavors \u003d DatastoreVersionMetadata.list_associated_flavors("},{"line_number":80,"context_line":"            context)"},{"line_number":81,"context_line":""}],"source_content_type":"text/x-python","patch_set":1,"id":"ff82abbf_c1158e4a","line":78,"range":{"start_line":78,"start_character":7,"end_line":78,"end_character":67},"in_reply_to":"ff82abbf_c13caee2","updated":"2017-11-29 04:18:31.000000000","message":"Done","commit_id":"e6531bf9aca76c32ed4877d8c0947557da8f26e4"}]}
