)]}'
{"monasca_setup/detection/plugins/ceph.py":[{"author":{"_account_id":16688,"name":"Rodolfo Alonso","email":"ralonsoh@redhat.com","username":"rodolfo-alonso-hernandez"},"change_message_id":"8280ceded4ccf937722295c86929041998388b15","unresolved":false,"context_lines":[{"line_number":71,"context_line":"                search_strings.append(\" \".join(permutation))"},{"line_number":72,"context_line":"        return search_strings"},{"line_number":73,"context_line":""},{"line_number":74,"context_line":"    def _mon_config(self, cluster_name):"},{"line_number":75,"context_line":"        expected_processes \u003d list()"},{"line_number":76,"context_line":"        # Get the list of daemon identifiers"},{"line_number":77,"context_line":"        mon_list \u003d os.listdir(self.ceph_mon_path) \\"}],"source_content_type":"text/x-python","patch_set":6,"id":"dae33548_509fe74f","line":74,"updated":"2016-02-16 12:44:12.000000000","message":"_mon_config, _mds_config and _osd_config are very similar. Could be merge in only one function.","commit_id":"1a52b63e764c5e40de90c33b8c36530a5f8149a6"},{"author":{"_account_id":11730,"name":"Pradeep Kumar","email":"pradeep.av@hp.com","username":"avpra"},"change_message_id":"70564d09d5b8aed2a25158b3ce35b376683b867b","unresolved":false,"context_lines":[{"line_number":71,"context_line":"                search_strings.append(\" \".join(permutation))"},{"line_number":72,"context_line":"        return search_strings"},{"line_number":73,"context_line":""},{"line_number":74,"context_line":"    def _mon_config(self, cluster_name):"},{"line_number":75,"context_line":"        expected_processes \u003d list()"},{"line_number":76,"context_line":"        # Get the list of daemon identifiers"},{"line_number":77,"context_line":"        mon_list \u003d os.listdir(self.ceph_mon_path) \\"}],"source_content_type":"text/x-python","patch_set":6,"id":"dae33548_18745d66","line":74,"in_reply_to":"dae33548_509fe74f","updated":"2016-02-16 14:56:14.000000000","message":"That\u0027s a good idea, I will do that","commit_id":"1a52b63e764c5e40de90c33b8c36530a5f8149a6"},{"author":{"_account_id":16688,"name":"Rodolfo Alonso","email":"ralonsoh@redhat.com","username":"rodolfo-alonso-hernandez"},"change_message_id":"8280ceded4ccf937722295c86929041998388b15","unresolved":false,"context_lines":[{"line_number":151,"context_line":"        process[\u0027type\u0027] \u003d \u0027ceph-radosgw\u0027"},{"line_number":152,"context_line":""},{"line_number":153,"context_line":"        # Trivial configuration with only rados username"},{"line_number":154,"context_line":"        process_options \u003d [\u0027-n client.radosgw.\u0027,"},{"line_number":155,"context_line":"                           \u0027--name\u003dclient.radosgw.\u0027]"},{"line_number":156,"context_line":"        for opt in process_options:"},{"line_number":157,"context_line":"            process[\u0027search_string\u0027].extend(self._build_search_string("}],"source_content_type":"text/x-python","patch_set":6,"id":"dae33548_938cd980","line":154,"range":{"start_line":154,"start_character":38,"end_line":154,"end_character":45},"updated":"2016-02-16 12:44:12.000000000","message":"Client name should\u0027t be \u0027client.radosgw.gateway\u0027?","commit_id":"1a52b63e764c5e40de90c33b8c36530a5f8149a6"},{"author":{"_account_id":11730,"name":"Pradeep Kumar","email":"pradeep.av@hp.com","username":"avpra"},"change_message_id":"70564d09d5b8aed2a25158b3ce35b376683b867b","unresolved":false,"context_lines":[{"line_number":151,"context_line":"        process[\u0027type\u0027] \u003d \u0027ceph-radosgw\u0027"},{"line_number":152,"context_line":""},{"line_number":153,"context_line":"        # Trivial configuration with only rados username"},{"line_number":154,"context_line":"        process_options \u003d [\u0027-n client.radosgw.\u0027,"},{"line_number":155,"context_line":"                           \u0027--name\u003dclient.radosgw.\u0027]"},{"line_number":156,"context_line":"        for opt in process_options:"},{"line_number":157,"context_line":"            process[\u0027search_string\u0027].extend(self._build_search_string("}],"source_content_type":"text/x-python","patch_set":6,"id":"dae33548_18973d49","line":154,"range":{"start_line":154,"start_character":38,"end_line":154,"end_character":45},"in_reply_to":"dae33548_938cd980","updated":"2016-02-16 14:56:14.000000000","message":"the rados username is the username which is defined by user. Its conventionally \u0027gateway\u0027. But just keeping this open (like a regex) so that it matches any way. client.radosgw is however the constant part","commit_id":"1a52b63e764c5e40de90c33b8c36530a5f8149a6"},{"author":{"_account_id":16688,"name":"Rodolfo Alonso","email":"ralonsoh@redhat.com","username":"rodolfo-alonso-hernandez"},"change_message_id":"8280ceded4ccf937722295c86929041998388b15","unresolved":false,"context_lines":[{"line_number":160,"context_line":"        # Configuration with rados username and config file"},{"line_number":161,"context_line":"        process_options \u003d [\u0027-c %s\u0027 % config_file,"},{"line_number":162,"context_line":"                           \u0027--conf\u003d%s\u0027 % config_file,"},{"line_number":163,"context_line":"                           \u0027-n client.radosgw.\u0027,"},{"line_number":164,"context_line":"                           \u0027--name\u003dclient.radosgw.\u0027]"},{"line_number":165,"context_line":""},{"line_number":166,"context_line":"        for comb in itertools.combinations(process_options, 2):"}],"source_content_type":"text/x-python","patch_set":6,"id":"dae33548_33f4edf0","line":163,"updated":"2016-02-16 12:44:12.000000000","message":"ditto","commit_id":"1a52b63e764c5e40de90c33b8c36530a5f8149a6"},{"author":{"_account_id":16688,"name":"Rodolfo Alonso","email":"ralonsoh@redhat.com","username":"rodolfo-alonso-hernandez"},"change_message_id":"8280ceded4ccf937722295c86929041998388b15","unresolved":false,"context_lines":[{"line_number":163,"context_line":"                           \u0027-n client.radosgw.\u0027,"},{"line_number":164,"context_line":"                           \u0027--name\u003dclient.radosgw.\u0027]"},{"line_number":165,"context_line":""},{"line_number":166,"context_line":"        for comb in itertools.combinations(process_options, 2):"},{"line_number":167,"context_line":"            # Fetch all combinations, filter duplicate params and"},{"line_number":168,"context_line":"            # add all permutations to search_string"},{"line_number":169,"context_line":"            process_args \u003d \u0027 \u0027.join(comb)"}],"source_content_type":"text/x-python","patch_set":6,"id":"dae33548_536ed196","line":166,"updated":"2016-02-16 12:44:12.000000000","message":"http://docs.ceph.com/docs/hammer/man/8/\nWhy do you need to test: -c -n, --conf -n, -c --name, --conf --name? All this commands should return the same answer.","commit_id":"1a52b63e764c5e40de90c33b8c36530a5f8149a6"},{"author":{"_account_id":11730,"name":"Pradeep Kumar","email":"pradeep.av@hp.com","username":"avpra"},"change_message_id":"70564d09d5b8aed2a25158b3ce35b376683b867b","unresolved":false,"context_lines":[{"line_number":163,"context_line":"                           \u0027-n client.radosgw.\u0027,"},{"line_number":164,"context_line":"                           \u0027--name\u003dclient.radosgw.\u0027]"},{"line_number":165,"context_line":""},{"line_number":166,"context_line":"        for comb in itertools.combinations(process_options, 2):"},{"line_number":167,"context_line":"            # Fetch all combinations, filter duplicate params and"},{"line_number":168,"context_line":"            # add all permutations to search_string"},{"line_number":169,"context_line":"            process_args \u003d \u0027 \u0027.join(comb)"}],"source_content_type":"text/x-python","patch_set":6,"id":"dae33548_384b21b2","line":166,"in_reply_to":"dae33548_536ed196","updated":"2016-02-16 14:56:14.000000000","message":"That\u0027s precisely the point. The end user might have the service definition configured to have any of the combination in the process string as all achieve the same.\n\nEg. In one machine the process string might be:\n/usr/bin/radosgw -c /etc/ceph/ceph.conf -n client.radosgw.gateway\n\nand in another:\n/usr/bin/radosgw --conf /etc/ceph/ceph.conf -n client.radosgw.gateway\n\nThe search string must capture any combination (at least the most trivial cases)\n\nHence there is the use of combinatorics over here","commit_id":"1a52b63e764c5e40de90c33b8c36530a5f8149a6"},{"author":{"_account_id":1633,"name":"unmesh-gurjar","email":"unmesh.gurjar@hp.com","username":"unmesh-gurjar"},"change_message_id":"211b82d945ddb4cd41d87900bc7191f52fa82686","unresolved":false,"context_lines":[{"line_number":86,"context_line":"        expected_processes \u003d list()"},{"line_number":87,"context_line":"        # Get the list of daemon identifiers"},{"line_number":88,"context_line":"        instance_list \u003d os.listdir(service_dir) \\"},{"line_number":89,"context_line":"            if os.path.exists(service_dir) else list()"},{"line_number":90,"context_line":""},{"line_number":91,"context_line":"        for instance in instance_list:"},{"line_number":92,"context_line":"            # Daemon identifier is of format \u003ccluster_name\u003e-\u003cid\u003e"}],"source_content_type":"text/x-python","patch_set":7,"id":"dae33548_2e2e0ea5","line":89,"range":{"start_line":89,"start_character":23,"end_line":89,"end_character":29},"updated":"2016-02-17 08:57:00.000000000","message":"Just a suggestion, can use filter as below:\ninstance_list \u003d filter(os.path.exists, os.listdir(service_dir))","commit_id":"61e64745552265e3bf97a9aed84f36c1f0fe396b"},{"author":{"_account_id":11730,"name":"Pradeep Kumar","email":"pradeep.av@hp.com","username":"avpra"},"change_message_id":"55a7aebe0ebaed10bd680cea66032ef04d5bb940","unresolved":false,"context_lines":[{"line_number":86,"context_line":"        expected_processes \u003d list()"},{"line_number":87,"context_line":"        # Get the list of daemon identifiers"},{"line_number":88,"context_line":"        instance_list \u003d os.listdir(service_dir) \\"},{"line_number":89,"context_line":"            if os.path.exists(service_dir) else list()"},{"line_number":90,"context_line":""},{"line_number":91,"context_line":"        for instance in instance_list:"},{"line_number":92,"context_line":"            # Daemon identifier is of format \u003ccluster_name\u003e-\u003cid\u003e"}],"source_content_type":"text/x-python","patch_set":7,"id":"9aed3d3a_be3c7930","line":89,"range":{"start_line":89,"start_character":23,"end_line":89,"end_character":29},"in_reply_to":"dae33548_2e2e0ea5","updated":"2016-02-26 05:22:25.000000000","message":"Will this not fail at os.listdir(service_dir) if service_dir doesn\u0027t exist ? To avoid that I wrote the other way.","commit_id":"61e64745552265e3bf97a9aed84f36c1f0fe396b"},{"author":{"_account_id":1633,"name":"unmesh-gurjar","email":"unmesh.gurjar@hp.com","username":"unmesh-gurjar"},"change_message_id":"211b82d945ddb4cd41d87900bc7191f52fa82686","unresolved":false,"context_lines":[{"line_number":154,"context_line":""},{"line_number":155,"context_line":"        # Default cluster name"},{"line_number":156,"context_line":"        cluster_name \u003d \u0027ceph\u0027"},{"line_number":157,"context_line":"        config_file \u003d \u0027/etc/ceph/ceph.conf\u0027"},{"line_number":158,"context_line":""},{"line_number":159,"context_line":"        # Get the cluster_name from \u003ccluster_name\u003e.conf in /etc/ceph/ directory"},{"line_number":160,"context_line":"        if os.path.exists(self.ceph_config_dir):"}],"source_content_type":"text/x-python","patch_set":7,"id":"dae33548_4e06f21d","line":157,"range":{"start_line":157,"start_character":28,"end_line":157,"end_character":32},"updated":"2016-02-17 08:57:00.000000000","message":"Would be better to define it as:\nconfig_file \u003d os.path.join(self.ceph_config_dir, \u0027%s.conf\u0027 % cluster_name)","commit_id":"61e64745552265e3bf97a9aed84f36c1f0fe396b"},{"author":{"_account_id":11730,"name":"Pradeep Kumar","email":"pradeep.av@hp.com","username":"avpra"},"change_message_id":"55a7aebe0ebaed10bd680cea66032ef04d5bb940","unresolved":false,"context_lines":[{"line_number":154,"context_line":""},{"line_number":155,"context_line":"        # Default cluster name"},{"line_number":156,"context_line":"        cluster_name \u003d \u0027ceph\u0027"},{"line_number":157,"context_line":"        config_file \u003d \u0027/etc/ceph/ceph.conf\u0027"},{"line_number":158,"context_line":""},{"line_number":159,"context_line":"        # Get the cluster_name from \u003ccluster_name\u003e.conf in /etc/ceph/ directory"},{"line_number":160,"context_line":"        if os.path.exists(self.ceph_config_dir):"}],"source_content_type":"text/x-python","patch_set":7,"id":"9aed3d3a_7e1151ac","line":157,"range":{"start_line":157,"start_character":28,"end_line":157,"end_character":32},"in_reply_to":"dae33548_4e06f21d","updated":"2016-02-26 05:22:25.000000000","message":"This is just the default location. I have added this in the below section where specific config file is used","commit_id":"61e64745552265e3bf97a9aed84f36c1f0fe396b"}]}
