)]}'
{"bin/trove-guestagent":[{"author":{"_account_id":1925,"name":"Vipul Sabhaya","email":"vipuls@gmail.com","username":"vipuls"},"change_message_id":"bd592eaf7ac4eaa031e22bf15c2267fb9f964607","unresolved":false,"context_lines":[{"line_number":55,"context_line":""},{"line_number":56,"context_line":"    try:"},{"line_number":57,"context_line":"        get_db_api().configure_db(CONF)"},{"line_number":58,"context_line":"        managers \u003d CONF.db_managers.split(\",\")"},{"line_number":59,"context_line":"        manager \u003d None"},{"line_number":60,"context_line":"        service_type \u003d CONF.service_type"},{"line_number":61,"context_line":"        if service_type \u003d\u003d \u0027percona\u0027:"}],"source_content_type":"application/octet-stream","patch_set":2,"id":"AAAAQ3%2F%2F604%3D","line":58,"updated":"2013-08-13 00:13:16.000000000","message":"It seems we need a way to load a Manager that may not be in the SERVICE_REGISTRY.  So i\u0027m proposing this:  Why not have a config variable in the guestagent.conf like \u0027guest_manager\u0027, which if present overrides the service_type lookup?","commit_id":"ca9e6f3c1a2f49b196ea27a0b484622bc50014b8"},{"author":{"_account_id":1925,"name":"Vipul Sabhaya","email":"vipuls@gmail.com","username":"vipuls"},"change_message_id":"cf24f5970219f581496caf609fc8d82a058c4692","unresolved":false,"context_lines":[{"line_number":48,"context_line":"CONF.register_opts([openstack_cfg.StrOpt(\u0027guestagent_manager\u0027),"},{"line_number":49,"context_line":"                     openstack_cfg.StrOpt(\u0027guest_id\u0027),"},{"line_number":50,"context_line":"                    openstack_cfg.StrOpt(\u0027trove_guestagent_manager_mysql\u0027),"},{"line_number":51,"context_line":"                    openstack_cfg.StrOpt(\u0027trove_guestagent_manager_percona\u0027)])"},{"line_number":52,"context_line":""},{"line_number":53,"context_line":"if __name__ \u003d\u003d \u0027__main__\u0027:"},{"line_number":54,"context_line":"    cfg.parse_args(sys.argv)"}],"source_content_type":"application/octet-stream","patch_set":3,"id":"AAAARH%2F%2F7qs%3D","line":51,"updated":"2013-08-15 01:00:11.000000000","message":"This change still requires a code change to add another manager.  Can we do the DictOpt here too?","commit_id":"d39dcb4640210c5311867c490f847b1329e7ae8b"},{"author":{"_account_id":694,"name":"Tim Simpson","email":"tim.simpson@rackspace.com","username":"tim-simpson"},"change_message_id":"fdcaf98ae28979d77fc53058363e433f6f91e31b","unresolved":false,"context_lines":[{"line_number":56,"context_line":"    try:"},{"line_number":57,"context_line":"        get_db_api().configure_db(CONF)"},{"line_number":58,"context_line":"        manager_dict \u003d CONF.trove_guestagent_manager"},{"line_number":59,"context_line":"        manager \u003d manager_dict[CONF.service_type]"},{"line_number":60,"context_line":"        server \u003d rpc.RpcService(manager\u003dmanager, host\u003dCONF.guest_id)"},{"line_number":61,"context_line":"        launcher \u003d service.launch(server)"},{"line_number":62,"context_line":"        launcher.wait()"}],"source_content_type":"application/octet-stream","patch_set":7,"id":"AAAASn%2F%2FdkI%3D","line":59,"updated":"2013-09-04 14:42:43.000000000","message":"I can understand making the manager class come from a config file. However, why store an entire dictionary in the config file just to then also store a key to that dictionary in the config file, read the one value from the dictionary that you want, and then throw the rest away? \n\nTo rephrase, I\u0027m wondering why store an entire dictionary in the config file when only a single element is needed.","commit_id":"5e961d62ce1f4940de656b0ac8986d6dffafe3af"},{"author":{"_account_id":8309,"name":"Pradeep Kumar Chandani","email":"chandani.pradeep@gmail.com","username":"pradeepchandani"},"change_message_id":"eb714f2ce9d0266653d00a2b2130fe82bbfbbc86","unresolved":false,"context_lines":[{"line_number":56,"context_line":"    try:"},{"line_number":57,"context_line":"        get_db_api().configure_db(CONF)"},{"line_number":58,"context_line":"        manager_dict \u003d CONF.trove_guestagent_manager"},{"line_number":59,"context_line":"        manager \u003d manager_dict[CONF.service_type]"},{"line_number":60,"context_line":"        server \u003d rpc.RpcService(manager\u003dmanager, host\u003dCONF.guest_id)"},{"line_number":61,"context_line":"        launcher \u003d service.launch(server)"},{"line_number":62,"context_line":"        launcher.wait()"}],"source_content_type":"application/octet-stream","patch_set":7,"id":"AAAASn%2F%2FdQI%3D","line":59,"in_reply_to":"AAAASn%2F%2FdkI%3D","updated":"2013-09-20 06:43:16.000000000","message":"Thanks Simpson, \n\ni  value your observation here are my comments : \n\n\"I can understand making the manager class come from a config file. However, why store an entire dictionary in the config file just to then also store a key to that dictionary in the config file, read the one value from the dictionary that you want, and then throw the rest away? \"\n\npoints taken, code will be modified in the next change-set\n\n\"To rephrase, I\u0027m wondering why store an entire dictionary in the config file when only a single element is needed.\"\n\nhere we need to abstract the manager for different database, as mysql, mariadb, percona are of same origin a single manager is working fine but in case of other databases coming in future, we may need one \"service_type: manager\"  key value pair reflecting them","commit_id":"5e961d62ce1f4940de656b0ac8986d6dffafe3af"},{"author":{"_account_id":739,"name":"Michael Basnight","email":"mbasnight@gmail.com","username":"hubcap"},"change_message_id":"0a512607fe3639ee86de96608f38b8d68b527daf","unresolved":false,"context_lines":[{"line_number":58,"context_line":"        get_db_api().configure_db(CONF)"},{"line_number":59,"context_line":"        manager \u003d dbaas.SERVICE_REGISTRY.get(CONF.service_type)"},{"line_number":60,"context_line":"        if not manager:"},{"line_number":61,"context_line":"            manager \u003d getattr(CONF, service_key)"},{"line_number":62,"context_line":"        server \u003d rpc.RpcService(manager\u003dmanager, host\u003dCONF.guest_id)"},{"line_number":63,"context_line":"        launcher \u003d service.launch(server)"},{"line_number":64,"context_line":"        launcher.wait()"}],"source_content_type":"application/octet-stream","patch_set":10,"id":"AAAAS3%2F%2FTVc%3D","line":61,"updated":"2013-09-30 15:50:34.000000000","message":"Id like to see a raise Exception with useful message, if manager is None.","commit_id":"f3e391f74b6a449f8807b2af033c4d7b3ae4454c"}],"etc/trove/trove-guestagent.conf.sample":[{"author":{"_account_id":1925,"name":"Vipul Sabhaya","email":"vipuls@gmail.com","username":"vipuls"},"change_message_id":"64d0da177a30d8c8d22e410e51b64b3423c07b62","unresolved":false,"context_lines":[{"line_number":80,"context_line":""},{"line_number":81,"context_line":"# Service_Registry"},{"line_number":82,"context_line":"trove_guestagent_manager \u003d mysql: trove.guestagent.manager.mysql.Manager,"},{"line_number":83,"context_line":"                           percona: trove.guestagent.manager.mysql.Manager"}],"source_content_type":"application/octet-stream","patch_set":4,"id":"AAAASn%2F%2F8JU%3D","line":83,"updated":"2013-08-27 18:52:45.000000000","message":"Have you tested this works? It might have to be in one line or multiple lines with the same key name..\n\nhttps://github.com/openstack/oslo.config/blob/master/tests/test_cfg.py#L1053","commit_id":"f8256c85fd91c7e7a6d43edecc7964ead3a26688"}],"trove/common/cfg.py":[{"author":{"_account_id":8415,"name":"Denis M.","email":"lildee1991@gmail.com","username":"dmakogon"},"change_message_id":"e0fc9c112813b1523bb7923a74dcddc8b8ed6ca6","unresolved":false,"context_lines":[{"line_number":199,"context_line":"               default\u003d\u0027$pybasedir/etc/trove/trove-guestagent.conf.sample\u0027,"},{"line_number":200,"context_line":"               help\u003d\"Path to guestagent config file\"),"},{"line_number":201,"context_line":"    cfg.DictOpt(\u0027service_registry_ext\u0027, default\u003ddict(),"},{"line_number":202,"context_line":"                help\u003d\"dict of managers\"),"},{"line_number":203,"context_line":"]"},{"line_number":204,"context_line":""},{"line_number":205,"context_line":""}],"source_content_type":"text/x-python","patch_set":13,"id":"AAAATH%2F%2F9ak%3D","line":202,"updated":"2013-10-07 13:49:17.000000000","message":"Please, write meaningful description for this parameter.  Such as \" Extention for default service managers. Allows to use custom managers for each of service type supported in trove\"","commit_id":"7ca1aedb91c54da5c1c00897348773ce74fdbffe"}],"trove/guestagent/dbaas.py":[{"author":{"_account_id":8415,"name":"Denis M.","email":"lildee1991@gmail.com","username":"dmakogon"},"change_message_id":"dcc300cf8c01d486bf0960a3d4120373b509fd8c","unresolved":false,"context_lines":[{"line_number":47,"context_line":""},{"line_number":48,"context_line":"def service_registry():"},{"line_number":49,"context_line":"    return dict(chain(get_custom_managers().iteritems(),"},{"line_number":50,"context_line":"                      defaults.iteritems()))"},{"line_number":51,"context_line":""},{"line_number":52,"context_line":""},{"line_number":53,"context_line":"def to_gb(bytes):"}],"source_content_type":"text/x-python","patch_set":13,"id":"AAAATH%2F%2F9Uw%3D","line":50,"updated":"2013-10-07 13:58:50.000000000","message":"Please, swap this values. Because it would cause overring by defaults issue.","commit_id":"7ca1aedb91c54da5c1c00897348773ce74fdbffe"},{"author":{"_account_id":8491,"name":"Illia Khudoshyn","email":"ikhudoshyn@mirantis.com","username":"ikhudoshyn"},"change_message_id":"71c80425a732630c9c9d140029ba0abaccfbc900","unresolved":false,"context_lines":[{"line_number":47,"context_line":""},{"line_number":48,"context_line":"def service_registry():"},{"line_number":49,"context_line":"    return dict(chain(get_custom_managers().iteritems(),"},{"line_number":50,"context_line":"                      defaults.iteritems()))"},{"line_number":51,"context_line":""},{"line_number":52,"context_line":""},{"line_number":53,"context_line":"def to_gb(bytes):"}],"source_content_type":"text/x-python","patch_set":13,"id":"AAAATH%2F%2F9VQ%3D","line":50,"updated":"2013-10-07 13:58:11.000000000","message":"This will effectively override custom configured mappings with defaults. E.g. if customer provides its own manager for \u0027mysql\u0027 it will have no effect, and a manager from defaults will be used. It is not a behavior that I, as user, would expect.","commit_id":"7ca1aedb91c54da5c1c00897348773ce74fdbffe"}],"trove/tests/unittests/guestagent/test_dbaas.py":[{"author":{"_account_id":8415,"name":"Denis M.","email":"lildee1991@gmail.com","username":"dmakogon"},"change_message_id":"e0fc9c112813b1523bb7923a74dcddc8b8ed6ca6","unresolved":false,"context_lines":[{"line_number":900,"context_line":""},{"line_number":901,"context_line":"    def test_service_registry_with_existing_manager(self):"},{"line_number":902,"context_line":"        service_registry_ext_test \u003d {"},{"line_number":903,"context_line":"            \u0027mysql\u0027: \u0027trove.guestagent.manager.mysql.Manager\u0027,"},{"line_number":904,"context_line":"        }"},{"line_number":905,"context_line":"        dbaas_sr.get_custom_managers \u003d \\"},{"line_number":906,"context_line":"            Mock(return_value\u003dservice_registry_ext_test)"}],"source_content_type":"text/x-python","patch_set":13,"id":"AAAATH%2F%2F9YU%3D","line":903,"updated":"2013-10-07 13:49:17.000000000","message":"use another value for this test, because it is the same with default.","commit_id":"7ca1aedb91c54da5c1c00897348773ce74fdbffe"},{"author":{"_account_id":8415,"name":"Denis M.","email":"lildee1991@gmail.com","username":"dmakogon"},"change_message_id":"e0fc9c112813b1523bb7923a74dcddc8b8ed6ca6","unresolved":false,"context_lines":[{"line_number":903,"context_line":"            \u0027mysql\u0027: \u0027trove.guestagent.manager.mysql.Manager\u0027,"},{"line_number":904,"context_line":"        }"},{"line_number":905,"context_line":"        dbaas_sr.get_custom_managers \u003d \\"},{"line_number":906,"context_line":"            Mock(return_value\u003dservice_registry_ext_test)"},{"line_number":907,"context_line":"        test_dict \u003d dbaas_sr.service_registry()"},{"line_number":908,"context_line":"        self.assertEqual(2, len(test_dict))"},{"line_number":909,"context_line":"        self.assertEqual(test_dict.get(\u0027mysql\u0027),"}],"source_content_type":"text/x-python","patch_set":13,"id":"AAAATH%2F%2F9Yc%3D","line":906,"updated":"2013-10-07 13:49:17.000000000","message":"Please, follow code style. Do not use \"\\\"","commit_id":"7ca1aedb91c54da5c1c00897348773ce74fdbffe"}]}
