)]}'
{"tempest/api/volume/admin/test_volume_hosts.py":[{"author":{"_account_id":5689,"name":"Masayuki Igawa","email":"masayuki@igawa.io","username":"igawa"},"change_message_id":"9f89c0a2c1cbebadee50f6f8c84513f7161a354a","unresolved":false,"context_lines":[{"line_number":53,"context_line":""},{"line_number":54,"context_line":"        # Choose a random cinder-volume host to get and check its elements"},{"line_number":55,"context_line":"        host_details \u003d self.admin_hosts_client.show_host("},{"line_number":56,"context_line":"            random.choice(c_vol_hosts))[\u0027host\u0027]"},{"line_number":57,"context_line":"        self.assertNotEmpty(host_details)"},{"line_number":58,"context_line":"        host_detail_keys \u003d [\u0027project\u0027, \u0027volume_count\u0027, \u0027snapshot_count\u0027,"},{"line_number":59,"context_line":"                            \u0027host\u0027, \u0027total_volume_gb\u0027, \u0027total_snapshot_gb\u0027]"}],"source_content_type":"text/x-python","patch_set":1,"id":"5f201791_5114ea43","line":56,"updated":"2017-06-27 06:56:59.000000000","message":"I\u0027m actually not a big fan of \"random.choice()\" here. Because it can make tests unstable. But it\u0027s not  this patch\u0027s issue.","commit_id":"0cb5f0002aba156b7cf5b5ad56ff65058ffcaf76"},{"author":{"_account_id":8556,"name":"Ghanshyam Maan","display_name":"Ghanshyam Maan","email":"gmaan.os14@gmail.com","username":"ghanshyam"},"change_message_id":"5fcbeece01f0b37045cb3010a236c61073f71c92","unresolved":false,"context_lines":[{"line_number":40,"context_line":"                                \"The count of volume hosts is \u003c 2, \""},{"line_number":41,"context_line":"                                \"response of list hosts is: %s\" % hosts)"},{"line_number":42,"context_line":""},{"line_number":43,"context_line":"        # Note(jeremyZ): The show host API is to show volume usage info on the"},{"line_number":44,"context_line":"        # specified cinder-volume host. If the host does not run cinder-volume"},{"line_number":45,"context_line":"        # service, the show host API will fail. The cinder-volume host is"},{"line_number":46,"context_line":"        # presented in format: \u003chost-name\u003e@driver-name."},{"line_number":47,"context_line":"        c_vol_hosts \u003d [host[\u0027host_name\u0027] for host in hosts"},{"line_number":48,"context_line":"                       if host[\u0027service\u0027] \u003d\u003d \u0027cinder-volume\u0027]"}],"source_content_type":"text/x-python","patch_set":5,"id":"9f436f4f_9997ff3a","line":45,"range":{"start_line":43,"start_character":24,"end_line":45,"end_character":48},"updated":"2017-08-16 12:59:08.000000000","message":"yea, i also got same behaviour on my multinode env.\n\nThis is what cinder code is written but i am not sure if it is right and we are missing doc only. API ref does not say that it get host of cinder-volume service only.\n\ncinder API get host with service cinder-volume\nhttps://github.com/openstack/cinder/blob/6dd6c74b389f15c42d3158ad50493c1d3086452f/cinder/api/contrib/hosts.py#L153\n\ntopic is cinder-volume here - https://github.com/openstack/cinder/blob/6dd6c74b389f15c42d3158ad50493c1d3086452f/cinder/common/constants.py#L26\n\nDB raise 404 if no cinder-volume service running -\n\nhttps://github.com/openstack/cinder/blob/6dd6c74b389f15c42d3158ad50493c1d3086452f/cinder/objects/service.py#L125\nhttps://github.com/openstack/cinder/blob/6dd6c74b389f15c42d3158ad50493c1d3086452f/cinder/db/sqlalchemy/api.py#L537","commit_id":"fa2ab09c560f2ae3e565ddf5234b41a2f36a7c97"},{"author":{"_account_id":6167,"name":"Ken\u0027ichi Ohmichi","email":"ken1ohmichi@gmail.com","username":"oomichi"},"change_message_id":"be97a5742437b60f30dbb187ca186604d0b2f2a2","unresolved":false,"context_lines":[{"line_number":55,"context_line":"        # Check each cinder-volume host."},{"line_number":56,"context_line":"        host_detail_keys \u003d [\u0027project\u0027, \u0027volume_count\u0027, \u0027snapshot_count\u0027,"},{"line_number":57,"context_line":"                            \u0027host\u0027, \u0027total_volume_gb\u0027, \u0027total_snapshot_gb\u0027]"},{"line_number":58,"context_line":"        for host in c_vol_hosts:"},{"line_number":59,"context_line":"            host_details \u003d self.admin_hosts_client.show_host(host)[\u0027host\u0027]"},{"line_number":60,"context_line":"            self.assertNotEmpty(host_details)"},{"line_number":61,"context_line":"            for detail in host_details:"}],"source_content_type":"text/x-python","patch_set":7,"id":"7f287b81_62023e0c","line":58,"range":{"start_line":58,"start_character":8,"end_line":58,"end_character":32},"updated":"2017-08-31 18:17:54.000000000","message":"This patch makes the test check all available cinder services instead of random picking and the selecting way becomes strict, so LGTM","commit_id":"af55ae3b47e5b535b404267f4ce96b0dec237951"}]}
