)]}'
{"barbican/templates/secret-mq.yaml":[{"author":{"_account_id":23928,"name":"Pete Birley","email":"petebirley@gmail.com","username":"portdirect"},"change_message_id":"f619ec67c8b31fa788a140b392fba0d32fc38d96","unresolved":false,"context_lines":[{"line_number":26,"context_line":"type: Opaque"},{"line_number":27,"context_line":"data:"},{"line_number":28,"context_line":"  MQ_CONNECTION: {{ tuple \"oslo_messaging\" \"internal\" $userClass \"amqp\" $envAll | include \"helm-toolkit.endpoints.authenticated_endpoint_uri_lookup\" | b64enc }}"},{"line_number":29,"context_line":"  ROOT_MQ_CONNECTION: {{ tuple \"oslo_messaging\" \"internal\" $userClass \"http\" $envAll | include \"helm-toolkit.endpoints.authenticated_endpoint_uri_lookup\" | b64enc -}}"},{"line_number":30,"context_line":"{{- end }}"},{"line_number":31,"context_line":"{{- end }}"}],"source_content_type":"text/x-yaml","patch_set":8,"id":"7f287b81_f8bb0ce2","line":29,"range":{"start_line":29,"start_character":2,"end_line":29,"end_character":7},"updated":"2017-09-06 14:29:42.000000000","message":"should this not be something other than root? ie MANAGEMENT or similar?","commit_id":"37b4a0d2a75367fdd74d4bfc94222fd29d6488d6"},{"author":{"_account_id":14250,"name":"Grzegorz Grasza","email":"xek@redhat.com","username":"xek"},"change_message_id":"05c3f4660849321bb23ef482a152bddee28794f2","unresolved":false,"context_lines":[{"line_number":26,"context_line":"type: Opaque"},{"line_number":27,"context_line":"data:"},{"line_number":28,"context_line":"  MQ_CONNECTION: {{ tuple \"oslo_messaging\" \"internal\" $userClass \"amqp\" $envAll | include \"helm-toolkit.endpoints.authenticated_endpoint_uri_lookup\" | b64enc }}"},{"line_number":29,"context_line":"  ROOT_MQ_CONNECTION: {{ tuple \"oslo_messaging\" \"internal\" $userClass \"http\" $envAll | include \"helm-toolkit.endpoints.authenticated_endpoint_uri_lookup\" | b64enc -}}"},{"line_number":30,"context_line":"{{- end }}"},{"line_number":31,"context_line":"{{- end }}"}],"source_content_type":"text/x-yaml","patch_set":8,"id":"5f2577a7_c5a66254","line":29,"range":{"start_line":29,"start_character":2,"end_line":29,"end_character":7},"in_reply_to":"7f287b81_f8bb0ce2","updated":"2017-09-12 15:10:42.000000000","message":"I made this consistent with _db-init.py.tpl and _mq-init.py.tpl scripts.","commit_id":"37b4a0d2a75367fdd74d4bfc94222fd29d6488d6"}],"helm-toolkit/templates/scripts/_mq-init.py.tpl":[{"author":{"_account_id":11636,"name":"Mateusz Blaszkowski","email":"mateusz.blaszkowski@intel.com","username":"mateuszb"},"change_message_id":"e49ace21fa8d6346dac232170f3903d3fa8e50a2","unresolved":false,"context_lines":[{"line_number":53,"context_line":""},{"line_number":54,"context_line":"# Get the connection string for the service mq"},{"line_number":55,"context_line":"if \"OPENSTACK_CONFIG_FILE\" in os.environ:"},{"line_number":56,"context_line":"    try:"},{"line_number":57,"context_line":"        os_conf \u003d os.environ[\u0027OPENSTACK_CONFIG_FILE\u0027]"},{"line_number":58,"context_line":"        if \"OPENSTACK_CONFIG_MQ_SECTION\" in os.environ:"},{"line_number":59,"context_line":"            os_conf_section \u003d os.environ[\u0027OPENSTACK_CONFIG_MQ_SECTION\u0027]"}],"source_content_type":"text/x-smarty","patch_set":2,"id":"9f436f4f_046f112b","line":56,"updated":"2017-08-17 08:50:51.000000000","message":"\u0027try\u0027 statement should begin right before ConfigParser usage","commit_id":"1ae30034b93a8fe1541897f68d6cde2d8bc6d57f"},{"author":{"_account_id":14250,"name":"Grzegorz Grasza","email":"xek@redhat.com","username":"xek"},"change_message_id":"f76fc9f928365cacccf9d22da64d0558ab18dc8a","unresolved":false,"context_lines":[{"line_number":53,"context_line":""},{"line_number":54,"context_line":"# Get the connection string for the service mq"},{"line_number":55,"context_line":"if \"OPENSTACK_CONFIG_FILE\" in os.environ:"},{"line_number":56,"context_line":"    try:"},{"line_number":57,"context_line":"        os_conf \u003d os.environ[\u0027OPENSTACK_CONFIG_FILE\u0027]"},{"line_number":58,"context_line":"        if \"OPENSTACK_CONFIG_MQ_SECTION\" in os.environ:"},{"line_number":59,"context_line":"            os_conf_section \u003d os.environ[\u0027OPENSTACK_CONFIG_MQ_SECTION\u0027]"}],"source_content_type":"text/x-smarty","patch_set":2,"id":"7f287b81_ee5886fa","line":56,"in_reply_to":"9f436f4f_046f112b","updated":"2017-08-30 12:10:20.000000000","message":"Done","commit_id":"1ae30034b93a8fe1541897f68d6cde2d8bc6d57f"},{"author":{"_account_id":11636,"name":"Mateusz Blaszkowski","email":"mateusz.blaszkowski@intel.com","username":"mateuszb"},"change_message_id":"e49ace21fa8d6346dac232170f3903d3fa8e50a2","unresolved":false,"context_lines":[{"line_number":72,"context_line":"            os_conf_section, os_conf_key))"},{"line_number":73,"context_line":"        user_mq_conn \u003d config.get(os_conf_section, os_conf_key)"},{"line_number":74,"context_line":"        logger.info(\"Got config from {0}\".format(os_conf))"},{"line_number":75,"context_line":"    except:"},{"line_number":76,"context_line":"        logger.critical(\"Tried to load config from {0} but failed.\".format(os_conf))"},{"line_number":77,"context_line":"        sys.exit(1)"},{"line_number":78,"context_line":"elif \"MQ_CONNECTION\" in os.environ:"}],"source_content_type":"text/x-smarty","patch_set":2,"id":"9f436f4f_04103156","line":75,"updated":"2017-08-17 08:50:51.000000000","message":"I\u0027d recommend catching ConfigParser exceptions (NoSectionError, NoOptionError) so that logs can be more verbose","commit_id":"1ae30034b93a8fe1541897f68d6cde2d8bc6d57f"},{"author":{"_account_id":14250,"name":"Grzegorz Grasza","email":"xek@redhat.com","username":"xek"},"change_message_id":"f76fc9f928365cacccf9d22da64d0558ab18dc8a","unresolved":false,"context_lines":[{"line_number":72,"context_line":"            os_conf_section, os_conf_key))"},{"line_number":73,"context_line":"        user_mq_conn \u003d config.get(os_conf_section, os_conf_key)"},{"line_number":74,"context_line":"        logger.info(\"Got config from {0}\".format(os_conf))"},{"line_number":75,"context_line":"    except:"},{"line_number":76,"context_line":"        logger.critical(\"Tried to load config from {0} but failed.\".format(os_conf))"},{"line_number":77,"context_line":"        sys.exit(1)"},{"line_number":78,"context_line":"elif \"MQ_CONNECTION\" in os.environ:"}],"source_content_type":"text/x-smarty","patch_set":2,"id":"7f287b81_eecac69e","line":75,"in_reply_to":"9f436f4f_04103156","updated":"2017-08-30 12:10:20.000000000","message":"I added a \u0027raise\u0027 so that the full stacktrace is visible in the log output.","commit_id":"1ae30034b93a8fe1541897f68d6cde2d8bc6d57f"},{"author":{"_account_id":11636,"name":"Mateusz Blaszkowski","email":"mateusz.blaszkowski@intel.com","username":"mateuszb"},"change_message_id":"e49ace21fa8d6346dac232170f3903d3fa8e50a2","unresolved":false,"context_lines":[{"line_number":79,"context_line":"    user_mq_conn \u003d os.environ[\u0027MQ_CONNECTION\u0027]"},{"line_number":80,"context_line":"    logger.info(\u0027Got config from MQ_CONNECTION env var\u0027)"},{"line_number":81,"context_line":"else:"},{"line_number":82,"context_line":"    logger.critical(\u0027Could not get mq config, either from config file or env var\u0027)"},{"line_number":83,"context_line":"    sys.exit(1)"},{"line_number":84,"context_line":""},{"line_number":85,"context_line":""}],"source_content_type":"text/x-smarty","patch_set":2,"id":"9f436f4f_2401f56a","line":82,"updated":"2017-08-17 08:50:51.000000000","message":"I\u0027d be worth mentioning which environment variables are not set","commit_id":"1ae30034b93a8fe1541897f68d6cde2d8bc6d57f"},{"author":{"_account_id":11636,"name":"Mateusz Blaszkowski","email":"mateusz.blaszkowski@intel.com","username":"mateuszb"},"change_message_id":"79231d3f755cf228334633ed36fc2c4e3e3e1e1e","unresolved":false,"context_lines":[{"line_number":79,"context_line":"    user_mq_conn \u003d os.environ[\u0027MQ_CONNECTION\u0027]"},{"line_number":80,"context_line":"    logger.info(\u0027Got config from MQ_CONNECTION env var\u0027)"},{"line_number":81,"context_line":"else:"},{"line_number":82,"context_line":"    logger.critical(\u0027Could not get mq config, either from config file or env var\u0027)"},{"line_number":83,"context_line":"    sys.exit(1)"},{"line_number":84,"context_line":""},{"line_number":85,"context_line":""}],"source_content_type":"text/x-smarty","patch_set":2,"id":"7f287b81_3a49f68a","line":82,"in_reply_to":"7f287b81_2e31eea3","updated":"2017-09-01 07:33:25.000000000","message":"Looking at the script it is obvious. However when user gets only the log message \u0027Could not get mq config, either from config file or env var\u0027 he won\u0027t now which of the env variable should be set in order to make it working properly.","commit_id":"1ae30034b93a8fe1541897f68d6cde2d8bc6d57f"},{"author":{"_account_id":14250,"name":"Grzegorz Grasza","email":"xek@redhat.com","username":"xek"},"change_message_id":"f76fc9f928365cacccf9d22da64d0558ab18dc8a","unresolved":false,"context_lines":[{"line_number":79,"context_line":"    user_mq_conn \u003d os.environ[\u0027MQ_CONNECTION\u0027]"},{"line_number":80,"context_line":"    logger.info(\u0027Got config from MQ_CONNECTION env var\u0027)"},{"line_number":81,"context_line":"else:"},{"line_number":82,"context_line":"    logger.critical(\u0027Could not get mq config, either from config file or env var\u0027)"},{"line_number":83,"context_line":"    sys.exit(1)"},{"line_number":84,"context_line":""},{"line_number":85,"context_line":""}],"source_content_type":"text/x-smarty","patch_set":2,"id":"7f287b81_2e31eea3","line":82,"in_reply_to":"9f436f4f_2401f56a","updated":"2017-08-30 12:10:20.000000000","message":"They were both not set at this point.","commit_id":"1ae30034b93a8fe1541897f68d6cde2d8bc6d57f"},{"author":{"_account_id":11636,"name":"Mateusz Blaszkowski","email":"mateusz.blaszkowski@intel.com","username":"mateuszb"},"change_message_id":"e49ace21fa8d6346dac232170f3903d3fa8e50a2","unresolved":false,"context_lines":[{"line_number":105,"context_line":"    assert \u0027administrator\u0027 in json.loads(result.read())[\u0027tags\u0027]"},{"line_number":106,"context_line":"    logger.info(\"Tested connection to MQ @ {0}:{1} as {2}\".format("},{"line_number":107,"context_line":"        mq_conn_parsed.host, mq_conn_parsed.port, mq_conn_parsed.username))"},{"line_number":108,"context_line":"except:"},{"line_number":109,"context_line":"    logger.critical(\u0027Could not connect to mesage queue as root (default) user\u0027)"},{"line_number":110,"context_line":"    raise"},{"line_number":111,"context_line":"    sys.exit(1)"}],"source_content_type":"text/x-smarty","patch_set":2,"id":"9f436f4f_8739c3a4","line":108,"updated":"2017-08-17 08:50:51.000000000","message":"It can fail because of multiple reasons. I think log information should be more explicit.","commit_id":"1ae30034b93a8fe1541897f68d6cde2d8bc6d57f"},{"author":{"_account_id":11636,"name":"Mateusz Blaszkowski","email":"mateusz.blaszkowski@intel.com","username":"mateuszb"},"change_message_id":"e49ace21fa8d6346dac232170f3903d3fa8e50a2","unresolved":false,"context_lines":[{"line_number":107,"context_line":"        mq_conn_parsed.host, mq_conn_parsed.port, mq_conn_parsed.username))"},{"line_number":108,"context_line":"except:"},{"line_number":109,"context_line":"    logger.critical(\u0027Could not connect to mesage queue as root (default) user\u0027)"},{"line_number":110,"context_line":"    raise"},{"line_number":111,"context_line":"    sys.exit(1)"},{"line_number":112,"context_line":""},{"line_number":113,"context_line":"# Test User MQ connection string"}],"source_content_type":"text/x-smarty","patch_set":2,"id":"9f436f4f_04cef161","line":110,"updated":"2017-08-17 08:50:51.000000000","message":"You can only raise \u0027Exception\u0027 type of objects, this line will raise an exception:\n\n  TypeError: exceptions must be old-style classes or derived from BaseException, not NoneType\n\nHowever I believe you didn\u0027t want to use both raise and sys.exit() one after another (both of them will terminate the script).","commit_id":"1ae30034b93a8fe1541897f68d6cde2d8bc6d57f"},{"author":{"_account_id":14250,"name":"Grzegorz Grasza","email":"xek@redhat.com","username":"xek"},"change_message_id":"f76fc9f928365cacccf9d22da64d0558ab18dc8a","unresolved":false,"context_lines":[{"line_number":107,"context_line":"        mq_conn_parsed.host, mq_conn_parsed.port, mq_conn_parsed.username))"},{"line_number":108,"context_line":"except:"},{"line_number":109,"context_line":"    logger.critical(\u0027Could not connect to mesage queue as root (default) user\u0027)"},{"line_number":110,"context_line":"    raise"},{"line_number":111,"context_line":"    sys.exit(1)"},{"line_number":112,"context_line":""},{"line_number":113,"context_line":"# Test User MQ connection string"}],"source_content_type":"text/x-smarty","patch_set":2,"id":"7f287b81_2ebfaed1","line":110,"in_reply_to":"9f436f4f_04cef161","updated":"2017-08-30 12:10:20.000000000","message":"Yes the sys.exit() was a c\u0026paste from the db-init script, I removed it.\n\nIn this case \u0027raise\u0027 re-raises the caught exception.","commit_id":"1ae30034b93a8fe1541897f68d6cde2d8bc6d57f"},{"author":{"_account_id":11636,"name":"Mateusz Blaszkowski","email":"mateusz.blaszkowski@intel.com","username":"mateuszb"},"change_message_id":"1a3ca51edc5ff6980f3831efd0772f38e1eac1e8","unresolved":false,"context_lines":[{"line_number":93,"context_line":"    mq_conn_parsed \u003d urlparse.urlparse(mq_connection)"},{"line_number":94,"context_line":"    pass_mgr \u003d urllib2.HTTPPasswordMgrWithDefaultRealm()"},{"line_number":95,"context_line":"    top_level_url \u003d \u0027{}://{}:{}/\u0027.format(\u0027http\u0027, mq_conn_parsed.hostname,"},{"line_number":96,"context_line":"                                         mq_conn_parsed.port + 10000)"},{"line_number":97,"context_line":"    pass_mgr.add_password(None, top_level_url, mq_conn_parsed.username,"},{"line_number":98,"context_line":"                                               mq_conn_parsed.password)"},{"line_number":99,"context_line":"    handler \u003d urllib2.HTTPBasicAuthHandler(pass_mgr)"}],"source_content_type":"text/x-smarty","patch_set":5,"id":"7f287b81_5ca83fda","line":96,"updated":"2017-09-01 07:39:53.000000000","message":"This at least needs a comment although I don\u0027t think it\u0027s always true that management_port is equal port + 10000. If port is set to a non-default value (i.e. 5671), management port remains to be 15672, doesn\u0027t it? Please correct me if I\u0027m wrong","commit_id":"06cdfdbe470f54f33b9b69919ed272d25f10809a"},{"author":{"_account_id":11636,"name":"Mateusz Blaszkowski","email":"mateusz.blaszkowski@intel.com","username":"mateuszb"},"change_message_id":"c55ff1ea13c12ab67fa2425d960122f932f1bdcd","unresolved":false,"context_lines":[{"line_number":93,"context_line":"    mq_conn_parsed \u003d urlparse.urlparse(mq_connection)"},{"line_number":94,"context_line":"    pass_mgr \u003d urllib2.HTTPPasswordMgrWithDefaultRealm()"},{"line_number":95,"context_line":"    top_level_url \u003d \u0027{}://{}:{}/\u0027.format(\u0027http\u0027, mq_conn_parsed.hostname,"},{"line_number":96,"context_line":"                                         mq_conn_parsed.port + 10000)"},{"line_number":97,"context_line":"    pass_mgr.add_password(None, top_level_url, mq_conn_parsed.username,"},{"line_number":98,"context_line":"                                               mq_conn_parsed.password)"},{"line_number":99,"context_line":"    handler \u003d urllib2.HTTPBasicAuthHandler(pass_mgr)"}],"source_content_type":"text/x-smarty","patch_set":5,"id":"7f287b81_45ca9e4f","line":96,"in_reply_to":"7f287b81_22d668c5","updated":"2017-09-01 10:24:32.000000000","message":"As we agreed on F2F, management port should be configurable (this means adding necessary section in rabbitmq.config) and passed separately in each service","commit_id":"06cdfdbe470f54f33b9b69919ed272d25f10809a"},{"author":{"_account_id":14250,"name":"Grzegorz Grasza","email":"xek@redhat.com","username":"xek"},"change_message_id":"bf3a7880fac93541ab40ecd4fd2e08de9be74c3d","unresolved":false,"context_lines":[{"line_number":93,"context_line":"    mq_conn_parsed \u003d urlparse.urlparse(mq_connection)"},{"line_number":94,"context_line":"    pass_mgr \u003d urllib2.HTTPPasswordMgrWithDefaultRealm()"},{"line_number":95,"context_line":"    top_level_url \u003d \u0027{}://{}:{}/\u0027.format(\u0027http\u0027, mq_conn_parsed.hostname,"},{"line_number":96,"context_line":"                                         mq_conn_parsed.port + 10000)"},{"line_number":97,"context_line":"    pass_mgr.add_password(None, top_level_url, mq_conn_parsed.username,"},{"line_number":98,"context_line":"                                               mq_conn_parsed.password)"},{"line_number":99,"context_line":"    handler \u003d urllib2.HTTPBasicAuthHandler(pass_mgr)"}],"source_content_type":"text/x-smarty","patch_set":5,"id":"7f287b81_22d668c5","line":96,"in_reply_to":"7f287b81_5ca83fda","updated":"2017-09-01 09:44:17.000000000","message":"You\u0027re right... Do you think making it static would be acceptable?","commit_id":"06cdfdbe470f54f33b9b69919ed272d25f10809a"}]}
