)]}'
{"/COMMIT_MSG":[{"author":{"_account_id":10440,"name":"Alex Tomic","email":"atomic777@gmail.com","username":"atomic77"},"change_message_id":"24659c5a7f2c69fa4bbb05ccfca4a9e33dd967e3","unresolved":false,"context_lines":[{"line_number":5,"context_line":"CommitDate: 2015-06-15 15:33:47 +0000"},{"line_number":6,"context_line":""},{"line_number":7,"context_line":"Support authentication in the MongoDB guest agent"},{"line_number":8,"context_line":""},{"line_number":9,"context_line":"NOTE: auth will *not* be turned on in this commit, but the code to handle"},{"line_number":10,"context_line":"it being enabled will be there. This is because with auth on user"},{"line_number":11,"context_line":"creation would only be possible through Trove. Therefore auth will be"}],"source_content_type":"text/x-gerrit-commit-message","patch_set":10,"id":"fa32b979_9da142ac","line":8,"updated":"2015-06-15 17:21:55.000000000","message":"This is an improvement on the previous title, but given the amount of code you\u0027re introducing in all these patchsets, a more detailed explanation of the dependencies would be helpful, as it\u0027s not clear, at least to me, from looking through the mongo-user and mongo-database blueprints and the commit messages. \n\ne.g. the explanation for why you\u0027ve introduced the authentication logic here, but not enabled it, I\u0027m having trouble understanding: \"This is because with auth on user\ncreation would only be possible through Trove\"","commit_id":"d6b65188cb61629d1327822fa5879f440aea710d"},{"author":{"_account_id":5293,"name":"Nikhil","email":"SlickNik@gmail.com","username":"slicknik"},"change_message_id":"b63126b220be3869c5b171fce5eac58c9b321970","unresolved":false,"context_lines":[{"line_number":7,"context_line":"Support authentication in the MongoDB guest agent"},{"line_number":8,"context_line":""},{"line_number":9,"context_line":"NOTE: The code to handle MongoDB authentication is being added, but the auth"},{"line_number":10,"context_line":"switch will NOT be turned on in this commit."},{"line_number":11,"context_line":""},{"line_number":12,"context_line":"Implement client authentication in the MongoDB guest agent. This involves"},{"line_number":13,"context_line":"creating an os_admin user, authenticating the client before all requests,"}],"source_content_type":"text/x-gerrit-commit-message","patch_set":21,"id":"ba3cc151_2c8695b9","line":10,"updated":"2015-07-01 05:12:41.000000000","message":"What is the reason that we\u0027re not turning this on in this commit? I don\u0027t see any integration tests for these, either. How is one supposed to ensure that these changes are working as expected?","commit_id":"ba596e6c5aa597ef2d55e2cc45302d023112fc50"},{"author":{"_account_id":15321,"name":"Matthew Van Dijk","email":"mvandijk@tesora.com","username":"mvandijk"},"change_message_id":"ee929a2dbff52e6561fde23da3d389648a11a6dd","unresolved":false,"context_lines":[{"line_number":7,"context_line":"Support authentication in the MongoDB guest agent"},{"line_number":8,"context_line":""},{"line_number":9,"context_line":"NOTE: The code to handle MongoDB authentication is being added, but the auth"},{"line_number":10,"context_line":"switch will NOT be turned on in this commit."},{"line_number":11,"context_line":""},{"line_number":12,"context_line":"Implement client authentication in the MongoDB guest agent. This involves"},{"line_number":13,"context_line":"creating an os_admin user, authenticating the client before all requests,"}],"source_content_type":"text/x-gerrit-commit-message","patch_set":21,"id":"ba3cc151_8b1bb980","line":10,"in_reply_to":"ba3cc151_2c8695b9","updated":"2015-07-02 13:23:04.000000000","message":"Without the functionality for Trove to create users, specifically with root access, enabling authentication will make the instance inaccessible. It will enabled in a later patch once these current items have been merged.","commit_id":"ba596e6c5aa597ef2d55e2cc45302d023112fc50"},{"author":{"_account_id":4240,"name":"Craig Vyvial","email":"cp16net@gmail.com","username":"cp16net"},"change_message_id":"14e2fb1cab732c0ca67cef312a58dda1e4ca0895","unresolved":false,"context_lines":[{"line_number":7,"context_line":"Support authentication in the MongoDB guest agent"},{"line_number":8,"context_line":""},{"line_number":9,"context_line":"NOTE: The code to handle MongoDB authentication is being added, but the auth"},{"line_number":10,"context_line":"switch will NOT be turned on in this commit."},{"line_number":11,"context_line":""},{"line_number":12,"context_line":"Implement client authentication in the MongoDB guest agent. This involves"},{"line_number":13,"context_line":"creating an os_admin user, authenticating the client before all requests,"}],"source_content_type":"text/x-gerrit-commit-message","patch_set":21,"id":"ba3cc151_7e8146fa","line":10,"in_reply_to":"ba3cc151_8b1bb980","updated":"2015-07-02 16:11:09.000000000","message":"So it sounds like this patch is dependent on the create users and root access for mongo. If thats the case i think it would be better to hold off on merging this change until those are merged since it will not be able to be used or validated until then.","commit_id":"ba596e6c5aa597ef2d55e2cc45302d023112fc50"},{"author":{"_account_id":7806,"name":"Sushil Kumar","email":"skm.net@gmail.com","username":"sushilkm"},"change_message_id":"1f17d050c9247f60b76284eecfb2fed535a2c33d","unresolved":false,"context_lines":[{"line_number":46,"context_line":"      --- users access grant/show/revoke"},{"line_number":47,"context_line":"   --- database"},{"line_number":48,"context_line":""},{"line_number":49,"context_line":"Closes-Bug: #1467513"},{"line_number":50,"context_line":"Partially Implements: blueprint mongodb-database"},{"line_number":51,"context_line":"Change-Id: I90793f95984b360a2c3668421cb5351aac89e46f"}],"source_content_type":"text/x-gerrit-commit-message","patch_set":21,"id":"fa32b979_da0d8236","line":49,"updated":"2015-06-27 18:20:07.000000000","message":"Now since there are two authors involved can we have author and co-authors.","commit_id":"ba596e6c5aa597ef2d55e2cc45302d023112fc50"},{"author":{"_account_id":15321,"name":"Matthew Van Dijk","email":"mvandijk@tesora.com","username":"mvandijk"},"change_message_id":"b4704e34ddae45707fdf668c383c70b255fd6e42","unresolved":false,"context_lines":[{"line_number":46,"context_line":"      --- users access grant/show/revoke"},{"line_number":47,"context_line":"   --- database"},{"line_number":48,"context_line":""},{"line_number":49,"context_line":"Closes-Bug: #1467513"},{"line_number":50,"context_line":"Partially Implements: blueprint mongodb-database"},{"line_number":51,"context_line":"Change-Id: I90793f95984b360a2c3668421cb5351aac89e46f"}],"source_content_type":"text/x-gerrit-commit-message","patch_set":21,"id":"ba3cc151_21ba7ae2","line":49,"in_reply_to":"fa32b979_da0d8236","updated":"2015-06-29 13:31:25.000000000","message":"The patchsets from Petr are just rebases. Not sure why his workflow is causing new patchsets here.","commit_id":"ba596e6c5aa597ef2d55e2cc45302d023112fc50"}],"test-requirements.txt":[{"author":{"_account_id":4240,"name":"Craig Vyvial","email":"cp16net@gmail.com","username":"cp16net"},"change_message_id":"5bf7dd36f61d9852b686959dfa5dae2f826ec319","unresolved":false,"context_lines":[{"line_number":20,"context_line":"testtools\u003e\u003d0.9.36,!\u003d1.2.0"},{"line_number":21,"context_line":"discover"},{"line_number":22,"context_line":"testrepository\u003e\u003d0.0.18"},{"line_number":23,"context_line":"pymongo\u003e\u003d3.0.2"}],"source_content_type":"text/plain","patch_set":21,"id":"ba3cc151_e9f89f4b","line":23,"updated":"2015-07-01 04:23:05.000000000","message":"Since this file is just the extra packages we need for testing trove, I think this line should be added to the requirements.txt instead of here since its needed inside the guest agent.","commit_id":"ba596e6c5aa597ef2d55e2cc45302d023112fc50"},{"author":{"_account_id":14576,"name":"Petr Malik","email":"pmalik@tesora.com","username":"pmalik"},"change_message_id":"9b452d65d590c4c645750a112895505bdbfa115c","unresolved":false,"context_lines":[{"line_number":20,"context_line":"testtools\u003e\u003d0.9.36,!\u003d1.2.0"},{"line_number":21,"context_line":"discover"},{"line_number":22,"context_line":"testrepository\u003e\u003d0.0.18"},{"line_number":23,"context_line":"pymongo\u003e\u003d3.0.2"}],"source_content_type":"text/plain","patch_set":21,"id":"ba3cc151_d7042c19","line":23,"in_reply_to":"ba3cc151_0c04f147","updated":"2015-07-01 17:29:56.000000000","message":"Well, this requirement is not needed by the \u0027guestagent\u0027 in general, but specifically by MongoDB. That is why \u0027pymongo\u0027 gets installed in MongoDB elements.\nAFAIK all requirements from the requirements.txt get installed on all guestagents. There is not really a point in having \u0027pymongo\u0027 in a Redis guestagent and vice versa.\n\nMaybe we should think about a better way to separate guestagents and have them specify their own additional requirements.\n\nA potentially related blueprint:\nhttps://blueprints.launchpad.net/trove/+spec/moving-trove-guestagent","commit_id":"ba596e6c5aa597ef2d55e2cc45302d023112fc50"},{"author":{"_account_id":4240,"name":"Craig Vyvial","email":"cp16net@gmail.com","username":"cp16net"},"change_message_id":"14e2fb1cab732c0ca67cef312a58dda1e4ca0895","unresolved":false,"context_lines":[{"line_number":20,"context_line":"testtools\u003e\u003d0.9.36,!\u003d1.2.0"},{"line_number":21,"context_line":"discover"},{"line_number":22,"context_line":"testrepository\u003e\u003d0.0.18"},{"line_number":23,"context_line":"pymongo\u003e\u003d3.0.2"}],"source_content_type":"text/plain","patch_set":21,"id":"ba3cc151_1e5d9a14","line":23,"in_reply_to":"ba3cc151_0e62570a","updated":"2015-07-02 16:11:09.000000000","message":"ahh i get it. thanks for the explanation.","commit_id":"ba596e6c5aa597ef2d55e2cc45302d023112fc50"},{"author":{"_account_id":6413,"name":"Victoria Martinez de la Cruz","email":"victoria@redhat.com","username":"vkmc"},"change_message_id":"bb1862a656292eda333ae6a025fbc83e2f45cec7","unresolved":false,"context_lines":[{"line_number":20,"context_line":"testtools\u003e\u003d0.9.36,!\u003d1.2.0"},{"line_number":21,"context_line":"discover"},{"line_number":22,"context_line":"testrepository\u003e\u003d0.0.18"},{"line_number":23,"context_line":"pymongo\u003e\u003d3.0.2"}],"source_content_type":"text/plain","patch_set":21,"id":"ba3cc151_0e62570a","line":23,"in_reply_to":"ba3cc151_6bb8b575","updated":"2015-07-02 13:34:59.000000000","message":"IMO it is ok for this dependency to be here because it is needed for the unittests. Following Petr\u0027s and Matthew\u0027s lines, pymongo cannot go to requirements.txt because its not a dependency for, say, the MySQL guestagent implementation. Agree that we need a better way to split the requirements for the different datastores. In the meantime, this should be part of the image creation process: that is, if you want a MongoDB instance, make sure you have MongoDB server and pymongo installed in your image.","commit_id":"ba596e6c5aa597ef2d55e2cc45302d023112fc50"},{"author":{"_account_id":15321,"name":"Matthew Van Dijk","email":"mvandijk@tesora.com","username":"mvandijk"},"change_message_id":"ee929a2dbff52e6561fde23da3d389648a11a6dd","unresolved":false,"context_lines":[{"line_number":20,"context_line":"testtools\u003e\u003d0.9.36,!\u003d1.2.0"},{"line_number":21,"context_line":"discover"},{"line_number":22,"context_line":"testrepository\u003e\u003d0.0.18"},{"line_number":23,"context_line":"pymongo\u003e\u003d3.0.2"}],"source_content_type":"text/plain","patch_set":21,"id":"ba3cc151_6bb8b575","line":23,"in_reply_to":"ba3cc151_d7042c19","updated":"2015-07-02 13:23:04.000000000","message":"Petr hit the nail on the head - it is more a requirement of MongoDB guest images to have pymongo installed. I agree that it should not be forced on all guests. We have the same problem then for Cassandra, Redis, MongoDB, and whatever else comes along.","commit_id":"ba596e6c5aa597ef2d55e2cc45302d023112fc50"},{"author":{"_account_id":5293,"name":"Nikhil","email":"SlickNik@gmail.com","username":"slicknik"},"change_message_id":"b63126b220be3869c5b171fce5eac58c9b321970","unresolved":false,"context_lines":[{"line_number":20,"context_line":"testtools\u003e\u003d0.9.36,!\u003d1.2.0"},{"line_number":21,"context_line":"discover"},{"line_number":22,"context_line":"testrepository\u003e\u003d0.0.18"},{"line_number":23,"context_line":"pymongo\u003e\u003d3.0.2"}],"source_content_type":"text/plain","patch_set":21,"id":"ba3cc151_0c04f147","line":23,"in_reply_to":"ba3cc151_e9f89f4b","updated":"2015-07-01 05:12:41.000000000","message":"Agreeed, since this is now a requirement for the guest, it should be included in requirements.txt for the guest agent. test-requirements is not the right place for this.","commit_id":"ba596e6c5aa597ef2d55e2cc45302d023112fc50"}],"trove/common/cfg.py":[{"author":{"_account_id":9664,"name":"amrith","email":"amrith.kumar@gmail.com","username":"amrith"},"change_message_id":"ff41b2bdce5c23fbfd8ea23604917f8111610477","unresolved":false,"context_lines":[{"line_number":742,"context_line":"               deprecated_group\u003d\u0027DEFAULT\u0027),"},{"line_number":743,"context_line":"    cfg.IntOpt(\u0027mongodb_port\u0027, default\u003d27017,"},{"line_number":744,"context_line":"               help\u003d\u0027Port for mongod and mongos instances.\u0027),"},{"line_number":745,"context_line":"    cfg.IntOpt(\u0027configsvr_port\u0027, default\u003d27019,"},{"line_number":746,"context_line":"               help\u003d\u0027Port for instances running as config servers.\u0027),"},{"line_number":747,"context_line":"]"},{"line_number":748,"context_line":""}],"source_content_type":"text/x-python","patch_set":21,"id":"fa32b979_01a4e105","line":745,"updated":"2015-06-27 14:52:13.000000000","message":"shouldn\u0027t this also get listed in tcp_ports above?","commit_id":"ba596e6c5aa597ef2d55e2cc45302d023112fc50"},{"author":{"_account_id":7806,"name":"Sushil Kumar","email":"skm.net@gmail.com","username":"sushilkm"},"change_message_id":"1f17d050c9247f60b76284eecfb2fed535a2c33d","unresolved":false,"context_lines":[{"line_number":742,"context_line":"               deprecated_group\u003d\u0027DEFAULT\u0027),"},{"line_number":743,"context_line":"    cfg.IntOpt(\u0027mongodb_port\u0027, default\u003d27017,"},{"line_number":744,"context_line":"               help\u003d\u0027Port for mongod and mongos instances.\u0027),"},{"line_number":745,"context_line":"    cfg.IntOpt(\u0027configsvr_port\u0027, default\u003d27019,"},{"line_number":746,"context_line":"               help\u003d\u0027Port for instances running as config servers.\u0027),"},{"line_number":747,"context_line":"]"},{"line_number":748,"context_line":""}],"source_content_type":"text/x-python","patch_set":21,"id":"fa32b979_d7831ba8","line":745,"in_reply_to":"fa32b979_01a4e105","updated":"2015-06-27 18:20:07.000000000","message":"I agree if we need to use configsvr_port on floating ip we would of course need that on tcp_port","commit_id":"ba596e6c5aa597ef2d55e2cc45302d023112fc50"},{"author":{"_account_id":15321,"name":"Matthew Van Dijk","email":"mvandijk@tesora.com","username":"mvandijk"},"change_message_id":"b4704e34ddae45707fdf668c383c70b255fd6e42","unresolved":false,"context_lines":[{"line_number":742,"context_line":"               deprecated_group\u003d\u0027DEFAULT\u0027),"},{"line_number":743,"context_line":"    cfg.IntOpt(\u0027mongodb_port\u0027, default\u003d27017,"},{"line_number":744,"context_line":"               help\u003d\u0027Port for mongod and mongos instances.\u0027),"},{"line_number":745,"context_line":"    cfg.IntOpt(\u0027configsvr_port\u0027, default\u003d27019,"},{"line_number":746,"context_line":"               help\u003d\u0027Port for instances running as config servers.\u0027),"},{"line_number":747,"context_line":"]"},{"line_number":748,"context_line":""}],"source_content_type":"text/x-python","patch_set":21,"id":"ba3cc151_21791afd","line":745,"in_reply_to":"fa32b979_d7831ba8","updated":"2015-06-29 13:31:25.000000000","message":"False, this port should not be publicly accessible. It needs to only be accessible to the query router MongoDB instances.","commit_id":"ba596e6c5aa597ef2d55e2cc45302d023112fc50"}],"trove/common/strategies/cluster/experimental/mongodb/api.py":[{"author":{"_account_id":9782,"name":"Morgan Jones","email":"morgan@tesora.com","username":"vgnbkr"},"change_message_id":"c7fec2f303cf45ccb80741bb6377698174b6525f","unresolved":false,"context_lines":[{"line_number":206,"context_line":"                         \"shard_id\": new_shard_id,"},{"line_number":207,"context_line":"                         \"instance_type\": \"member\","},{"line_number":208,"context_line":"                         \"replica_set_name\": new_replica_set_name,"},{"line_number":209,"context_line":"                         \"key\": self.key}"},{"line_number":210,"context_line":"        for i in range(1, num_members_per_shard + 1):"},{"line_number":211,"context_line":"            instance_name \u003d \"%s-%s-%s\" % (self.name, new_replica_set_name,"},{"line_number":212,"context_line":"                                          str(i))"}],"source_content_type":"text/x-python","patch_set":2,"id":"5afe65bd_ea6c049e","line":209,"updated":"2015-06-03 18:39:04.000000000","message":"Where does this key come from?  I don\u0027t see where it is saved.","commit_id":"f0c7095d302f6edd6f380e6df562832aa0157ccf"},{"author":{"_account_id":9782,"name":"Morgan Jones","email":"morgan@tesora.com","username":"vgnbkr"},"change_message_id":"c7fec2f303cf45ccb80741bb6377698174b6525f","unresolved":false,"context_lines":[{"line_number":229,"context_line":"            new_shard_id,"},{"line_number":230,"context_line":"            new_replica_set_name)"},{"line_number":231,"context_line":""},{"line_number":232,"context_line":"    @property"},{"line_number":233,"context_line":"    def key(self):"},{"line_number":234,"context_line":"        return self._key"},{"line_number":235,"context_line":""}],"source_content_type":"text/x-python","patch_set":2,"id":"5afe65bd_2a4c5c41","line":232,"updated":"2015-06-03 18:39:04.000000000","message":"Why are you explicitly declaring the property?","commit_id":"f0c7095d302f6edd6f380e6df562832aa0157ccf"},{"author":{"_account_id":7806,"name":"Sushil Kumar","email":"skm.net@gmail.com","username":"sushilkm"},"change_message_id":"0cd28f80822ec2c683dc291ba78802a7096a7bce","unresolved":false,"context_lines":[{"line_number":231,"context_line":""},{"line_number":232,"context_line":"    @property"},{"line_number":233,"context_line":"    def key(self):"},{"line_number":234,"context_line":"        return self._key"},{"line_number":235,"context_line":""},{"line_number":236,"context_line":"    @key.setter"},{"line_number":237,"context_line":"    def key(self, value):"}],"source_content_type":"text/x-python","patch_set":2,"id":"5afe65bd_8a8c6280","line":234,"updated":"2015-06-03 06:56:53.000000000","message":"is it self.key or self._key as on line 208 it is referenced as self.key\n\nit could be only one of them","commit_id":"f0c7095d302f6edd6f380e6df562832aa0157ccf"},{"author":{"_account_id":15321,"name":"Matthew Van Dijk","email":"mvandijk@tesora.com","username":"mvandijk"},"change_message_id":"04424e69191dd729c1b12bd50f75ccf8938a5381","unresolved":false,"context_lines":[{"line_number":231,"context_line":""},{"line_number":232,"context_line":"    @property"},{"line_number":233,"context_line":"    def key(self):"},{"line_number":234,"context_line":"        return self._key"},{"line_number":235,"context_line":""},{"line_number":236,"context_line":"    @key.setter"},{"line_number":237,"context_line":"    def key(self, value):"}],"source_content_type":"text/x-python","patch_set":2,"id":"5afe65bd_f8660228","line":234,"in_reply_to":"5afe65bd_8a8c6280","updated":"2015-06-03 13:20:26.000000000","message":"This is being reworked. It was caught by the test_cluster unit test.","commit_id":"f0c7095d302f6edd6f380e6df562832aa0157ccf"},{"author":{"_account_id":6413,"name":"Victoria Martinez de la Cruz","email":"victoria@redhat.com","username":"vkmc"},"change_message_id":"640fb10e936935547e2da0ee999b98f706afaac9","unresolved":false,"context_lines":[{"line_number":171,"context_line":"        task_api.load(context, datastore_version.manager).create_cluster("},{"line_number":172,"context_line":"            db_info.id)"},{"line_number":173,"context_line":""},{"line_number":174,"context_line":"        cluster \u003d MongoDbCluster(context, db_info, datastore,"},{"line_number":175,"context_line":"                                 datastore_version)"},{"line_number":176,"context_line":"        return cluster"},{"line_number":177,"context_line":""}],"source_content_type":"text/x-python","patch_set":18,"id":"fa32b979_66519f2f","line":174,"updated":"2015-06-25 19:17:13.000000000","message":"NIT: return directly","commit_id":"5d05ebc04954bf98c6a487948cf565ab334792df"},{"author":{"_account_id":15321,"name":"Matthew Van Dijk","email":"mvandijk@tesora.com","username":"mvandijk"},"change_message_id":"f4aea28d8f5054761e4203a039189763c1c47f96","unresolved":false,"context_lines":[{"line_number":171,"context_line":"        task_api.load(context, datastore_version.manager).create_cluster("},{"line_number":172,"context_line":"            db_info.id)"},{"line_number":173,"context_line":""},{"line_number":174,"context_line":"        cluster \u003d MongoDbCluster(context, db_info, datastore,"},{"line_number":175,"context_line":"                                 datastore_version)"},{"line_number":176,"context_line":"        return cluster"},{"line_number":177,"context_line":""}],"source_content_type":"text/x-python","patch_set":18,"id":"fa32b979_d2e7c244","line":174,"in_reply_to":"fa32b979_66519f2f","updated":"2015-06-26 17:39:06.000000000","message":"Done","commit_id":"5d05ebc04954bf98c6a487948cf565ab334792df"}],"trove/common/strategies/cluster/experimental/mongodb/taskmanager.py":[{"author":{"_account_id":14576,"name":"Petr Malik","email":"pmalik@tesora.com","username":"pmalik"},"change_message_id":"bf8daab70ddd53960d7c1d9286f2f797523bd2bf","unresolved":false,"context_lines":[{"line_number":141,"context_line":"            LOG.debug(\"config server ips: %s\" % config_server_ips)"},{"line_number":142,"context_line":""},{"line_number":143,"context_line":"            LOG.debug(\"calling add_config_servers on, and sending admin user \""},{"line_number":144,"context_line":"                      \"password to, query_routers\")"},{"line_number":145,"context_line":"            try:"},{"line_number":146,"context_line":"                admin_created \u003d False"},{"line_number":147,"context_line":"                admin_password \u003d utils.generate_random_password()"}],"source_content_type":"text/x-python","patch_set":14,"id":"fa32b979_4408ec91","line":144,"updated":"2015-06-19 15:40:39.000000000","message":"A short comment on what this is doing (create a user on only one query router [I assume it sends it down to the config servers] and reset the password to the same value on the rest?) may be helpful in the future.","commit_id":"59facd61b6a657abc110ed0fab08ba3823a383d1"},{"author":{"_account_id":15321,"name":"Matthew Van Dijk","email":"mvandijk@tesora.com","username":"mvandijk"},"change_message_id":"cbcec005c49e4d5aa8bd4b20da630f0a005c866d","unresolved":false,"context_lines":[{"line_number":141,"context_line":"            LOG.debug(\"config server ips: %s\" % config_server_ips)"},{"line_number":142,"context_line":""},{"line_number":143,"context_line":"            LOG.debug(\"calling add_config_servers on, and sending admin user \""},{"line_number":144,"context_line":"                      \"password to, query_routers\")"},{"line_number":145,"context_line":"            try:"},{"line_number":146,"context_line":"                admin_created \u003d False"},{"line_number":147,"context_line":"                admin_password \u003d utils.generate_random_password()"}],"source_content_type":"text/x-python","patch_set":14,"id":"fa32b979_e69eab53","line":144,"in_reply_to":"fa32b979_1d952fe3","updated":"2015-06-22 17:44:04.000000000","message":"Correct, and done.","commit_id":"59facd61b6a657abc110ed0fab08ba3823a383d1"},{"author":{"_account_id":6413,"name":"Victoria Martinez de la Cruz","email":"victoria@redhat.com","username":"vkmc"},"change_message_id":"738cc8eb5953fb6c7b4adb2ae21498b940c1c2f7","unresolved":false,"context_lines":[{"line_number":141,"context_line":"            LOG.debug(\"config server ips: %s\" % config_server_ips)"},{"line_number":142,"context_line":""},{"line_number":143,"context_line":"            LOG.debug(\"calling add_config_servers on, and sending admin user \""},{"line_number":144,"context_line":"                      \"password to, query_routers\")"},{"line_number":145,"context_line":"            try:"},{"line_number":146,"context_line":"                admin_created \u003d False"},{"line_number":147,"context_line":"                admin_password \u003d utils.generate_random_password()"}],"source_content_type":"text/x-python","patch_set":14,"id":"fa32b979_1d952fe3","line":144,"in_reply_to":"fa32b979_4408ec91","updated":"2015-06-22 11:10:11.000000000","message":"+1","commit_id":"59facd61b6a657abc110ed0fab08ba3823a383d1"}],"trove/guestagent/common/operating_system.py":[{"author":{"_account_id":7806,"name":"Sushil Kumar","email":"skm.net@gmail.com","username":"sushilkm"},"change_message_id":"0cd28f80822ec2c683dc291ba78802a7096a7bce","unresolved":false,"context_lines":[{"line_number":68,"context_line":""},{"line_number":69,"context_line":"    @classmethod"},{"line_number":70,"context_line":"    def SET_USR_RW(cls):"},{"line_number":71,"context_line":"        return cls(reset\u003d[stat.S_IRUSR | stat.S_IWUSR])  # \u003d0400"},{"line_number":72,"context_line":""},{"line_number":73,"context_line":"    @classmethod"},{"line_number":74,"context_line":"    def ADD_READ_ALL(cls):"}],"source_content_type":"text/x-python","patch_set":2,"id":"5afe65bd_4ad42a46","line":71,"updated":"2015-06-03 06:56:53.000000000","message":"RW\u003d6","commit_id":"f0c7095d302f6edd6f380e6df562832aa0157ccf"},{"author":{"_account_id":15321,"name":"Matthew Van Dijk","email":"mvandijk@tesora.com","username":"mvandijk"},"change_message_id":"04424e69191dd729c1b12bd50f75ccf8938a5381","unresolved":false,"context_lines":[{"line_number":68,"context_line":""},{"line_number":69,"context_line":"    @classmethod"},{"line_number":70,"context_line":"    def SET_USR_RW(cls):"},{"line_number":71,"context_line":"        return cls(reset\u003d[stat.S_IRUSR | stat.S_IWUSR])  # \u003d0400"},{"line_number":72,"context_line":""},{"line_number":73,"context_line":"    @classmethod"},{"line_number":74,"context_line":"    def ADD_READ_ALL(cls):"}],"source_content_type":"text/x-python","patch_set":2,"id":"5afe65bd_f84de299","line":71,"in_reply_to":"5afe65bd_4ad42a46","updated":"2015-06-03 13:20:26.000000000","message":"Right.","commit_id":"f0c7095d302f6edd6f380e6df562832aa0157ccf"}],"trove/guestagent/datastore/experimental/mongodb/manager.py":[{"author":{"_account_id":9782,"name":"Morgan Jones","email":"morgan@tesora.com","username":"vgnbkr"},"change_message_id":"c7fec2f303cf45ccb80741bb6377698174b6525f","unresolved":false,"context_lines":[{"line_number":111,"context_line":"    def get_config_changes(self, cluster_config, mount_point\u003dNone):"},{"line_number":112,"context_line":"        LOG.debug(\"Getting configuration changes.\")"},{"line_number":113,"context_line":"        config_changes \u003d {}"},{"line_number":114,"context_line":"        #todo mvandijk: uncomment the following when auth is being enabled"},{"line_number":115,"context_line":"        #config_changes[\u0027auth\u0027] \u003d \u0027true\u0027"},{"line_number":116,"context_line":"        if cluster_config is not None:"},{"line_number":117,"context_line":"            #todo mvandijk: uncomment the following when auth is being enabled"}],"source_content_type":"text/x-python","patch_set":2,"id":"5afe65bd_0ae52008","line":114,"updated":"2015-06-03 18:39:04.000000000","message":"This change should just be dependent on the mongodb-user change.  Otherwise, this will just get forgotten.","commit_id":"f0c7095d302f6edd6f380e6df562832aa0157ccf"},{"author":{"_account_id":7806,"name":"Sushil Kumar","email":"skm.net@gmail.com","username":"sushilkm"},"change_message_id":"0cd28f80822ec2c683dc291ba78802a7096a7bce","unresolved":false,"context_lines":[{"line_number":112,"context_line":"        LOG.debug(\"Getting configuration changes.\")"},{"line_number":113,"context_line":"        config_changes \u003d {}"},{"line_number":114,"context_line":"        #todo mvandijk: uncomment the following when auth is being enabled"},{"line_number":115,"context_line":"        #config_changes[\u0027auth\u0027] \u003d \u0027true\u0027"},{"line_number":116,"context_line":"        if cluster_config is not None:"},{"line_number":117,"context_line":"            #todo mvandijk: uncomment the following when auth is being enabled"},{"line_number":118,"context_line":"            #config_changes[\u0027keyFile\u0027] \u003d self.app.get_key_file()"}],"source_content_type":"text/x-python","patch_set":2,"id":"5afe65bd_6a06c6cf","line":115,"updated":"2015-06-03 06:56:53.000000000","message":"I think this needs a better comment, i got confused here if it was a deployers requirement to enable auth and then commit message helped me clear my doubt, so either we can get rid of this piece or a better comment suggesting that this would be enabled in future work.","commit_id":"f0c7095d302f6edd6f380e6df562832aa0157ccf"},{"author":{"_account_id":15321,"name":"Matthew Van Dijk","email":"mvandijk@tesora.com","username":"mvandijk"},"change_message_id":"04424e69191dd729c1b12bd50f75ccf8938a5381","unresolved":false,"context_lines":[{"line_number":112,"context_line":"        LOG.debug(\"Getting configuration changes.\")"},{"line_number":113,"context_line":"        config_changes \u003d {}"},{"line_number":114,"context_line":"        #todo mvandijk: uncomment the following when auth is being enabled"},{"line_number":115,"context_line":"        #config_changes[\u0027auth\u0027] \u003d \u0027true\u0027"},{"line_number":116,"context_line":"        if cluster_config is not None:"},{"line_number":117,"context_line":"            #todo mvandijk: uncomment the following when auth is being enabled"},{"line_number":118,"context_line":"            #config_changes[\u0027keyFile\u0027] \u003d self.app.get_key_file()"}],"source_content_type":"text/x-python","patch_set":2,"id":"5afe65bd_1832fe10","line":115,"in_reply_to":"5afe65bd_6a06c6cf","updated":"2015-06-03 13:20:26.000000000","message":"This will be removed by me in an upcoming commit.","commit_id":"f0c7095d302f6edd6f380e6df562832aa0157ccf"},{"author":{"_account_id":4240,"name":"Craig Vyvial","email":"cp16net@gmail.com","username":"cp16net"},"change_message_id":"b5550c7be8e4fb629459520f3d0cdbff2937be23","unresolved":false,"context_lines":[{"line_number":116,"context_line":"        LOG.debug(\"Getting configuration changes.\")"},{"line_number":117,"context_line":"        config_changes \u003d {}"},{"line_number":118,"context_line":"        # todo mvandijk: uncomment the following when auth is being enabled"},{"line_number":119,"context_line":"        # config_changes[\u0027auth\u0027] \u003d \u0027true\u0027"},{"line_number":120,"context_line":"        config_changes[\u0027bind_ip\u0027] \u003d \u0027,\u0027.join([netutils.get_my_ipv4(),"},{"line_number":121,"context_line":"                                              \u0027127.0.0.1\u0027])"},{"line_number":122,"context_line":"        if cluster_config is not None:"}],"source_content_type":"text/x-python","patch_set":21,"id":"ba3cc151_4fe8abb4","line":119,"updated":"2015-07-01 05:41:03.000000000","message":"If all the code is there this should be enabled or if this is something that a deployer may want to configure make a config for it. (will this affect any \"old\" instances and cause issues if they are not upgraded and setup with auth?)","commit_id":"ba596e6c5aa597ef2d55e2cc45302d023112fc50"},{"author":{"_account_id":15321,"name":"Matthew Van Dijk","email":"mvandijk@tesora.com","username":"mvandijk"},"change_message_id":"ee929a2dbff52e6561fde23da3d389648a11a6dd","unresolved":false,"context_lines":[{"line_number":116,"context_line":"        LOG.debug(\"Getting configuration changes.\")"},{"line_number":117,"context_line":"        config_changes \u003d {}"},{"line_number":118,"context_line":"        # todo mvandijk: uncomment the following when auth is being enabled"},{"line_number":119,"context_line":"        # config_changes[\u0027auth\u0027] \u003d \u0027true\u0027"},{"line_number":120,"context_line":"        config_changes[\u0027bind_ip\u0027] \u003d \u0027,\u0027.join([netutils.get_my_ipv4(),"},{"line_number":121,"context_line":"                                              \u0027127.0.0.1\u0027])"},{"line_number":122,"context_line":"        if cluster_config is not None:"}],"source_content_type":"text/x-python","patch_set":21,"id":"ba3cc151_ce546fcb","line":119,"in_reply_to":"ba3cc151_4fe8abb4","updated":"2015-07-02 13:23:04.000000000","message":"See my reply to Nik","commit_id":"ba596e6c5aa597ef2d55e2cc45302d023112fc50"}],"trove/guestagent/datastore/experimental/mongodb/service.py":[{"author":{"_account_id":9782,"name":"Morgan Jones","email":"morgan@tesora.com","username":"vgnbkr"},"change_message_id":"c7fec2f303cf45ccb80741bb6377698174b6525f","unresolved":false,"context_lines":[{"line_number":310,"context_line":"        # TODO(ramashri) see if hardcoded values can be removed"},{"line_number":311,"context_line":"        utils.poll_until(check_rs_status, sleep_time\u003d60, time_out\u003d100)"},{"line_number":312,"context_line":""},{"line_number":313,"context_line":"    def get_key_file(self):"},{"line_number":314,"context_line":"        return system.MONGO_KEY_FILE"},{"line_number":315,"context_line":""},{"line_number":316,"context_line":"    def _store_key(self, key):"}],"source_content_type":"text/x-python","patch_set":2,"id":"5afe65bd_eac88476","line":313,"updated":"2015-06-03 18:39:04.000000000","message":"Is this here for testing?  If so, you should add a comment to that effect.","commit_id":"f0c7095d302f6edd6f380e6df562832aa0157ccf"},{"author":{"_account_id":9782,"name":"Morgan Jones","email":"morgan@tesora.com","username":"vgnbkr"},"change_message_id":"c7fec2f303cf45ccb80741bb6377698174b6525f","unresolved":false,"context_lines":[{"line_number":314,"context_line":"        return system.MONGO_KEY_FILE"},{"line_number":315,"context_line":""},{"line_number":316,"context_line":"    def _store_key(self, key):"},{"line_number":317,"context_line":"        MongoDBCredentials.clear_file(system.TMP_KEY_FILE)"},{"line_number":318,"context_line":"        with open(system.TMP_KEY_FILE, \u0027w\u0027) as f:"},{"line_number":319,"context_line":"            f.write(key)"},{"line_number":320,"context_line":"        operating_system.move(system.TMP_KEY_FILE, system.MONGO_KEY_FILE,"}],"source_content_type":"text/x-python","patch_set":2,"id":"5afe65bd_6ab014de","line":317,"updated":"2015-06-03 18:39:04.000000000","message":"Why are you clearing the file first?  You should write it, set the owner and permissions, then move it when it is complete.","commit_id":"f0c7095d302f6edd6f380e6df562832aa0157ccf"},{"author":{"_account_id":7806,"name":"Sushil Kumar","email":"skm.net@gmail.com","username":"sushilkm"},"change_message_id":"0cd28f80822ec2c683dc291ba78802a7096a7bce","unresolved":false,"context_lines":[{"line_number":315,"context_line":""},{"line_number":316,"context_line":"    def _store_key(self, key):"},{"line_number":317,"context_line":"        MongoDBCredentials.clear_file(system.TMP_KEY_FILE)"},{"line_number":318,"context_line":"        with open(system.TMP_KEY_FILE, \u0027w\u0027) as f:"},{"line_number":319,"context_line":"            f.write(key)"},{"line_number":320,"context_line":"        operating_system.move(system.TMP_KEY_FILE, system.MONGO_KEY_FILE,"},{"line_number":321,"context_line":"                              force\u003dTrue, as_root\u003dTrue)"}],"source_content_type":"text/x-python","patch_set":2,"id":"5afe65bd_4abe6ad5","line":318,"updated":"2015-06-03 06:56:53.000000000","message":"this way of using a predefined tmp file seems to security concerns, we shall use tempfile package for the purpose","commit_id":"f0c7095d302f6edd6f380e6df562832aa0157ccf"},{"author":{"_account_id":15321,"name":"Matthew Van Dijk","email":"mvandijk@tesora.com","username":"mvandijk"},"change_message_id":"04424e69191dd729c1b12bd50f75ccf8938a5381","unresolved":false,"context_lines":[{"line_number":315,"context_line":""},{"line_number":316,"context_line":"    def _store_key(self, key):"},{"line_number":317,"context_line":"        MongoDBCredentials.clear_file(system.TMP_KEY_FILE)"},{"line_number":318,"context_line":"        with open(system.TMP_KEY_FILE, \u0027w\u0027) as f:"},{"line_number":319,"context_line":"            f.write(key)"},{"line_number":320,"context_line":"        operating_system.move(system.TMP_KEY_FILE, system.MONGO_KEY_FILE,"},{"line_number":321,"context_line":"                              force\u003dTrue, as_root\u003dTrue)"}],"source_content_type":"text/x-python","patch_set":2,"id":"5afe65bd_b8d40abd","line":318,"in_reply_to":"5afe65bd_4abe6ad5","updated":"2015-06-03 13:20:26.000000000","message":"I\u0027ll look into it, thanks.","commit_id":"f0c7095d302f6edd6f380e6df562832aa0157ccf"},{"author":{"_account_id":7806,"name":"Sushil Kumar","email":"skm.net@gmail.com","username":"sushilkm"},"change_message_id":"0cd28f80822ec2c683dc291ba78802a7096a7bce","unresolved":false,"context_lines":[{"line_number":324,"context_line":"                               as_root\u003dTrue)"},{"line_number":325,"context_line":""},{"line_number":326,"context_line":"    def _create_admin_user(self):"},{"line_number":327,"context_line":"        LOG.debug(_(\"Generating admin password.\"))"},{"line_number":328,"context_line":"        admin_password \u003d utils.generate_random_password()"},{"line_number":329,"context_line":"        creds \u003d MongoDBCredentials(username\u003dsystem.MONGO_ADMIN_NAME,"},{"line_number":330,"context_line":"                                   password\u003dadmin_password)"}],"source_content_type":"text/x-python","patch_set":2,"id":"5afe65bd_4aa54ab3","line":327,"updated":"2015-06-03 06:56:53.000000000","message":"we do not need internationalization for debug messages.","commit_id":"f0c7095d302f6edd6f380e6df562832aa0157ccf"},{"author":{"_account_id":15321,"name":"Matthew Van Dijk","email":"mvandijk@tesora.com","username":"mvandijk"},"change_message_id":"04424e69191dd729c1b12bd50f75ccf8938a5381","unresolved":false,"context_lines":[{"line_number":324,"context_line":"                               as_root\u003dTrue)"},{"line_number":325,"context_line":""},{"line_number":326,"context_line":"    def _create_admin_user(self):"},{"line_number":327,"context_line":"        LOG.debug(_(\"Generating admin password.\"))"},{"line_number":328,"context_line":"        admin_password \u003d utils.generate_random_password()"},{"line_number":329,"context_line":"        creds \u003d MongoDBCredentials(username\u003dsystem.MONGO_ADMIN_NAME,"},{"line_number":330,"context_line":"                                   password\u003dadmin_password)"}],"source_content_type":"text/x-python","patch_set":2,"id":"5afe65bd_384a5aad","line":327,"in_reply_to":"5afe65bd_4aa54ab3","updated":"2015-06-03 13:20:26.000000000","message":"ok","commit_id":"f0c7095d302f6edd6f380e6df562832aa0157ccf"},{"author":{"_account_id":7806,"name":"Sushil Kumar","email":"skm.net@gmail.com","username":"sushilkm"},"change_message_id":"0cd28f80822ec2c683dc291ba78802a7096a7bce","unresolved":false,"context_lines":[{"line_number":335,"context_line":"        user.databases \u003d system.MONGO_ADMIN_DB"},{"line_number":336,"context_line":"        with MongoDBClient(user, auth\u003dFalse) as client:"},{"line_number":337,"context_line":"            MongoDBAdmin().create_user(user, client\u003dclient)"},{"line_number":338,"context_line":"        LOG.debug(_(\"Created admin user.\"))"},{"line_number":339,"context_line":""},{"line_number":340,"context_line":"    def secure(self, key\u003dNone):"},{"line_number":341,"context_line":"        # Secure the server by storing the cluster key"}],"source_content_type":"text/x-python","patch_set":2,"id":"5afe65bd_aa771e39","line":338,"updated":"2015-06-03 06:56:53.000000000","message":"No internationalization needed with debug messages.","commit_id":"f0c7095d302f6edd6f380e6df562832aa0157ccf"},{"author":{"_account_id":15321,"name":"Matthew Van Dijk","email":"mvandijk@tesora.com","username":"mvandijk"},"change_message_id":"04424e69191dd729c1b12bd50f75ccf8938a5381","unresolved":false,"context_lines":[{"line_number":335,"context_line":"        user.databases \u003d system.MONGO_ADMIN_DB"},{"line_number":336,"context_line":"        with MongoDBClient(user, auth\u003dFalse) as client:"},{"line_number":337,"context_line":"            MongoDBAdmin().create_user(user, client\u003dclient)"},{"line_number":338,"context_line":"        LOG.debug(_(\"Created admin user.\"))"},{"line_number":339,"context_line":""},{"line_number":340,"context_line":"    def secure(self, key\u003dNone):"},{"line_number":341,"context_line":"        # Secure the server by storing the cluster key"}],"source_content_type":"text/x-python","patch_set":2,"id":"5afe65bd_18c8be21","line":338,"in_reply_to":"5afe65bd_aa771e39","updated":"2015-06-03 13:20:26.000000000","message":"ok","commit_id":"f0c7095d302f6edd6f380e6df562832aa0157ccf"},{"author":{"_account_id":9782,"name":"Morgan Jones","email":"morgan@tesora.com","username":"vgnbkr"},"change_message_id":"c7fec2f303cf45ccb80741bb6377698174b6525f","unresolved":false,"context_lines":[{"line_number":343,"context_line":"        # This is done after MongoDB is first installed, while"},{"line_number":344,"context_line":"        # the localhost exception is still active."},{"line_number":345,"context_line":"        self.start_db()"},{"line_number":346,"context_line":"        if key:"},{"line_number":347,"context_line":"            self._store_key(key)"},{"line_number":348,"context_line":"        self._create_admin_user()"},{"line_number":349,"context_line":"        self.stop_db()"}],"source_content_type":"text/x-python","patch_set":2,"id":"5afe65bd_4a11d8ab","line":346,"updated":"2015-06-03 18:39:04.000000000","message":"Do we intend to support MongoDB databases without keys?","commit_id":"f0c7095d302f6edd6f380e6df562832aa0157ccf"},{"author":{"_account_id":9782,"name":"Morgan Jones","email":"morgan@tesora.com","username":"vgnbkr"},"change_message_id":"c7fec2f303cf45ccb80741bb6377698174b6525f","unresolved":false,"context_lines":[{"line_number":405,"context_line":"    \"\"\"Handles administrative tasks on MongoDB.\"\"\""},{"line_number":406,"context_line":""},{"line_number":407,"context_line":"    # user is cached by making it a class attribute"},{"line_number":408,"context_line":"    __admin_user \u003d None"},{"line_number":409,"context_line":""},{"line_number":410,"context_line":"    def _admin_user(self):"},{"line_number":411,"context_line":"        if not type(self).__admin_user:"}],"source_content_type":"text/x-python","patch_set":2,"id":"5afe65bd_4a88b8e7","line":408,"updated":"2015-06-03 18:39:04.000000000","message":"This is a class variable, so no need for underscores.","commit_id":"f0c7095d302f6edd6f380e6df562832aa0157ccf"},{"author":{"_account_id":9782,"name":"Morgan Jones","email":"morgan@tesora.com","username":"vgnbkr"},"change_message_id":"c7fec2f303cf45ccb80741bb6377698174b6525f","unresolved":false,"context_lines":[{"line_number":479,"context_line":"        :param auth: set to False to disable authentication, default True"},{"line_number":480,"context_line":"        :return:"},{"line_number":481,"context_line":"        \"\"\""},{"line_number":482,"context_line":"        if not type(self).__engine:"},{"line_number":483,"context_line":"            LOG.debug(\"Creating MongoDB client.\")"},{"line_number":484,"context_line":"            type(self).__engine \u003d pymongo.MongoClient(host\u003dhost, port\u003dport,"},{"line_number":485,"context_line":"                                                      connect\u003dFalse)"}],"source_content_type":"text/x-python","patch_set":2,"id":"5afe65bd_ef777600","line":482,"updated":"2015-06-03 18:39:04.000000000","message":"Doesn\u0027t this reference the __engine property of derived classes?  Is that really what you mean to do?","commit_id":"f0c7095d302f6edd6f380e6df562832aa0157ccf"},{"author":{"_account_id":9782,"name":"Morgan Jones","email":"morgan@tesora.com","username":"vgnbkr"},"change_message_id":"c7fec2f303cf45ccb80741bb6377698174b6525f","unresolved":false,"context_lines":[{"line_number":483,"context_line":"            LOG.debug(\"Creating MongoDB client.\")"},{"line_number":484,"context_line":"            type(self).__engine \u003d pymongo.MongoClient(host\u003dhost, port\u003dport,"},{"line_number":485,"context_line":"                                                      connect\u003dFalse)"},{"line_number":486,"context_line":"        self.__session \u003d type(self).__engine"},{"line_number":487,"context_line":"        if not database:"},{"line_number":488,"context_line":"            schema \u003d user.databases[0]"},{"line_number":489,"context_line":"            database \u003d models.MongoDBSchema.deserialize_schema(schema).name"}],"source_content_type":"text/x-python","patch_set":2,"id":"5afe65bd_6ad134cd","line":486,"updated":"2015-06-03 18:39:04.000000000","message":"Just use self.session.","commit_id":"f0c7095d302f6edd6f380e6df562832aa0157ccf"},{"author":{"_account_id":9782,"name":"Morgan Jones","email":"morgan@tesora.com","username":"vgnbkr"},"change_message_id":"c7fec2f303cf45ccb80741bb6377698174b6525f","unresolved":false,"context_lines":[{"line_number":488,"context_line":"            schema \u003d user.databases[0]"},{"line_number":489,"context_line":"            database \u003d models.MongoDBSchema.deserialize_schema(schema).name"},{"line_number":490,"context_line":"        LOG.debug(\"Connecting MongoDB client to %s.\" % database)"},{"line_number":491,"context_line":"        self.__db \u003d self.__session[database]"},{"line_number":492,"context_line":"        if auth:"},{"line_number":493,"context_line":"            self.__db.authenticate(user.name, password\u003duser.password)"},{"line_number":494,"context_line":"        self.__user \u003d user"}],"source_content_type":"text/x-python","patch_set":2,"id":"5afe65bd_0ad9a0f3","line":491,"updated":"2015-06-03 18:39:04.000000000","message":"Again, just use self.db","commit_id":"f0c7095d302f6edd6f380e6df562832aa0157ccf"},{"author":{"_account_id":9782,"name":"Morgan Jones","email":"morgan@tesora.com","username":"vgnbkr"},"change_message_id":"c7fec2f303cf45ccb80741bb6377698174b6525f","unresolved":false,"context_lines":[{"line_number":516,"context_line":"        if password:"},{"line_number":517,"context_line":"            self.password \u003d password"},{"line_number":518,"context_line":""},{"line_number":519,"context_line":"    username_tag \u003d \u0027username\u0027"},{"line_number":520,"context_line":"    password_tag \u003d \u0027password\u0027"},{"line_number":521,"context_line":""},{"line_number":522,"context_line":"    @property"}],"source_content_type":"text/x-python","patch_set":2,"id":"5afe65bd_eab9a42f","line":519,"updated":"2015-06-03 18:39:04.000000000","message":"Just use the values inline - defining them like this isn\u0027t really pythonic.","commit_id":"f0c7095d302f6edd6f380e6df562832aa0157ccf"},{"author":{"_account_id":9782,"name":"Morgan Jones","email":"morgan@tesora.com","username":"vgnbkr"},"change_message_id":"c7fec2f303cf45ccb80741bb6377698174b6525f","unresolved":false,"context_lines":[{"line_number":519,"context_line":"    username_tag \u003d \u0027username\u0027"},{"line_number":520,"context_line":"    password_tag \u003d \u0027password\u0027"},{"line_number":521,"context_line":""},{"line_number":522,"context_line":"    @property"},{"line_number":523,"context_line":"    def username(self):"},{"line_number":524,"context_line":"        return self._username"},{"line_number":525,"context_line":""}],"source_content_type":"text/x-python","patch_set":2,"id":"5afe65bd_ca5f080d","line":522,"updated":"2015-06-03 18:39:04.000000000","message":"Why are you defining these as properties?  These methods aren\u0027t doing anything the default property methods don\u0027t do.","commit_id":"f0c7095d302f6edd6f380e6df562832aa0157ccf"},{"author":{"_account_id":9782,"name":"Morgan Jones","email":"morgan@tesora.com","username":"vgnbkr"},"change_message_id":"c7fec2f303cf45ccb80741bb6377698174b6525f","unresolved":false,"context_lines":[{"line_number":542,"context_line":"            self.password \u003d credentials[MongoDBCredentials.password_tag]"},{"line_number":543,"context_line":""},{"line_number":544,"context_line":"    def write(self, filename):"},{"line_number":545,"context_line":"        self.clear_file(filename)"},{"line_number":546,"context_line":"        with open(filename, \u0027w\u0027) as f:"},{"line_number":547,"context_line":"            credentials \u003d {MongoDBCredentials.username_tag: self.username,"},{"line_number":548,"context_line":"                           MongoDBCredentials.password_tag: self.password}"}],"source_content_type":"text/x-python","patch_set":2,"id":"5afe65bd_eabe44fe","line":545,"updated":"2015-06-03 18:39:04.000000000","message":"Why are you clearing the file?  Can\u0027t you just write it then set the permissions?","commit_id":"f0c7095d302f6edd6f380e6df562832aa0157ccf"},{"author":{"_account_id":7806,"name":"Sushil Kumar","email":"skm.net@gmail.com","username":"sushilkm"},"change_message_id":"0cd28f80822ec2c683dc291ba78802a7096a7bce","unresolved":false,"context_lines":[{"line_number":554,"context_line":"        if operating_system.file_discovery([filename]):"},{"line_number":555,"context_line":"            operating_system.remove(filename)"},{"line_number":556,"context_line":"        rc_file \u003d open(filename, \u0027wb\u0027)"},{"line_number":557,"context_line":"        rc_file.close()"},{"line_number":558,"context_line":"        operating_system.chmod(filename,"},{"line_number":559,"context_line":"                               operating_system.FileMode.SET_USR_RW,"},{"line_number":560,"context_line":"                               as_root\u003dTrue)"}],"source_content_type":"text/x-python","patch_set":2,"id":"5afe65bd_2a368e52","line":557,"updated":"2015-06-03 06:56:53.000000000","message":"strange, just open and close without any operations.","commit_id":"f0c7095d302f6edd6f380e6df562832aa0157ccf"},{"author":{"_account_id":15321,"name":"Matthew Van Dijk","email":"mvandijk@tesora.com","username":"mvandijk"},"change_message_id":"04424e69191dd729c1b12bd50f75ccf8938a5381","unresolved":false,"context_lines":[{"line_number":554,"context_line":"        if operating_system.file_discovery([filename]):"},{"line_number":555,"context_line":"            operating_system.remove(filename)"},{"line_number":556,"context_line":"        rc_file \u003d open(filename, \u0027wb\u0027)"},{"line_number":557,"context_line":"        rc_file.close()"},{"line_number":558,"context_line":"        operating_system.chmod(filename,"},{"line_number":559,"context_line":"                               operating_system.FileMode.SET_USR_RW,"},{"line_number":560,"context_line":"                               as_root\u003dTrue)"}],"source_content_type":"text/x-python","patch_set":2,"id":"5afe65bd_58c5163a","line":557,"in_reply_to":"5afe65bd_2a368e52","updated":"2015-06-03 13:20:26.000000000","message":"Forces the creation. I was contemplating just the following: open(filename, \u0027wb\u0027) as the garbage collection would clean it up right away. I\u0027ll change to that and add a comment.","commit_id":"f0c7095d302f6edd6f380e6df562832aa0157ccf"},{"author":{"_account_id":14576,"name":"Petr Malik","email":"pmalik@tesora.com","username":"pmalik"},"change_message_id":"4ef8990999e23e79909dab05d40a3c82b820e9ce","unresolved":false,"context_lines":[{"line_number":261,"context_line":"        \"\"\""},{"line_number":262,"context_line":"        url \u003d \"%s/%s:%s\" % (replica_set_name, replica_set_member,"},{"line_number":263,"context_line":"                            system.MONGO_PORT)"},{"line_number":264,"context_line":"        MongoDBAdmin().add_shard(url)"},{"line_number":265,"context_line":""},{"line_number":266,"context_line":"    def add_members(self, members):"},{"line_number":267,"context_line":"        \"\"\""}],"source_content_type":"text/x-python","patch_set":5,"id":"5afe65bd_4295e53c","line":264,"updated":"2015-06-04 19:01:11.000000000","message":"The Admin object could probably be cached as an instance variable and reused.","commit_id":"5f0900411a0f5bbfccd6c63bdbd78b6833455696"},{"author":{"_account_id":14576,"name":"Petr Malik","email":"pmalik@tesora.com","username":"pmalik"},"change_message_id":"4ef8990999e23e79909dab05d40a3c82b820e9ce","unresolved":false,"context_lines":[{"line_number":520,"context_line":"        if password:"},{"line_number":521,"context_line":"            self.password \u003d password"},{"line_number":522,"context_line":""},{"line_number":523,"context_line":"    username_tag \u003d \u0027username\u0027"},{"line_number":524,"context_line":"    password_tag \u003d \u0027password\u0027"},{"line_number":525,"context_line":""},{"line_number":526,"context_line":"    @property"}],"source_content_type":"text/x-python","patch_set":5,"id":"5afe65bd_8544071b","line":523,"range":{"start_line":523,"start_character":4,"end_line":523,"end_character":16},"updated":"2015-06-04 19:01:11.000000000","message":"Constants are usually defined at the beginning of the class in uppercase.","commit_id":"5f0900411a0f5bbfccd6c63bdbd78b6833455696"},{"author":{"_account_id":6413,"name":"Victoria Martinez de la Cruz","email":"victoria@redhat.com","username":"vkmc"},"change_message_id":"738cc8eb5953fb6c7b4adb2ae21498b940c1c2f7","unresolved":false,"context_lines":[{"line_number":559,"context_line":"    \"\"\"Handles storing/retrieving credentials. Stored as json in files.\"\"\""},{"line_number":560,"context_line":""},{"line_number":561,"context_line":"    def __init__(self, username\u003dNone, password\u003dNone):"},{"line_number":562,"context_line":"        self._username \u003d None"},{"line_number":563,"context_line":"        self._password \u003d None"},{"line_number":564,"context_line":"        if username:"},{"line_number":565,"context_line":"            self.username \u003d username"}],"source_content_type":"text/x-python","patch_set":14,"id":"fa32b979_8350fcd5","line":562,"updated":"2015-06-22 11:10:11.000000000","message":"This could be written as self._username \u003d username if self.username else None","commit_id":"59facd61b6a657abc110ed0fab08ba3823a383d1"},{"author":{"_account_id":15321,"name":"Matthew Van Dijk","email":"mvandijk@tesora.com","username":"mvandijk"},"change_message_id":"cbcec005c49e4d5aa8bd4b20da630f0a005c866d","unresolved":false,"context_lines":[{"line_number":559,"context_line":"    \"\"\"Handles storing/retrieving credentials. Stored as json in files.\"\"\""},{"line_number":560,"context_line":""},{"line_number":561,"context_line":"    def __init__(self, username\u003dNone, password\u003dNone):"},{"line_number":562,"context_line":"        self._username \u003d None"},{"line_number":563,"context_line":"        self._password \u003d None"},{"line_number":564,"context_line":"        if username:"},{"line_number":565,"context_line":"            self.username \u003d username"}],"source_content_type":"text/x-python","patch_set":14,"id":"fa32b979_f7409f09","line":562,"in_reply_to":"fa32b979_8350fcd5","updated":"2015-06-22 17:44:04.000000000","message":"I had those in for validation purposes and forgot to remove (validation handled in the mongodb user model). I will clean this all up.","commit_id":"59facd61b6a657abc110ed0fab08ba3823a383d1"},{"author":{"_account_id":6413,"name":"Victoria Martinez de la Cruz","email":"victoria@redhat.com","username":"vkmc"},"change_message_id":"738cc8eb5953fb6c7b4adb2ae21498b940c1c2f7","unresolved":false,"context_lines":[{"line_number":560,"context_line":""},{"line_number":561,"context_line":"    def __init__(self, username\u003dNone, password\u003dNone):"},{"line_number":562,"context_line":"        self._username \u003d None"},{"line_number":563,"context_line":"        self._password \u003d None"},{"line_number":564,"context_line":"        if username:"},{"line_number":565,"context_line":"            self.username \u003d username"},{"line_number":566,"context_line":"        if password:"}],"source_content_type":"text/x-python","patch_set":14,"id":"fa32b979_432f543e","line":563,"updated":"2015-06-22 11:10:11.000000000","message":"This could be written as self._password \u003d password if self.password else None","commit_id":"59facd61b6a657abc110ed0fab08ba3823a383d1"},{"author":{"_account_id":6413,"name":"Victoria Martinez de la Cruz","email":"victoria@redhat.com","username":"vkmc"},"change_message_id":"738cc8eb5953fb6c7b4adb2ae21498b940c1c2f7","unresolved":false,"context_lines":[{"line_number":562,"context_line":"        self._username \u003d None"},{"line_number":563,"context_line":"        self._password \u003d None"},{"line_number":564,"context_line":"        if username:"},{"line_number":565,"context_line":"            self.username \u003d username"},{"line_number":566,"context_line":"        if password:"},{"line_number":567,"context_line":"            self.password \u003d password"},{"line_number":568,"context_line":""}],"source_content_type":"text/x-python","patch_set":14,"id":"fa32b979_a3c42092","line":565,"updated":"2015-06-22 11:10:11.000000000","message":"self._username \u003d username","commit_id":"59facd61b6a657abc110ed0fab08ba3823a383d1"},{"author":{"_account_id":6413,"name":"Victoria Martinez de la Cruz","email":"victoria@redhat.com","username":"vkmc"},"change_message_id":"738cc8eb5953fb6c7b4adb2ae21498b940c1c2f7","unresolved":false,"context_lines":[{"line_number":564,"context_line":"        if username:"},{"line_number":565,"context_line":"            self.username \u003d username"},{"line_number":566,"context_line":"        if password:"},{"line_number":567,"context_line":"            self.password \u003d password"},{"line_number":568,"context_line":""},{"line_number":569,"context_line":"    username_tag \u003d \u0027username\u0027"},{"line_number":570,"context_line":"    password_tag \u003d \u0027password\u0027"}],"source_content_type":"text/x-python","patch_set":14,"id":"fa32b979_63be1801","line":567,"updated":"2015-06-22 11:10:11.000000000","message":"self._password \u003d password","commit_id":"59facd61b6a657abc110ed0fab08ba3823a383d1"},{"author":{"_account_id":6413,"name":"Victoria Martinez de la Cruz","email":"victoria@redhat.com","username":"vkmc"},"change_message_id":"738cc8eb5953fb6c7b4adb2ae21498b940c1c2f7","unresolved":false,"context_lines":[{"line_number":566,"context_line":"        if password:"},{"line_number":567,"context_line":"            self.password \u003d password"},{"line_number":568,"context_line":""},{"line_number":569,"context_line":"    username_tag \u003d \u0027username\u0027"},{"line_number":570,"context_line":"    password_tag \u003d \u0027password\u0027"},{"line_number":571,"context_line":""},{"line_number":572,"context_line":"    @property"}],"source_content_type":"text/x-python","patch_set":14,"id":"fa32b979_23dd7014","line":569,"updated":"2015-06-22 11:10:11.000000000","message":"This is a default in case no username is provided?","commit_id":"59facd61b6a657abc110ed0fab08ba3823a383d1"},{"author":{"_account_id":6413,"name":"Victoria Martinez de la Cruz","email":"victoria@redhat.com","username":"vkmc"},"change_message_id":"738cc8eb5953fb6c7b4adb2ae21498b940c1c2f7","unresolved":false,"context_lines":[{"line_number":588,"context_line":"    def read(self, filename):"},{"line_number":589,"context_line":"        with open(filename) as f:"},{"line_number":590,"context_line":"            credentials \u003d json.load(f)"},{"line_number":591,"context_line":"            self.username \u003d credentials[MongoDBCredentials.username_tag]"},{"line_number":592,"context_line":"            self.password \u003d credentials[MongoDBCredentials.password_tag]"},{"line_number":593,"context_line":""},{"line_number":594,"context_line":"    def write(self, filename):"}],"source_content_type":"text/x-python","patch_set":14,"id":"fa32b979_a33f4024","line":591,"updated":"2015-06-22 11:10:11.000000000","message":"self._username","commit_id":"59facd61b6a657abc110ed0fab08ba3823a383d1"},{"author":{"_account_id":6413,"name":"Victoria Martinez de la Cruz","email":"victoria@redhat.com","username":"vkmc"},"change_message_id":"738cc8eb5953fb6c7b4adb2ae21498b940c1c2f7","unresolved":false,"context_lines":[{"line_number":589,"context_line":"        with open(filename) as f:"},{"line_number":590,"context_line":"            credentials \u003d json.load(f)"},{"line_number":591,"context_line":"            self.username \u003d credentials[MongoDBCredentials.username_tag]"},{"line_number":592,"context_line":"            self.password \u003d credentials[MongoDBCredentials.password_tag]"},{"line_number":593,"context_line":""},{"line_number":594,"context_line":"    def write(self, filename):"},{"line_number":595,"context_line":"        self.clear_file(filename)"}],"source_content_type":"text/x-python","patch_set":14,"id":"fa32b979_c33a8434","line":592,"updated":"2015-06-22 11:10:11.000000000","message":"self._password","commit_id":"59facd61b6a657abc110ed0fab08ba3823a383d1"},{"author":{"_account_id":6413,"name":"Victoria Martinez de la Cruz","email":"victoria@redhat.com","username":"vkmc"},"change_message_id":"738cc8eb5953fb6c7b4adb2ae21498b940c1c2f7","unresolved":false,"context_lines":[{"line_number":594,"context_line":"    def write(self, filename):"},{"line_number":595,"context_line":"        self.clear_file(filename)"},{"line_number":596,"context_line":"        with open(filename, \u0027w\u0027) as f:"},{"line_number":597,"context_line":"            credentials \u003d {MongoDBCredentials.username_tag: self.username,"},{"line_number":598,"context_line":"                           MongoDBCredentials.password_tag: self.password}"},{"line_number":599,"context_line":"            json.dump(credentials, f)"},{"line_number":600,"context_line":""}],"source_content_type":"text/x-python","patch_set":14,"id":"fa32b979_43151499","line":597,"updated":"2015-06-22 11:10:11.000000000","message":"Ditto","commit_id":"59facd61b6a657abc110ed0fab08ba3823a383d1"},{"author":{"_account_id":14576,"name":"Petr Malik","email":"pmalik@tesora.com","username":"pmalik"},"change_message_id":"15376238a295f3e6f062dc74748d132000e2871b","unresolved":false,"context_lines":[{"line_number":526,"context_line":"    # engine is cached by making it a class attribute"},{"line_number":527,"context_line":"    engine \u003d None"},{"line_number":528,"context_line":""},{"line_number":529,"context_line":"    def __init__(self, user, host\u003d\u0027localhost\u0027, port\u003dMONGODB_PORT,"},{"line_number":530,"context_line":"                 auth\u003dTrue):"},{"line_number":531,"context_line":"        \"\"\""},{"line_number":532,"context_line":"        :param user: (required) MongoDBUser instance"}],"source_content_type":"text/x-python","patch_set":17,"id":"fa32b979_f4c25d33","line":529,"updated":"2015-06-24 18:09:14.000000000","message":"Specifing the port and host won\u0027t have any effect when the client is already cached.","commit_id":"aaeb322d118c132d737e1e07892f685dd66d24f8"},{"author":{"_account_id":6413,"name":"Victoria Martinez de la Cruz","email":"victoria@redhat.com","username":"vkmc"},"change_message_id":"640fb10e936935547e2da0ee999b98f706afaac9","unresolved":false,"context_lines":[{"line_number":506,"context_line":"        with MongoDBClient(self._admin_user()) as admin_client:"},{"line_number":507,"context_line":"            # get the current config, add the new members, then save it"},{"line_number":508,"context_line":"            config \u003d admin_client.admin.command(\u0027replSetGetConfig\u0027)[\u0027config\u0027]"},{"line_number":509,"context_line":"            config[\u0027version\u0027] +\u003d 1"},{"line_number":510,"context_line":"            next_id \u003d max([m[\u0027_id\u0027] for m in config[\u0027members\u0027]]) + 1"},{"line_number":511,"context_line":"            for member in members:"},{"line_number":512,"context_line":"                config[\u0027members\u0027].append({\u0027_id\u0027: next_id, \u0027host\u0027: member})"}],"source_content_type":"text/x-python","patch_set":18,"id":"fa32b979_45d31f04","line":509,"updated":"2015-06-25 19:17:13.000000000","message":"Why is this needed?","commit_id":"5d05ebc04954bf98c6a487948cf565ab334792df"},{"author":{"_account_id":15321,"name":"Matthew Van Dijk","email":"mvandijk@tesora.com","username":"mvandijk"},"change_message_id":"f4aea28d8f5054761e4203a039189763c1c47f96","unresolved":false,"context_lines":[{"line_number":506,"context_line":"        with MongoDBClient(self._admin_user()) as admin_client:"},{"line_number":507,"context_line":"            # get the current config, add the new members, then save it"},{"line_number":508,"context_line":"            config \u003d admin_client.admin.command(\u0027replSetGetConfig\u0027)[\u0027config\u0027]"},{"line_number":509,"context_line":"            config[\u0027version\u0027] +\u003d 1"},{"line_number":510,"context_line":"            next_id \u003d max([m[\u0027_id\u0027] for m in config[\u0027members\u0027]]) + 1"},{"line_number":511,"context_line":"            for member in members:"},{"line_number":512,"context_line":"                config[\u0027members\u0027].append({\u0027_id\u0027: next_id, \u0027host\u0027: member})"}],"source_content_type":"text/x-python","patch_set":18,"id":"fa32b979_5295f285","line":509,"in_reply_to":"fa32b979_45d31f04","updated":"2015-06-26 17:39:06.000000000","message":"When changing the replica set config in MongoDB you should increment the version. See http://docs.mongodb.org/manual/reference/method/rs.reconfig/#rs.reconfig","commit_id":"5d05ebc04954bf98c6a487948cf565ab334792df"},{"author":{"_account_id":14576,"name":"Petr Malik","email":"pmalik@tesora.com","username":"pmalik"},"change_message_id":"bbfb730ae63b03326ddaa89e438c3582bd1cd1df","unresolved":false,"context_lines":[{"line_number":547,"context_line":"            if host:"},{"line_number":548,"context_line":"                type(self).engine[\u0027host\u0027] \u003d host"},{"line_number":549,"context_line":"            if port:"},{"line_number":550,"context_line":"                type(self).engine[\u0027host\u0027] \u003d port"},{"line_number":551,"context_line":"            new_client \u003d True"},{"line_number":552,"context_line":"        if new_client:"},{"line_number":553,"context_line":"            host \u003d type(self).engine[\u0027host\u0027]"}],"source_content_type":"text/x-python","patch_set":18,"id":"fa32b979_8b461520","line":550,"updated":"2015-06-25 19:38:29.000000000","message":"BUG: the key should be \u0027port\u0027.","commit_id":"5d05ebc04954bf98c6a487948cf565ab334792df"},{"author":{"_account_id":15321,"name":"Matthew Van Dijk","email":"mvandijk@tesora.com","username":"mvandijk"},"change_message_id":"f4aea28d8f5054761e4203a039189763c1c47f96","unresolved":false,"context_lines":[{"line_number":547,"context_line":"            if host:"},{"line_number":548,"context_line":"                type(self).engine[\u0027host\u0027] \u003d host"},{"line_number":549,"context_line":"            if port:"},{"line_number":550,"context_line":"                type(self).engine[\u0027host\u0027] \u003d port"},{"line_number":551,"context_line":"            new_client \u003d True"},{"line_number":552,"context_line":"        if new_client:"},{"line_number":553,"context_line":"            host \u003d type(self).engine[\u0027host\u0027]"}],"source_content_type":"text/x-python","patch_set":18,"id":"fa32b979_721cb613","line":550,"in_reply_to":"fa32b979_8b461520","updated":"2015-06-26 17:39:06.000000000","message":"Done.","commit_id":"5d05ebc04954bf98c6a487948cf565ab334792df"}],"trove/guestagent/datastore/experimental/mongodb/system.py":[{"author":{"_account_id":7806,"name":"Sushil Kumar","email":"skm.net@gmail.com","username":"sushilkm"},"change_message_id":"0cd28f80822ec2c683dc291ba78802a7096a7bce","unresolved":false,"context_lines":[{"line_number":24,"context_line":"# After changing bind address mongodb accepts connection"},{"line_number":25,"context_line":"# on real IP, not on the localhost"},{"line_number":26,"context_line":"CMD_STATUS \u003d \"mongostat --host %s -n 1\""},{"line_number":27,"context_line":"LOCALHOST \u003d \u0027localhost\u0027"},{"line_number":28,"context_line":"MONGO_PORT \u003d 27017"},{"line_number":29,"context_line":""},{"line_number":30,"context_line":"TMP_CONFIG \u003d \"/tmp/mongodb.conf.tmp\""}],"source_content_type":"text/x-python","patch_set":2,"id":"5afe65bd_4a166aa8","line":27,"updated":"2015-06-03 06:56:53.000000000","message":"do we need this as a variable because variable name and value are same except for case","commit_id":"f0c7095d302f6edd6f380e6df562832aa0157ccf"},{"author":{"_account_id":15321,"name":"Matthew Van Dijk","email":"mvandijk@tesora.com","username":"mvandijk"},"change_message_id":"04424e69191dd729c1b12bd50f75ccf8938a5381","unresolved":false,"context_lines":[{"line_number":24,"context_line":"# After changing bind address mongodb accepts connection"},{"line_number":25,"context_line":"# on real IP, not on the localhost"},{"line_number":26,"context_line":"CMD_STATUS \u003d \"mongostat --host %s -n 1\""},{"line_number":27,"context_line":"LOCALHOST \u003d \u0027localhost\u0027"},{"line_number":28,"context_line":"MONGO_PORT \u003d 27017"},{"line_number":29,"context_line":""},{"line_number":30,"context_line":"TMP_CONFIG \u003d \"/tmp/mongodb.conf.tmp\""}],"source_content_type":"text/x-python","patch_set":2,"id":"5afe65bd_736475e4","line":27,"in_reply_to":"5afe65bd_4a166aa8","updated":"2015-06-03 13:20:26.000000000","message":"I agree. At the time I wasn\u0027t sure if I would need to use the string \u0027localhost\u0027 multiple times. I will remove this.","commit_id":"f0c7095d302f6edd6f380e6df562832aa0157ccf"},{"author":{"_account_id":7806,"name":"Sushil Kumar","email":"skm.net@gmail.com","username":"sushilkm"},"change_message_id":"0cd28f80822ec2c683dc291ba78802a7096a7bce","unresolved":false,"context_lines":[{"line_number":25,"context_line":"# on real IP, not on the localhost"},{"line_number":26,"context_line":"CMD_STATUS \u003d \"mongostat --host %s -n 1\""},{"line_number":27,"context_line":"LOCALHOST \u003d \u0027localhost\u0027"},{"line_number":28,"context_line":"MONGO_PORT \u003d 27017"},{"line_number":29,"context_line":""},{"line_number":30,"context_line":"TMP_CONFIG \u003d \"/tmp/mongodb.conf.tmp\""},{"line_number":31,"context_line":"CONFIG_CANDIDATES \u003d [\"/etc/mongodb.conf\", \"/etc/mongod.conf\"]"}],"source_content_type":"text/x-python","patch_set":2,"id":"5afe65bd_ca225a01","line":28,"updated":"2015-06-03 06:56:53.000000000","message":"I wonder if this could be part of some config value","commit_id":"f0c7095d302f6edd6f380e6df562832aa0157ccf"},{"author":{"_account_id":15321,"name":"Matthew Van Dijk","email":"mvandijk@tesora.com","username":"mvandijk"},"change_message_id":"04424e69191dd729c1b12bd50f75ccf8938a5381","unresolved":false,"context_lines":[{"line_number":25,"context_line":"# on real IP, not on the localhost"},{"line_number":26,"context_line":"CMD_STATUS \u003d \"mongostat --host %s -n 1\""},{"line_number":27,"context_line":"LOCALHOST \u003d \u0027localhost\u0027"},{"line_number":28,"context_line":"MONGO_PORT \u003d 27017"},{"line_number":29,"context_line":""},{"line_number":30,"context_line":"TMP_CONFIG \u003d \"/tmp/mongodb.conf.tmp\""},{"line_number":31,"context_line":"CONFIG_CANDIDATES \u003d [\"/etc/mongodb.conf\", \"/etc/mongod.conf\"]"}],"source_content_type":"text/x-python","patch_set":2,"id":"5afe65bd_d37c4974","line":28,"in_reply_to":"5afe65bd_ca225a01","updated":"2015-06-03 13:20:26.000000000","message":"This was being hardcoded in the service before. Switching to a config value is possible, but out of scope here.","commit_id":"f0c7095d302f6edd6f380e6df562832aa0157ccf"},{"author":{"_account_id":6413,"name":"Victoria Martinez de la Cruz","email":"victoria@redhat.com","username":"vkmc"},"change_message_id":"738cc8eb5953fb6c7b4adb2ae21498b940c1c2f7","unresolved":false,"context_lines":[{"line_number":24,"context_line":"# After changing bind address mongodb accepts connection"},{"line_number":25,"context_line":"# on real IP, not on the localhost"},{"line_number":26,"context_line":"CMD_STATUS \u003d \"mongostat --host %s -n 1\""},{"line_number":27,"context_line":"MONGO_PORT \u003d 27017"},{"line_number":28,"context_line":""},{"line_number":29,"context_line":"TMP_CONFIG \u003d \"/tmp/mongodb.conf.tmp\""},{"line_number":30,"context_line":"CONFIG_CANDIDATES \u003d [\"/etc/mongodb.conf\", \"/etc/mongod.conf\"]"}],"source_content_type":"text/x-python","patch_set":14,"id":"fa32b979_3d9ef3b8","line":27,"updated":"2015-06-22 11:10:11.000000000","message":"This should be configurable, in guestagent mongodb conf section.","commit_id":"59facd61b6a657abc110ed0fab08ba3823a383d1"},{"author":{"_account_id":15321,"name":"Matthew Van Dijk","email":"mvandijk@tesora.com","username":"mvandijk"},"change_message_id":"cbcec005c49e4d5aa8bd4b20da630f0a005c866d","unresolved":false,"context_lines":[{"line_number":24,"context_line":"# After changing bind address mongodb accepts connection"},{"line_number":25,"context_line":"# on real IP, not on the localhost"},{"line_number":26,"context_line":"CMD_STATUS \u003d \"mongostat --host %s -n 1\""},{"line_number":27,"context_line":"MONGO_PORT \u003d 27017"},{"line_number":28,"context_line":""},{"line_number":29,"context_line":"TMP_CONFIG \u003d \"/tmp/mongodb.conf.tmp\""},{"line_number":30,"context_line":"CONFIG_CANDIDATES \u003d [\"/etc/mongodb.conf\", \"/etc/mongod.conf\"]"}],"source_content_type":"text/x-python","patch_set":14,"id":"fa32b979_aba5ce47","line":27,"in_reply_to":"fa32b979_3d9ef3b8","updated":"2015-06-22 17:44:04.000000000","message":"done","commit_id":"59facd61b6a657abc110ed0fab08ba3823a383d1"}],"trove/guestagent/db/models.py":[{"author":{"_account_id":9782,"name":"Morgan Jones","email":"morgan@tesora.com","username":"vgnbkr"},"change_message_id":"c7fec2f303cf45ccb80741bb6377698174b6525f","unresolved":false,"context_lines":[{"line_number":90,"context_line":"            raise ValueError(_(\"\u0027%s\u0027 is not a valid schema name.\") % value)"},{"line_number":91,"context_line":""},{"line_number":92,"context_line":"    @abc.abstractproperty"},{"line_number":93,"context_line":"    def _max_schema_name_length(self):"},{"line_number":94,"context_line":"        \"\"\"Return the maximum valid schema name length if any."},{"line_number":95,"context_line":"        :returns:            Maximum schema name length or None if unlimited."},{"line_number":96,"context_line":"        \"\"\""}],"source_content_type":"text/x-python","patch_set":2,"id":"5afe65bd_8e27b663","line":93,"updated":"2015-06-03 18:39:04.000000000","message":"I don\u0027t understand why this is a property and why it has an underscore?","commit_id":"f0c7095d302f6edd6f380e6df562832aa0157ccf"},{"author":{"_account_id":9782,"name":"Morgan Jones","email":"morgan@tesora.com","username":"vgnbkr"},"change_message_id":"c7fec2f303cf45ccb80741bb6377698174b6525f","unresolved":false,"context_lines":[{"line_number":96,"context_line":"        \"\"\""},{"line_number":97,"context_line":""},{"line_number":98,"context_line":"    @abc.abstractmethod"},{"line_number":99,"context_line":"    def _is_valid_schema_name(self, value):"},{"line_number":100,"context_line":"        \"\"\"Validate a given schema name."},{"line_number":101,"context_line":"        :param value:        Validated schema name."},{"line_number":102,"context_line":"        :type value:         string"}],"source_content_type":"text/x-python","patch_set":2,"id":"5afe65bd_aed71222","line":99,"updated":"2015-06-03 18:39:04.000000000","message":"This is abstract, so it is implicitly not private, so why is there an underscore?","commit_id":"f0c7095d302f6edd6f380e6df562832aa0157ccf"},{"author":{"_account_id":9782,"name":"Morgan Jones","email":"morgan@tesora.com","username":"vgnbkr"},"change_message_id":"c7fec2f303cf45ccb80741bb6377698174b6525f","unresolved":false,"context_lines":[{"line_number":105,"context_line":""},{"line_number":106,"context_line":"    @classmethod"},{"line_number":107,"context_line":"    @abc.abstractmethod"},{"line_number":108,"context_line":"    def _dict_requirements(cls):"},{"line_number":109,"context_line":"        \"\"\"Get the dictionary requirements for a user created via"},{"line_number":110,"context_line":"        deserialization."},{"line_number":111,"context_line":"        :returns:           List of required dictionary keys."}],"source_content_type":"text/x-python","patch_set":2,"id":"5afe65bd_2ecb2274","line":108,"updated":"2015-06-03 18:39:04.000000000","message":"What does it mean to have an abstract class method?","commit_id":"f0c7095d302f6edd6f380e6df562832aa0157ccf"},{"author":{"_account_id":9782,"name":"Morgan Jones","email":"morgan@tesora.com","username":"vgnbkr"},"change_message_id":"c7fec2f303cf45ccb80741bb6377698174b6525f","unresolved":false,"context_lines":[{"line_number":125,"context_line":"        super(MongoDBSchema, self).__init__()"},{"line_number":126,"context_line":"        if (deserializing and name) or (not (deserializing or name)):"},{"line_number":127,"context_line":"            raise ValueError(\"Bad args.\")"},{"line_number":128,"context_line":"        if deserializing:"},{"line_number":129,"context_line":"            pass"},{"line_number":130,"context_line":"        else:"},{"line_number":131,"context_line":"            self.name \u003d name"}],"source_content_type":"text/x-python","patch_set":2,"id":"5afe65bd_0ea186a3","line":128,"updated":"2015-06-03 18:39:04.000000000","message":"Just make this a \"not deserializing\" - using pass here is just obfuscating","commit_id":"f0c7095d302f6edd6f380e6df562832aa0157ccf"},{"author":{"_account_id":9782,"name":"Morgan Jones","email":"morgan@tesora.com","username":"vgnbkr"},"change_message_id":"c7fec2f303cf45ccb80741bb6377698174b6525f","unresolved":false,"context_lines":[{"line_number":131,"context_line":"            self.name \u003d name"},{"line_number":132,"context_line":""},{"line_number":133,"context_line":"    @property"},{"line_number":134,"context_line":"    def _max_schema_name_length(self):"},{"line_number":135,"context_line":"        return 64"},{"line_number":136,"context_line":""},{"line_number":137,"context_line":"    def _is_valid_schema_name(self, value):"}],"source_content_type":"text/x-python","patch_set":2,"id":"5afe65bd_ae8cb235","line":134,"updated":"2015-06-03 18:39:04.000000000","message":"If it\u0027s a property, don\u0027t put an underscore on it.","commit_id":"f0c7095d302f6edd6f380e6df562832aa0157ccf"},{"author":{"_account_id":10295,"name":"mariam john","email":"mariamj@us.ibm.com","username":"mariamj"},"change_message_id":"94e0ce9269c4d96debe056d07e8ec750f5e58cd5","unresolved":false,"context_lines":[{"line_number":35,"context_line":""},{"line_number":36,"context_line":"class DatastoreSchema(Base):"},{"line_number":37,"context_line":"    \"\"\"Represents a database schema.\"\"\""},{"line_number":38,"context_line":""},{"line_number":39,"context_line":"    def __init__(self):"},{"line_number":40,"context_line":"        self._name \u003d None"},{"line_number":41,"context_line":"        self._collate \u003d None"}],"source_content_type":"text/x-python","patch_set":5,"id":"5afe65bd_c086a464","line":38,"updated":"2015-06-03 16:30:01.000000000","message":"I am having a little trouble here trying to understand this. So we have the MySQLDatabase class which has the following properties: name, collate and character_set. Then we have this new class DatastoreSchema that also defines the same properties. Is the intent of this class meant to be a generic class which other datastores can extend from or is it still something specific to Mongo.","commit_id":"5f0900411a0f5bbfccd6c63bdbd78b6833455696"},{"author":{"_account_id":15321,"name":"Matthew Van Dijk","email":"mvandijk@tesora.com","username":"mvandijk"},"change_message_id":"0208aab0504b9a1d7fd9b95f5cadd12434e4b899","unresolved":false,"context_lines":[{"line_number":35,"context_line":""},{"line_number":36,"context_line":"class DatastoreSchema(Base):"},{"line_number":37,"context_line":"    \"\"\"Represents a database schema.\"\"\""},{"line_number":38,"context_line":""},{"line_number":39,"context_line":"    def __init__(self):"},{"line_number":40,"context_line":"        self._name \u003d None"},{"line_number":41,"context_line":"        self._collate \u003d None"}],"source_content_type":"text/x-python","patch_set":5,"id":"5afe65bd_e6bd3869","line":38,"in_reply_to":"5afe65bd_c086a464","updated":"2015-06-03 16:47:07.000000000","message":"This is work done by Petr Malik that will also be leveraged by other datastores in the future.\nI didn\u0027t want to migrate MySQL over as that is out of scope of this work.","commit_id":"5f0900411a0f5bbfccd6c63bdbd78b6833455696"},{"author":{"_account_id":14576,"name":"Petr Malik","email":"pmalik@tesora.com","username":"pmalik"},"change_message_id":"00c5388c29802e8b6dedd53bb8b28a50dbd677f9","unresolved":false,"context_lines":[{"line_number":35,"context_line":""},{"line_number":36,"context_line":"class DatastoreSchema(Base):"},{"line_number":37,"context_line":"    \"\"\"Represents a database schema.\"\"\""},{"line_number":38,"context_line":""},{"line_number":39,"context_line":"    def __init__(self):"},{"line_number":40,"context_line":"        self._name \u003d None"},{"line_number":41,"context_line":"        self._collate \u003d None"}],"source_content_type":"text/x-python","patch_set":5,"id":"5afe65bd_2261c9d3","line":38,"in_reply_to":"5afe65bd_c086a464","updated":"2015-06-04 17:23:31.000000000","message":"Yes. The MySQL user and datastore should eventually override and extend these base classes. Updating MySQL classes would be out of scope of this patch set. That\u0027s for future once this merges.","commit_id":"5f0900411a0f5bbfccd6c63bdbd78b6833455696"},{"author":{"_account_id":14576,"name":"Petr Malik","email":"pmalik@tesora.com","username":"pmalik"},"change_message_id":"4ef8990999e23e79909dab05d40a3c82b820e9ce","unresolved":false,"context_lines":[{"line_number":44,"context_line":"    @classmethod"},{"line_number":45,"context_line":"    def deserialize_schema(cls, value):"},{"line_number":46,"context_line":"        if not cls._validate_dict(value):"},{"line_number":47,"context_line":"            raise ValueError(_(\"Bad dictionary.\"))"},{"line_number":48,"context_line":"        schema \u003d cls(deserializing\u003dTrue)"},{"line_number":49,"context_line":"        schema.deserialize(value)"},{"line_number":50,"context_line":"        return schema"}],"source_content_type":"text/x-python","patch_set":5,"id":"5afe65bd_a07a5175","line":47,"updated":"2015-06-04 19:01:11.000000000","message":"We could say something more self-explanatory, something along the lines of \u0027...required schema property is missing...\u0027","commit_id":"5f0900411a0f5bbfccd6c63bdbd78b6833455696"},{"author":{"_account_id":14576,"name":"Petr Malik","email":"pmalik@tesora.com","username":"pmalik"},"change_message_id":"4ef8990999e23e79909dab05d40a3c82b820e9ce","unresolved":false,"context_lines":[{"line_number":69,"context_line":"    @classmethod"},{"line_number":70,"context_line":"    def _validate_dict(cls, value):"},{"line_number":71,"context_line":"        reqs \u003d cls._dict_requirements()"},{"line_number":72,"context_line":"        if not ((isinstance(value, dict)) and"},{"line_number":73,"context_line":"                (all(key in value for key in reqs))):"},{"line_number":74,"context_line":"            return False"},{"line_number":75,"context_line":"        return True"}],"source_content_type":"text/x-python","patch_set":5,"id":"5afe65bd_403a7dcd","line":72,"updated":"2015-06-04 19:01:11.000000000","message":"This feels a bit confusing to me. What about something like:\n\nreturn isinstance(value, dict) and all(key in value for key in reqs)","commit_id":"5f0900411a0f5bbfccd6c63bdbd78b6833455696"},{"author":{"_account_id":14576,"name":"Petr Malik","email":"pmalik@tesora.com","username":"pmalik"},"change_message_id":"4ef8990999e23e79909dab05d40a3c82b820e9ce","unresolved":false,"context_lines":[{"line_number":123,"context_line":""},{"line_number":124,"context_line":"    def __init__(self, name\u003dNone, deserializing\u003dFalse):"},{"line_number":125,"context_line":"        super(MongoDBSchema, self).__init__()"},{"line_number":126,"context_line":"        if (deserializing and name) or (not (deserializing or name)):"},{"line_number":127,"context_line":"            raise ValueError(\"Bad args.\")"},{"line_number":128,"context_line":"        if deserializing:"},{"line_number":129,"context_line":"            pass"}],"source_content_type":"text/x-python","patch_set":5,"id":"3afb71cf_a4568204","line":126,"range":{"start_line":126,"start_character":45,"end_line":126,"end_character":58},"updated":"2015-06-04 19:01:11.000000000","message":"What about \u0027not (bool(deserializing) !\u003d bool(name))\u0027  [!\u003d is XOR]","commit_id":"5f0900411a0f5bbfccd6c63bdbd78b6833455696"},{"author":{"_account_id":10295,"name":"mariam john","email":"mariamj@us.ibm.com","username":"mariamj"},"change_message_id":"94e0ce9269c4d96debe056d07e8ec750f5e58cd5","unresolved":false,"context_lines":[{"line_number":125,"context_line":"        super(MongoDBSchema, self).__init__()"},{"line_number":126,"context_line":"        if (deserializing and name) or (not (deserializing or name)):"},{"line_number":127,"context_line":"            raise ValueError(\"Bad args.\")"},{"line_number":128,"context_line":"        if deserializing:"},{"line_number":129,"context_line":"            pass"},{"line_number":130,"context_line":"        else:"},{"line_number":131,"context_line":"            self.name \u003d name"}],"source_content_type":"text/x-python","patch_set":5,"id":"5afe65bd_05696e8b","line":128,"updated":"2015-06-03 16:30:01.000000000","message":"need to add _ for translation","commit_id":"5f0900411a0f5bbfccd6c63bdbd78b6833455696"},{"author":{"_account_id":15321,"name":"Matthew Van Dijk","email":"mvandijk@tesora.com","username":"mvandijk"},"change_message_id":"0208aab0504b9a1d7fd9b95f5cadd12434e4b899","unresolved":false,"context_lines":[{"line_number":125,"context_line":"        super(MongoDBSchema, self).__init__()"},{"line_number":126,"context_line":"        if (deserializing and name) or (not (deserializing or name)):"},{"line_number":127,"context_line":"            raise ValueError(\"Bad args.\")"},{"line_number":128,"context_line":"        if deserializing:"},{"line_number":129,"context_line":"            pass"},{"line_number":130,"context_line":"        else:"},{"line_number":131,"context_line":"            self.name \u003d name"}],"source_content_type":"text/x-python","patch_set":5,"id":"5afe65bd_c6c0fce2","line":128,"in_reply_to":"5afe65bd_05696e8b","updated":"2015-06-03 16:47:07.000000000","message":"ok","commit_id":"5f0900411a0f5bbfccd6c63bdbd78b6833455696"},{"author":{"_account_id":10295,"name":"mariam john","email":"mariamj@us.ibm.com","username":"mariamj"},"change_message_id":"94e0ce9269c4d96debe056d07e8ec750f5e58cd5","unresolved":false,"context_lines":[{"line_number":129,"context_line":"            pass"},{"line_number":130,"context_line":"        else:"},{"line_number":131,"context_line":"            self.name \u003d name"},{"line_number":132,"context_line":""},{"line_number":133,"context_line":"    @property"},{"line_number":134,"context_line":"    def _max_schema_name_length(self):"},{"line_number":135,"context_line":"        return 64"}],"source_content_type":"text/x-python","patch_set":5,"id":"5afe65bd_c564764a","line":132,"updated":"2015-06-03 16:30:01.000000000","message":"why are we defining a new instance variable name when _name is already being defined in DatastoreSchema?","commit_id":"5f0900411a0f5bbfccd6c63bdbd78b6833455696"},{"author":{"_account_id":15321,"name":"Matthew Van Dijk","email":"mvandijk@tesora.com","username":"mvandijk"},"change_message_id":"0208aab0504b9a1d7fd9b95f5cadd12434e4b899","unresolved":false,"context_lines":[{"line_number":129,"context_line":"            pass"},{"line_number":130,"context_line":"        else:"},{"line_number":131,"context_line":"            self.name \u003d name"},{"line_number":132,"context_line":""},{"line_number":133,"context_line":"    @property"},{"line_number":134,"context_line":"    def _max_schema_name_length(self):"},{"line_number":135,"context_line":"        return 64"}],"source_content_type":"text/x-python","patch_set":5,"id":"5afe65bd_c64ebc95","line":132,"in_reply_to":"5afe65bd_c564764a","updated":"2015-06-03 16:47:07.000000000","message":"self.name calls the setter to the name property (which sets _name).","commit_id":"5f0900411a0f5bbfccd6c63bdbd78b6833455696"},{"author":{"_account_id":10295,"name":"mariam john","email":"mariamj@us.ibm.com","username":"mariamj"},"change_message_id":"94e0ce9269c4d96debe056d07e8ec750f5e58cd5","unresolved":false,"context_lines":[{"line_number":133,"context_line":"    @property"},{"line_number":134,"context_line":"    def _max_schema_name_length(self):"},{"line_number":135,"context_line":"        return 64"},{"line_number":136,"context_line":""},{"line_number":137,"context_line":"    def _is_valid_schema_name(self, value):"},{"line_number":138,"context_line":"        return True"},{"line_number":139,"context_line":""}],"source_content_type":"text/x-python","patch_set":5,"id":"5afe65bd_65e942e6","line":136,"updated":"2015-06-03 16:30:01.000000000","message":"wouldnt a better way be to assign this number to a variable and return that .","commit_id":"5f0900411a0f5bbfccd6c63bdbd78b6833455696"},{"author":{"_account_id":15321,"name":"Matthew Van Dijk","email":"mvandijk@tesora.com","username":"mvandijk"},"change_message_id":"0208aab0504b9a1d7fd9b95f5cadd12434e4b899","unresolved":false,"context_lines":[{"line_number":133,"context_line":"    @property"},{"line_number":134,"context_line":"    def _max_schema_name_length(self):"},{"line_number":135,"context_line":"        return 64"},{"line_number":136,"context_line":""},{"line_number":137,"context_line":"    def _is_valid_schema_name(self, value):"},{"line_number":138,"context_line":"        return True"},{"line_number":139,"context_line":""}],"source_content_type":"text/x-python","patch_set":5,"id":"5afe65bd_66602802","line":136,"in_reply_to":"5afe65bd_65e942e6","updated":"2015-06-03 16:47:07.000000000","message":"Why? This is a MongoDB specification.","commit_id":"5f0900411a0f5bbfccd6c63bdbd78b6833455696"},{"author":{"_account_id":14576,"name":"Petr Malik","email":"pmalik@tesora.com","username":"pmalik"},"change_message_id":"4ef8990999e23e79909dab05d40a3c82b820e9ce","unresolved":false,"context_lines":[{"line_number":133,"context_line":"    @property"},{"line_number":134,"context_line":"    def _max_schema_name_length(self):"},{"line_number":135,"context_line":"        return 64"},{"line_number":136,"context_line":""},{"line_number":137,"context_line":"    def _is_valid_schema_name(self, value):"},{"line_number":138,"context_line":"        return True"},{"line_number":139,"context_line":""}],"source_content_type":"text/x-python","patch_set":5,"id":"3afb71cf_045f960f","line":136,"in_reply_to":"5afe65bd_66602802","updated":"2015-06-04 19:01:11.000000000","message":"I agree with Matt, this is a property - it behaves like a variable already - no need to create a new one.","commit_id":"5f0900411a0f5bbfccd6c63bdbd78b6833455696"},{"author":{"_account_id":10295,"name":"mariam john","email":"mariamj@us.ibm.com","username":"mariamj"},"change_message_id":"94e0ce9269c4d96debe056d07e8ec750f5e58cd5","unresolved":false,"context_lines":[{"line_number":136,"context_line":""},{"line_number":137,"context_line":"    def _is_valid_schema_name(self, value):"},{"line_number":138,"context_line":"        return True"},{"line_number":139,"context_line":""},{"line_number":140,"context_line":"    @classmethod"},{"line_number":141,"context_line":"    def _dict_requirements(cls):"},{"line_number":142,"context_line":"        return [\u0027_name\u0027]"}],"source_content_type":"text/x-python","patch_set":5,"id":"5afe65bd_45cbe672","line":139,"updated":"2015-06-03 16:30:01.000000000","message":"why do we need this method if its always going to return true. Shouldnt there be some actual validation.","commit_id":"5f0900411a0f5bbfccd6c63bdbd78b6833455696"},{"author":{"_account_id":15321,"name":"Matthew Van Dijk","email":"mvandijk@tesora.com","username":"mvandijk"},"change_message_id":"0208aab0504b9a1d7fd9b95f5cadd12434e4b899","unresolved":false,"context_lines":[{"line_number":136,"context_line":""},{"line_number":137,"context_line":"    def _is_valid_schema_name(self, value):"},{"line_number":138,"context_line":"        return True"},{"line_number":139,"context_line":""},{"line_number":140,"context_line":"    @classmethod"},{"line_number":141,"context_line":"    def _dict_requirements(cls):"},{"line_number":142,"context_line":"        return [\u0027_name\u0027]"}],"source_content_type":"text/x-python","patch_set":5,"id":"5afe65bd_863fa4d5","line":139,"in_reply_to":"5afe65bd_45cbe672","updated":"2015-06-03 16:47:07.000000000","message":"This is just implementing the abstract method from the base class.","commit_id":"5f0900411a0f5bbfccd6c63bdbd78b6833455696"},{"author":{"_account_id":14576,"name":"Petr Malik","email":"pmalik@tesora.com","username":"pmalik"},"change_message_id":"4ef8990999e23e79909dab05d40a3c82b820e9ce","unresolved":false,"context_lines":[{"line_number":136,"context_line":""},{"line_number":137,"context_line":"    def _is_valid_schema_name(self, value):"},{"line_number":138,"context_line":"        return True"},{"line_number":139,"context_line":""},{"line_number":140,"context_line":"    @classmethod"},{"line_number":141,"context_line":"    def _dict_requirements(cls):"},{"line_number":142,"context_line":"        return [\u0027_name\u0027]"}],"source_content_type":"text/x-python","patch_set":5,"id":"3afb71cf_04b6763d","line":139,"in_reply_to":"5afe65bd_45cbe672","updated":"2015-06-04 19:01:11.000000000","message":"mariam: No, unless MongoDB has some restrictions on schema names.","commit_id":"5f0900411a0f5bbfccd6c63bdbd78b6833455696"},{"author":{"_account_id":14576,"name":"Petr Malik","email":"pmalik@tesora.com","username":"pmalik"},"change_message_id":"4ef8990999e23e79909dab05d40a3c82b820e9ce","unresolved":false,"context_lines":[{"line_number":459,"context_line":"            self._name \u003d value"},{"line_number":460,"context_line":""},{"line_number":461,"context_line":""},{"line_number":462,"context_line":"class DatastoreUser(Base):"},{"line_number":463,"context_line":"    \"\"\"Represents a datastore user.\"\"\""},{"line_number":464,"context_line":""},{"line_number":465,"context_line":"    _HOSTNAME_WILDCARD \u003d \u0027%\u0027"}],"source_content_type":"text/x-python","patch_set":5,"id":"3afb71cf_c4861e65","line":462,"updated":"2015-06-04 19:01:11.000000000","message":"See the comments in the Datastore class above.","commit_id":"5f0900411a0f5bbfccd6c63bdbd78b6833455696"},{"author":{"_account_id":10295,"name":"mariam john","email":"mariamj@us.ibm.com","username":"mariamj"},"change_message_id":"94e0ce9269c4d96debe056d07e8ec750f5e58cd5","unresolved":false,"context_lines":[{"line_number":597,"context_line":"        super(MongoDBUser, self).__init__()"},{"line_number":598,"context_line":"        if ((deserializing and (name or password)) or"},{"line_number":599,"context_line":"                (not (deserializing or (name and password)))):"},{"line_number":600,"context_line":"            raise ValueError(\"Bad args.\")"},{"line_number":601,"context_line":"        if deserializing:"},{"line_number":602,"context_line":"            pass"},{"line_number":603,"context_line":"        else:"}],"source_content_type":"text/x-python","patch_set":5,"id":"5afe65bd_c00904df","line":600,"updated":"2015-06-03 16:30:01.000000000","message":"needs translation","commit_id":"5f0900411a0f5bbfccd6c63bdbd78b6833455696"},{"author":{"_account_id":15321,"name":"Matthew Van Dijk","email":"mvandijk@tesora.com","username":"mvandijk"},"change_message_id":"0208aab0504b9a1d7fd9b95f5cadd12434e4b899","unresolved":false,"context_lines":[{"line_number":597,"context_line":"        super(MongoDBUser, self).__init__()"},{"line_number":598,"context_line":"        if ((deserializing and (name or password)) or"},{"line_number":599,"context_line":"                (not (deserializing or (name and password)))):"},{"line_number":600,"context_line":"            raise ValueError(\"Bad args.\")"},{"line_number":601,"context_line":"        if deserializing:"},{"line_number":602,"context_line":"            pass"},{"line_number":603,"context_line":"        else:"}],"source_content_type":"text/x-python","patch_set":5,"id":"5afe65bd_26311006","line":600,"in_reply_to":"5afe65bd_c00904df","updated":"2015-06-03 16:47:07.000000000","message":"ok","commit_id":"5f0900411a0f5bbfccd6c63bdbd78b6833455696"},{"author":{"_account_id":10295,"name":"mariam john","email":"mariamj@us.ibm.com","username":"mariamj"},"change_message_id":"94e0ce9269c4d96debe056d07e8ec750f5e58cd5","unresolved":false,"context_lines":[{"line_number":623,"context_line":"    @property"},{"line_number":624,"context_line":"    def _max_username_length(self):"},{"line_number":625,"context_line":"        return False"},{"line_number":626,"context_line":""},{"line_number":627,"context_line":"    def _is_valid_user_name(self, value):"},{"line_number":628,"context_line":"        return True"},{"line_number":629,"context_line":""}],"source_content_type":"text/x-python","patch_set":5,"id":"5afe65bd_c0c0e4e2","line":626,"updated":"2015-06-03 16:30:01.000000000","message":"shouldnt this return a number instead?","commit_id":"5f0900411a0f5bbfccd6c63bdbd78b6833455696"},{"author":{"_account_id":15321,"name":"Matthew Van Dijk","email":"mvandijk@tesora.com","username":"mvandijk"},"change_message_id":"0208aab0504b9a1d7fd9b95f5cadd12434e4b899","unresolved":false,"context_lines":[{"line_number":623,"context_line":"    @property"},{"line_number":624,"context_line":"    def _max_username_length(self):"},{"line_number":625,"context_line":"        return False"},{"line_number":626,"context_line":""},{"line_number":627,"context_line":"    def _is_valid_user_name(self, value):"},{"line_number":628,"context_line":"        return True"},{"line_number":629,"context_line":""}],"source_content_type":"text/x-python","patch_set":5,"id":"5afe65bd_0603b410","line":626,"in_reply_to":"5afe65bd_c0c0e4e2","updated":"2015-06-03 16:47:07.000000000","message":"No. See the implementation. Return a number if there is a limit on the name length. In MongoDB there is no limit.","commit_id":"5f0900411a0f5bbfccd6c63bdbd78b6833455696"},{"author":{"_account_id":10295,"name":"mariam john","email":"mariamj@us.ibm.com","username":"mariamj"},"change_message_id":"94e0ce9269c4d96debe056d07e8ec750f5e58cd5","unresolved":false,"context_lines":[{"line_number":625,"context_line":"        return False"},{"line_number":626,"context_line":""},{"line_number":627,"context_line":"    def _is_valid_user_name(self, value):"},{"line_number":628,"context_line":"        return True"},{"line_number":629,"context_line":""},{"line_number":630,"context_line":"    def _is_valid_host_name(self, value):"},{"line_number":631,"context_line":"        return True"}],"source_content_type":"text/x-python","patch_set":5,"id":"5afe65bd_a045e870","line":628,"updated":"2015-06-03 16:30:01.000000000","message":"why not call validate_user_name to actually validate the name?","commit_id":"5f0900411a0f5bbfccd6c63bdbd78b6833455696"},{"author":{"_account_id":15321,"name":"Matthew Van Dijk","email":"mvandijk@tesora.com","username":"mvandijk"},"change_message_id":"0208aab0504b9a1d7fd9b95f5cadd12434e4b899","unresolved":false,"context_lines":[{"line_number":625,"context_line":"        return False"},{"line_number":626,"context_line":""},{"line_number":627,"context_line":"    def _is_valid_user_name(self, value):"},{"line_number":628,"context_line":"        return True"},{"line_number":629,"context_line":""},{"line_number":630,"context_line":"    def _is_valid_host_name(self, value):"},{"line_number":631,"context_line":"        return True"}],"source_content_type":"text/x-python","patch_set":5,"id":"5afe65bd_1a3788e4","line":628,"in_reply_to":"5afe65bd_a045e870","updated":"2015-06-03 16:47:07.000000000","message":"This is the datastore-specific checker, and is called by _validate_user_name.","commit_id":"5f0900411a0f5bbfccd6c63bdbd78b6833455696"},{"author":{"_account_id":14576,"name":"Petr Malik","email":"pmalik@tesora.com","username":"pmalik"},"change_message_id":"faab78ce91154cc3ecb601c672ddf47744688e87","unresolved":false,"context_lines":[{"line_number":647,"context_line":""},{"line_number":648,"context_line":"    def _parse_name(self, value):"},{"line_number":649,"context_line":"        \"\"\"The name will be \u003cdatabase\u003e.\u003cusername\u003e, so split it.\"\"\""},{"line_number":650,"context_line":"        pattern \u003d re.compile(\u0027(.*?)\\.(.*)\u0027)"},{"line_number":651,"context_line":"        match \u003d pattern.match(value)"},{"line_number":652,"context_line":"        if not match:"},{"line_number":653,"context_line":"            raise ValueError(_(\u0027MongoDB user name \"%s\" not in\u0027"}],"source_content_type":"text/x-python","patch_set":7,"id":"3afb71cf_8629b139","line":650,"updated":"2015-06-09 16:05:19.000000000","message":"Do you really need the regex here. Wouldn\u0027t something like \u0027s.split(\u0027sep\u0027, 1)\u0027 be enough?","commit_id":"1aacf048f8eb2b3a40a0ecce195333cefaabf632"},{"author":{"_account_id":14576,"name":"Petr Malik","email":"pmalik@tesora.com","username":"pmalik"},"change_message_id":"faab78ce91154cc3ecb601c672ddf47744688e87","unresolved":false,"context_lines":[{"line_number":657,"context_line":""},{"line_number":658,"context_line":"    @property"},{"line_number":659,"context_line":"    def _max_username_length(self):"},{"line_number":660,"context_line":"        return False"},{"line_number":661,"context_line":""},{"line_number":662,"context_line":"    def _is_valid_name(self, value):"},{"line_number":663,"context_line":"        return True"}],"source_content_type":"text/x-python","patch_set":7,"id":"3afb71cf_4325ebbe","line":660,"updated":"2015-06-09 16:05:19.000000000","message":"I think this should be None if there is no limit - see the comment on the abstract interface.","commit_id":"1aacf048f8eb2b3a40a0ecce195333cefaabf632"},{"author":{"_account_id":14576,"name":"Petr Malik","email":"pmalik@tesora.com","username":"pmalik"},"change_message_id":"faab78ce91154cc3ecb601c672ddf47744688e87","unresolved":false,"context_lines":[{"line_number":659,"context_line":"    def _max_username_length(self):"},{"line_number":660,"context_line":"        return False"},{"line_number":661,"context_line":""},{"line_number":662,"context_line":"    def _is_valid_name(self, value):"},{"line_number":663,"context_line":"        return True"},{"line_number":664,"context_line":""},{"line_number":665,"context_line":"    def _is_valid_host_name(self, value):"}],"source_content_type":"text/x-python","patch_set":7,"id":"3afb71cf_268f9d76","line":662,"updated":"2015-06-09 16:05:19.000000000","message":"So, Mongo has no restrictions on the pattern of the user names?","commit_id":"1aacf048f8eb2b3a40a0ecce195333cefaabf632"},{"author":{"_account_id":10295,"name":"mariam john","email":"mariamj@us.ibm.com","username":"mariamj"},"change_message_id":"01de8bc2c006f1109eed1ef4e16f02ffdb3b894e","unresolved":false,"context_lines":[{"line_number":592,"context_line":""},{"line_number":593,"context_line":"class MongoDBUser(DatastoreUser):"},{"line_number":594,"context_line":"    \"\"\"Represents a MongoDB user and its associated properties."},{"line_number":595,"context_line":"    MongoDB users are identified using their namd and database."},{"line_number":596,"context_line":"    Trove stores this as \u003cdatabase\u003e.\u003cusername\u003e"},{"line_number":597,"context_line":"    \"\"\""},{"line_number":598,"context_line":""}],"source_content_type":"text/x-python","patch_set":14,"id":"fa32b979_db4efd95","line":595,"updated":"2015-06-22 00:25:46.000000000","message":"a small typo here : name. Is this representation of MongoDB user (\u003cdatabase\u003e.\u003cusername\u003e) specific to Trove?","commit_id":"59facd61b6a657abc110ed0fab08ba3823a383d1"},{"author":{"_account_id":15321,"name":"Matthew Van Dijk","email":"mvandijk@tesora.com","username":"mvandijk"},"change_message_id":"cbcec005c49e4d5aa8bd4b20da630f0a005c866d","unresolved":false,"context_lines":[{"line_number":592,"context_line":""},{"line_number":593,"context_line":"class MongoDBUser(DatastoreUser):"},{"line_number":594,"context_line":"    \"\"\"Represents a MongoDB user and its associated properties."},{"line_number":595,"context_line":"    MongoDB users are identified using their namd and database."},{"line_number":596,"context_line":"    Trove stores this as \u003cdatabase\u003e.\u003cusername\u003e"},{"line_number":597,"context_line":"    \"\"\""},{"line_number":598,"context_line":""}],"source_content_type":"text/x-python","patch_set":14,"id":"fa32b979_66bdbbd6","line":595,"in_reply_to":"fa32b979_db4efd95","updated":"2015-06-22 17:44:04.000000000","message":"Done.\n\nThis is mongo\u0027s internal user id. A user is created with a username against a specific database. In a system collection this has the unique id of this form. This does not translate into the Trove model, so this is the closest representation I could come up with.","commit_id":"59facd61b6a657abc110ed0fab08ba3823a383d1"},{"author":{"_account_id":10295,"name":"mariam john","email":"mariamj@us.ibm.com","username":"mariamj"},"change_message_id":"01de8bc2c006f1109eed1ef4e16f02ffdb3b894e","unresolved":false,"context_lines":[{"line_number":625,"context_line":"        else:"},{"line_number":626,"context_line":"            missing \u003d \u0027username\u0027 if self.database else \u0027database\u0027"},{"line_number":627,"context_line":"            raise ValueError(_(\u0027MongoDB user name missing %s.\u0027) % missing)"},{"line_number":628,"context_line":""},{"line_number":629,"context_line":"    @name.setter"},{"line_number":630,"context_line":"    def name(self, value):"},{"line_number":631,"context_line":"        self.database, self.username \u003d self._parse_name(value)"}],"source_content_type":"text/x-python","patch_set":14,"id":"fa32b979_bb49b990","line":628,"updated":"2015-06-22 00:25:46.000000000","message":"if the username is missing, wouldnt the message read: \u0027MongoDB user name missing username.\u0027. Doesnt it make more sense to say something like: \n\u0027MongoDB user is missing username (MongoDB users are identified in Trove as \u003cdatabase\u003e.\u003cusername\u003e).\u0027","commit_id":"59facd61b6a657abc110ed0fab08ba3823a383d1"},{"author":{"_account_id":15321,"name":"Matthew Van Dijk","email":"mvandijk@tesora.com","username":"mvandijk"},"change_message_id":"cbcec005c49e4d5aa8bd4b20da630f0a005c866d","unresolved":false,"context_lines":[{"line_number":625,"context_line":"        else:"},{"line_number":626,"context_line":"            missing \u003d \u0027username\u0027 if self.database else \u0027database\u0027"},{"line_number":627,"context_line":"            raise ValueError(_(\u0027MongoDB user name missing %s.\u0027) % missing)"},{"line_number":628,"context_line":""},{"line_number":629,"context_line":"    @name.setter"},{"line_number":630,"context_line":"    def name(self, value):"},{"line_number":631,"context_line":"        self.database, self.username \u003d self._parse_name(value)"}],"source_content_type":"text/x-python","patch_set":14,"id":"fa32b979_4682f753","line":628,"in_reply_to":"fa32b979_bb49b990","updated":"2015-06-22 17:44:04.000000000","message":"The assignment in the line above will make the message say either:\n\nMongoDB user name missing username.\n\nor\n\nMongoDB user name missing database.\n\nI will tweak the message to be:\n\nMongoDB user\u0027s input name missing %s.","commit_id":"59facd61b6a657abc110ed0fab08ba3823a383d1"},{"author":{"_account_id":10295,"name":"mariam john","email":"mariamj@us.ibm.com","username":"mariamj"},"change_message_id":"09e3efe5f469c22601d73914c413fd582a40835e","unresolved":false,"context_lines":[{"line_number":654,"context_line":"                               \u0027\u003cdatabase\u003e.\u003cusername\u003e format.\u0027) % value)"},{"line_number":655,"context_line":"        (database, username) \u003d (match.group(1), match.group(2))"},{"line_number":656,"context_line":"        return (database, username)"},{"line_number":657,"context_line":""},{"line_number":658,"context_line":"    @property"},{"line_number":659,"context_line":"    def _max_username_length(self):"},{"line_number":660,"context_line":"        return False"}],"source_content_type":"text/x-python","patch_set":14,"id":"fa32b979_336dcd32","line":657,"updated":"2015-06-22 06:12:46.000000000","message":"I see that in this patch https://review.openstack.org/#/c/189989/5/trove/guestagent/db/models.py, this is defined as a static method which is right.","commit_id":"59facd61b6a657abc110ed0fab08ba3823a383d1"},{"author":{"_account_id":15321,"name":"Matthew Van Dijk","email":"mvandijk@tesora.com","username":"mvandijk"},"change_message_id":"cbcec005c49e4d5aa8bd4b20da630f0a005c866d","unresolved":false,"context_lines":[{"line_number":654,"context_line":"                               \u0027\u003cdatabase\u003e.\u003cusername\u003e format.\u0027) % value)"},{"line_number":655,"context_line":"        (database, username) \u003d (match.group(1), match.group(2))"},{"line_number":656,"context_line":"        return (database, username)"},{"line_number":657,"context_line":""},{"line_number":658,"context_line":"    @property"},{"line_number":659,"context_line":"    def _max_username_length(self):"},{"line_number":660,"context_line":"        return False"}],"source_content_type":"text/x-python","patch_set":14,"id":"fa32b979_e6d8eb81","line":657,"in_reply_to":"fa32b979_336dcd32","updated":"2015-06-22 17:44:04.000000000","message":"I will move those changes to this base branch.","commit_id":"59facd61b6a657abc110ed0fab08ba3823a383d1"},{"author":{"_account_id":6413,"name":"Victoria Martinez de la Cruz","email":"victoria@redhat.com","username":"vkmc"},"change_message_id":"640fb10e936935547e2da0ee999b98f706afaac9","unresolved":false,"context_lines":[{"line_number":65,"context_line":"                                 \u0027reqs\u0027: cls._dict_requirements()}))"},{"line_number":66,"context_line":""},{"line_number":67,"context_line":"        schema \u003d cls(deserializing\u003dTrue)"},{"line_number":68,"context_line":"        schema.deserialize(value)"},{"line_number":69,"context_line":"        return schema"},{"line_number":70,"context_line":""},{"line_number":71,"context_line":"    @property"}],"source_content_type":"text/x-python","patch_set":18,"id":"fa32b979_08d3eb60","line":68,"updated":"2015-06-25 19:17:13.000000000","message":"NIT. return directly","commit_id":"5d05ebc04954bf98c6a487948cf565ab334792df"},{"author":{"_account_id":15321,"name":"Matthew Van Dijk","email":"mvandijk@tesora.com","username":"mvandijk"},"change_message_id":"f4aea28d8f5054761e4203a039189763c1c47f96","unresolved":false,"context_lines":[{"line_number":65,"context_line":"                                 \u0027reqs\u0027: cls._dict_requirements()}))"},{"line_number":66,"context_line":""},{"line_number":67,"context_line":"        schema \u003d cls(deserializing\u003dTrue)"},{"line_number":68,"context_line":"        schema.deserialize(value)"},{"line_number":69,"context_line":"        return schema"},{"line_number":70,"context_line":""},{"line_number":71,"context_line":"    @property"}],"source_content_type":"text/x-python","patch_set":18,"id":"fa32b979_d22a622f","line":68,"in_reply_to":"fa32b979_08d3eb60","updated":"2015-06-26 17:39:06.000000000","message":"No this method does not return the object we want.\nWe set schema, run its method, then return the object.","commit_id":"5d05ebc04954bf98c6a487948cf565ab334792df"}],"trove/tests/unittests/guestagent/test_mongodb_cluster_manager.py":[{"author":{"_account_id":7806,"name":"Sushil Kumar","email":"skm.net@gmail.com","username":"sushilkm"},"change_message_id":"0cd28f80822ec2c683dc291ba78802a7096a7bce","unresolved":false,"context_lines":[{"line_number":111,"context_line":""},{"line_number":112,"context_line":"        self._prepare_method(\"test-id-1\", \"query_router\", None)"},{"line_number":113,"context_line":"        mock_update.assert_called_with(None, {\u0027bind_ip\u0027: \u002710.0.0.2\u0027,"},{"line_number":114,"context_line":"                                              #\u0027keyFile\u0027: \u0027/test/key/file\u0027})"},{"line_number":115,"context_line":"                                              })"},{"line_number":116,"context_line":"        self.assertTrue(self.manager.app.status.is_query_router)"},{"line_number":117,"context_line":"        mock_set_status.assert_called_with("}],"source_content_type":"text/x-python","patch_set":2,"id":"5afe65bd_2ae9ee80","line":114,"updated":"2015-06-03 06:56:53.000000000","message":"if it is commented why do we need this in tests","commit_id":"f0c7095d302f6edd6f380e6df562832aa0157ccf"},{"author":{"_account_id":15321,"name":"Matthew Van Dijk","email":"mvandijk@tesora.com","username":"mvandijk"},"change_message_id":"04424e69191dd729c1b12bd50f75ccf8938a5381","unresolved":false,"context_lines":[{"line_number":111,"context_line":""},{"line_number":112,"context_line":"        self._prepare_method(\"test-id-1\", \"query_router\", None)"},{"line_number":113,"context_line":"        mock_update.assert_called_with(None, {\u0027bind_ip\u0027: \u002710.0.0.2\u0027,"},{"line_number":114,"context_line":"                                              #\u0027keyFile\u0027: \u0027/test/key/file\u0027})"},{"line_number":115,"context_line":"                                              })"},{"line_number":116,"context_line":"        self.assertTrue(self.manager.app.status.is_query_router)"},{"line_number":117,"context_line":"        mock_set_status.assert_called_with("}],"source_content_type":"text/x-python","patch_set":2,"id":"5afe65bd_182c3e01","line":114,"in_reply_to":"5afe65bd_2ae9ee80","updated":"2015-06-03 13:20:26.000000000","message":"The commit that will turn on \u0027auth\u0027 will uncomment these.","commit_id":"f0c7095d302f6edd6f380e6df562832aa0157ccf"},{"author":{"_account_id":7806,"name":"Sushil Kumar","email":"skm.net@gmail.com","username":"sushilkm"},"change_message_id":"0cd28f80822ec2c683dc291ba78802a7096a7bce","unresolved":false,"context_lines":[{"line_number":130,"context_line":"        self._prepare_method(\"test-id-2\", \"config_server\", None)"},{"line_number":131,"context_line":"        mock_update.assert_called_with(None, {\u0027configsvr\u0027: \u0027true\u0027,"},{"line_number":132,"context_line":"                                              \u0027bind_ip\u0027: \u002710.0.0.3\u0027,"},{"line_number":133,"context_line":"                                              #\u0027keyFile\u0027: \u0027/test/key/file\u0027,"},{"line_number":134,"context_line":"                                              \u0027dbpath\u0027: \u0027/var/lib/mongodb\u0027})"},{"line_number":135,"context_line":"        self.assertTrue(self.manager.app.status.is_config_server)"},{"line_number":136,"context_line":"        mock_set_status.assert_called_with("}],"source_content_type":"text/x-python","patch_set":2,"id":"5afe65bd_4af2ea70","line":133,"updated":"2015-06-03 06:56:53.000000000","message":"if it is commented why do we need this in tests","commit_id":"f0c7095d302f6edd6f380e6df562832aa0157ccf"},{"author":{"_account_id":15321,"name":"Matthew Van Dijk","email":"mvandijk@tesora.com","username":"mvandijk"},"change_message_id":"04424e69191dd729c1b12bd50f75ccf8938a5381","unresolved":false,"context_lines":[{"line_number":130,"context_line":"        self._prepare_method(\"test-id-2\", \"config_server\", None)"},{"line_number":131,"context_line":"        mock_update.assert_called_with(None, {\u0027configsvr\u0027: \u0027true\u0027,"},{"line_number":132,"context_line":"                                              \u0027bind_ip\u0027: \u002710.0.0.3\u0027,"},{"line_number":133,"context_line":"                                              #\u0027keyFile\u0027: \u0027/test/key/file\u0027,"},{"line_number":134,"context_line":"                                              \u0027dbpath\u0027: \u0027/var/lib/mongodb\u0027})"},{"line_number":135,"context_line":"        self.assertTrue(self.manager.app.status.is_config_server)"},{"line_number":136,"context_line":"        mock_set_status.assert_called_with("}],"source_content_type":"text/x-python","patch_set":2,"id":"5afe65bd_b8388a3e","line":133,"in_reply_to":"5afe65bd_4af2ea70","updated":"2015-06-03 13:20:26.000000000","message":"^","commit_id":"f0c7095d302f6edd6f380e6df562832aa0157ccf"}],"trove/tests/unittests/guestagent/test_mongodb_manager.py":[{"author":{"_account_id":7806,"name":"Sushil Kumar","email":"skm.net@gmail.com","username":"sushilkm"},"change_message_id":"0cd28f80822ec2c683dc291ba78802a7096a7bce","unresolved":false,"context_lines":[{"line_number":90,"context_line":"        mocked_volume().mount.assert_called_with(self.mount_point)"},{"line_number":91,"context_line":""},{"line_number":92,"context_line":"    def test_secure(self):"},{"line_number":93,"context_line":"        self.manager.app \u003d mock.Mock()"},{"line_number":94,"context_line":""},{"line_number":95,"context_line":"        mock_secure \u003d mock.Mock()"},{"line_number":96,"context_line":"        self.manager.app.secure \u003d mock_secure"}],"source_content_type":"text/x-python","patch_set":2,"id":"5afe65bd_eab19690","line":93,"updated":"2015-06-03 06:56:53.000000000","message":"insecure mocking","commit_id":"f0c7095d302f6edd6f380e6df562832aa0157ccf"},{"author":{"_account_id":15321,"name":"Matthew Van Dijk","email":"mvandijk@tesora.com","username":"mvandijk"},"change_message_id":"04424e69191dd729c1b12bd50f75ccf8938a5381","unresolved":false,"context_lines":[{"line_number":90,"context_line":"        mocked_volume().mount.assert_called_with(self.mount_point)"},{"line_number":91,"context_line":""},{"line_number":92,"context_line":"    def test_secure(self):"},{"line_number":93,"context_line":"        self.manager.app \u003d mock.Mock()"},{"line_number":94,"context_line":""},{"line_number":95,"context_line":"        mock_secure \u003d mock.Mock()"},{"line_number":96,"context_line":"        self.manager.app.secure \u003d mock_secure"}],"source_content_type":"text/x-python","patch_set":2,"id":"5afe65bd_d88346cb","line":93,"in_reply_to":"5afe65bd_eab19690","updated":"2015-06-03 13:20:26.000000000","message":"No it is mocking in the local namespace.","commit_id":"f0c7095d302f6edd6f380e6df562832aa0157ccf"},{"author":{"_account_id":7806,"name":"Sushil Kumar","email":"skm.net@gmail.com","username":"sushilkm"},"change_message_id":"dcb3d6e7a929b434a12ad9c99d3ca1ccf77c7132","unresolved":false,"context_lines":[{"line_number":58,"context_line":"        \"\"\"self.manager.app must be correctly mocked before calling.\"\"\""},{"line_number":59,"context_line":""},{"line_number":60,"context_line":"        self.manager.status \u003d mock.Mock()"},{"line_number":61,"context_line":"        self.manager.get_config_changes \u003d mock.Mock()"},{"line_number":62,"context_line":""},{"line_number":63,"context_line":"        self.manager.prepare(self.context, packages,"},{"line_number":64,"context_line":"                             databases, memory_mb, users,"}],"source_content_type":"text/x-python","patch_set":5,"id":"5afe65bd_9af2586e","line":61,"updated":"2015-06-03 17:21:18.000000000","message":"This is an unsafe mocking, this would mock the method get_config_changes forever.","commit_id":"5f0900411a0f5bbfccd6c63bdbd78b6833455696"},{"author":{"_account_id":15321,"name":"Matthew Van Dijk","email":"mvandijk@tesora.com","username":"mvandijk"},"change_message_id":"d4ef0c3df4c68785811e04c2b7bc99801d90b968","unresolved":false,"context_lines":[{"line_number":58,"context_line":"        \"\"\"self.manager.app must be correctly mocked before calling.\"\"\""},{"line_number":59,"context_line":""},{"line_number":60,"context_line":"        self.manager.status \u003d mock.Mock()"},{"line_number":61,"context_line":"        self.manager.get_config_changes \u003d mock.Mock()"},{"line_number":62,"context_line":""},{"line_number":63,"context_line":"        self.manager.prepare(self.context, packages,"},{"line_number":64,"context_line":"                             databases, memory_mb, users,"}],"source_content_type":"text/x-python","patch_set":5,"id":"5afe65bd_b0009502","line":61,"in_reply_to":"5afe65bd_9af2586e","updated":"2015-06-03 17:29:54.000000000","message":"No it is mocking this instance\u0027s function, it is local only.","commit_id":"5f0900411a0f5bbfccd6c63bdbd78b6833455696"}]}
