)]}'
{"docs/monasca-api-spec.md":[{"author":{"_account_id":16168,"name":"Tomasz Trębski","email":"kornicameister@gmail.com","username":"trebskit"},"change_message_id":"2373471882577f17826d98cd12891431374a5dd0","unresolved":false,"context_lines":[{"line_number":996,"context_line":"* __Alarm database__ (MariaDB/MySQL, PostgreSQL) is consider healthy if connection to database can be established"},{"line_number":997,"context_line":"  and sample query can be executed."},{"line_number":998,"context_line":"* __Metrics database__ (InfluxDB, Cassandra) is consider healthy if: `InfluxDB` is set health check is verified according to the"},{"line_number":999,"context_line":"InfluxDB documentation (/ping), `Cassandra` is set health check is verified through new connection to the database."},{"line_number":1000,"context_line":""},{"line_number":1001,"context_line":"## Simple check"},{"line_number":1002,"context_line":"The simple check only returns response only if Monasca APi is up and running. It does not return any data"}],"source_content_type":"text/x-markdown","patch_set":11,"id":"ff0f0b1f_076cdc05","line":999,"updated":"2017-05-24 05:22:13.000000000","message":"Actual link would be great.","commit_id":"15173e6b99c6a3627c43edd3d62caf80033918a6"},{"author":{"_account_id":20033,"name":"Artur Basiak","email":"artur.basiak@ts.fujitsu.com","username":"abasiak"},"change_message_id":"a03e5e7e057d8734eed2ccf249ce3b2099f855ce","unresolved":false,"context_lines":[{"line_number":996,"context_line":"* __Alarm database__ (MariaDB/MySQL, PostgreSQL) is consider healthy if connection to database can be established"},{"line_number":997,"context_line":"  and sample query can be executed."},{"line_number":998,"context_line":"* __Metrics database__ (InfluxDB, Cassandra) is consider healthy if: `InfluxDB` is set health check is verified according to the"},{"line_number":999,"context_line":"InfluxDB documentation (/ping), `Cassandra` is set health check is verified through new connection to the database."},{"line_number":1000,"context_line":""},{"line_number":1001,"context_line":"## Simple check"},{"line_number":1002,"context_line":"The simple check only returns response only if Monasca APi is up and running. It does not return any data"}],"source_content_type":"text/x-markdown","patch_set":11,"id":"ff0f0b1f_a323daa6","line":999,"in_reply_to":"ff0f0b1f_076cdc05","updated":"2017-05-24 11:07:54.000000000","message":"Done","commit_id":"15173e6b99c6a3627c43edd3d62caf80033918a6"},{"author":{"_account_id":2419,"name":"Roland Hochmuth","email":"roland.hochmuth@hpe.com","username":"roland-hochmuth-s"},"change_message_id":"92908030bd7b4b96a65bbdb4d68567a56bc3eca3","unresolved":false,"context_lines":[{"line_number":981,"context_line":"under `/healthcheck` endopoint."},{"line_number":982,"context_line":""},{"line_number":983,"context_line":"## Complex check"},{"line_number":984,"context_line":"The complex check not only returns a response with success code if Monasca APi is up and running by it also verifies if"},{"line_number":985,"context_line":"dependant components , such as __Kafka__, __Alarm database__ (MariadDB/MySQL, PostgreSQL), __Metrics database__ (Cassandra, InfluxdDB)"},{"line_number":986,"context_line":"are healthy too."},{"line_number":987,"context_line":""}],"source_content_type":"text/x-markdown","patch_set":13,"id":"ff0f0b1f_2cfc4eb3","line":984,"updated":"2017-05-24 19:43:39.000000000","message":"nit: APi -\u003e API","commit_id":"3f6a8ca11367ea9f4ca4dc5d7f5bb531f6e627ba"},{"author":{"_account_id":20033,"name":"Artur Basiak","email":"artur.basiak@ts.fujitsu.com","username":"abasiak"},"change_message_id":"124944b9ad4f2cb9a729753b2f319ec6ee84dd2b","unresolved":false,"context_lines":[{"line_number":981,"context_line":"under `/healthcheck` endopoint."},{"line_number":982,"context_line":""},{"line_number":983,"context_line":"## Complex check"},{"line_number":984,"context_line":"The complex check not only returns a response with success code if Monasca APi is up and running by it also verifies if"},{"line_number":985,"context_line":"dependant components , such as __Kafka__, __Alarm database__ (MariadDB/MySQL, PostgreSQL), __Metrics database__ (Cassandra, InfluxdDB)"},{"line_number":986,"context_line":"are healthy too."},{"line_number":987,"context_line":""}],"source_content_type":"text/x-markdown","patch_set":13,"id":"ff0f0b1f_ffc82955","line":984,"in_reply_to":"ff0f0b1f_2cfc4eb3","updated":"2017-05-25 06:46:04.000000000","message":"Done","commit_id":"3f6a8ca11367ea9f4ca4dc5d7f5bb531f6e627ba"},{"author":{"_account_id":2419,"name":"Roland Hochmuth","email":"roland.hochmuth@hpe.com","username":"roland-hochmuth-s"},"change_message_id":"92908030bd7b4b96a65bbdb4d68567a56bc3eca3","unresolved":false,"context_lines":[{"line_number":992,"context_line":"Example: `curl -XGET 192.168.10.6:8070/healthcheck`"},{"line_number":993,"context_line":""},{"line_number":994,"context_line":"### Peripheral checks"},{"line_number":995,"context_line":"* __Kafka__ is consider healthy if connection to broker can be established and configured topics can be found."},{"line_number":996,"context_line":"* __Alarm database__ (MariaDB/MySQL, PostgreSQL) is consider healthy if connection to database can be established"},{"line_number":997,"context_line":"  and sample query can be executed."},{"line_number":998,"context_line":"* __Metrics database__ (InfluxDB, Cassandra) is consider healthy if: `InfluxDB` is set health check is verified according to the"}],"source_content_type":"text/x-markdown","patch_set":13,"id":"ff0f0b1f_ec8f7627","line":995,"range":{"start_line":995,"start_character":15,"end_line":995,"end_character":23},"updated":"2017-05-24 19:43:39.000000000","message":"consider -\u003e considered healthy if a connection to the broker can be established and the configured topics","commit_id":"3f6a8ca11367ea9f4ca4dc5d7f5bb531f6e627ba"},{"author":{"_account_id":20033,"name":"Artur Basiak","email":"artur.basiak@ts.fujitsu.com","username":"abasiak"},"change_message_id":"124944b9ad4f2cb9a729753b2f319ec6ee84dd2b","unresolved":false,"context_lines":[{"line_number":992,"context_line":"Example: `curl -XGET 192.168.10.6:8070/healthcheck`"},{"line_number":993,"context_line":""},{"line_number":994,"context_line":"### Peripheral checks"},{"line_number":995,"context_line":"* __Kafka__ is consider healthy if connection to broker can be established and configured topics can be found."},{"line_number":996,"context_line":"* __Alarm database__ (MariaDB/MySQL, PostgreSQL) is consider healthy if connection to database can be established"},{"line_number":997,"context_line":"  and sample query can be executed."},{"line_number":998,"context_line":"* __Metrics database__ (InfluxDB, Cassandra) is consider healthy if: `InfluxDB` is set health check is verified according to the"}],"source_content_type":"text/x-markdown","patch_set":13,"id":"ff0f0b1f_fc703774","line":995,"range":{"start_line":995,"start_character":15,"end_line":995,"end_character":23},"in_reply_to":"ff0f0b1f_ec8f7627","updated":"2017-05-25 06:46:04.000000000","message":"Done","commit_id":"3f6a8ca11367ea9f4ca4dc5d7f5bb531f6e627ba"},{"author":{"_account_id":2419,"name":"Roland Hochmuth","email":"roland.hochmuth@hpe.com","username":"roland-hochmuth-s"},"change_message_id":"92908030bd7b4b96a65bbdb4d68567a56bc3eca3","unresolved":false,"context_lines":[{"line_number":995,"context_line":"* __Kafka__ is consider healthy if connection to broker can be established and configured topics can be found."},{"line_number":996,"context_line":"* __Alarm database__ (MariaDB/MySQL, PostgreSQL) is consider healthy if connection to database can be established"},{"line_number":997,"context_line":"  and sample query can be executed."},{"line_number":998,"context_line":"* __Metrics database__ (InfluxDB, Cassandra) is consider healthy if: `InfluxDB` is set health check is verified according to the"},{"line_number":999,"context_line":"InfluxDB documentation ([/ping](https://docs.influxdata.com/influxdb/v1.1/tools/api/)), `Cassandra` is set health check is verified through new connection to the database."},{"line_number":1000,"context_line":""},{"line_number":1001,"context_line":"## Simple check"}],"source_content_type":"text/x-markdown","patch_set":13,"id":"ff0f0b1f_ac9a9e5e","line":998,"updated":"2017-05-24 19:43:39.000000000","message":"Probably should remove Cassandra, if not both InfluxDB and Cassandra. It is enough to say the Metrics Database.\n\nBTW, you could also change Metrics database to be Time Series Database (TSDB).","commit_id":"3f6a8ca11367ea9f4ca4dc5d7f5bb531f6e627ba"},{"author":{"_account_id":20033,"name":"Artur Basiak","email":"artur.basiak@ts.fujitsu.com","username":"abasiak"},"change_message_id":"124944b9ad4f2cb9a729753b2f319ec6ee84dd2b","unresolved":false,"context_lines":[{"line_number":995,"context_line":"* __Kafka__ is consider healthy if connection to broker can be established and configured topics can be found."},{"line_number":996,"context_line":"* __Alarm database__ (MariaDB/MySQL, PostgreSQL) is consider healthy if connection to database can be established"},{"line_number":997,"context_line":"  and sample query can be executed."},{"line_number":998,"context_line":"* __Metrics database__ (InfluxDB, Cassandra) is consider healthy if: `InfluxDB` is set health check is verified according to the"},{"line_number":999,"context_line":"InfluxDB documentation ([/ping](https://docs.influxdata.com/influxdb/v1.1/tools/api/)), `Cassandra` is set health check is verified through new connection to the database."},{"line_number":1000,"context_line":""},{"line_number":1001,"context_line":"## Simple check"}],"source_content_type":"text/x-markdown","patch_set":13,"id":"ff0f0b1f_7c3307ac","line":998,"in_reply_to":"ff0f0b1f_ac9a9e5e","updated":"2017-05-25 06:46:04.000000000","message":"Done","commit_id":"3f6a8ca11367ea9f4ca4dc5d7f5bb531f6e627ba"},{"author":{"_account_id":2419,"name":"Roland Hochmuth","email":"roland.hochmuth@hpe.com","username":"roland-hochmuth-s"},"change_message_id":"92908030bd7b4b96a65bbdb4d68567a56bc3eca3","unresolved":false,"context_lines":[{"line_number":999,"context_line":"InfluxDB documentation ([/ping](https://docs.influxdata.com/influxdb/v1.1/tools/api/)), `Cassandra` is set health check is verified through new connection to the database."},{"line_number":1000,"context_line":""},{"line_number":1001,"context_line":"## Simple check"},{"line_number":1002,"context_line":"The simple check only returns response only if Monasca APi is up and running. It does not return any data"},{"line_number":1003,"context_line":"because it is accessible only for `HEAD` request. If the Monasca Api is up and running the following response code:"},{"line_number":1004,"context_line":"`204` is expected."},{"line_number":1005,"context_line":""}],"source_content_type":"text/x-markdown","patch_set":13,"id":"ff0f0b1f_4cab0274","line":1002,"updated":"2017-05-24 19:43:39.000000000","message":"nit: APi -\u003e API","commit_id":"3f6a8ca11367ea9f4ca4dc5d7f5bb531f6e627ba"},{"author":{"_account_id":20033,"name":"Artur Basiak","email":"artur.basiak@ts.fujitsu.com","username":"abasiak"},"change_message_id":"124944b9ad4f2cb9a729753b2f319ec6ee84dd2b","unresolved":false,"context_lines":[{"line_number":999,"context_line":"InfluxDB documentation ([/ping](https://docs.influxdata.com/influxdb/v1.1/tools/api/)), `Cassandra` is set health check is verified through new connection to the database."},{"line_number":1000,"context_line":""},{"line_number":1001,"context_line":"## Simple check"},{"line_number":1002,"context_line":"The simple check only returns response only if Monasca APi is up and running. It does not return any data"},{"line_number":1003,"context_line":"because it is accessible only for `HEAD` request. If the Monasca Api is up and running the following response code:"},{"line_number":1004,"context_line":"`204` is expected."},{"line_number":1005,"context_line":""}],"source_content_type":"text/x-markdown","patch_set":13,"id":"ff0f0b1f_5c26036a","line":1002,"in_reply_to":"ff0f0b1f_4cab0274","updated":"2017-05-25 06:46:04.000000000","message":"Done","commit_id":"3f6a8ca11367ea9f4ca4dc5d7f5bb531f6e627ba"}],"monasca_api/api/healthcheck_api.py":[{"author":{"_account_id":16168,"name":"Tomasz Trębski","email":"kornicameister@gmail.com","username":"trebskit"},"change_message_id":"bbc169257cfb829a204831037f921935afa5e418","unresolved":false,"context_lines":[{"line_number":19,"context_line":""},{"line_number":20,"context_line":""},{"line_number":21,"context_line":"class HealthCheckApi(object):"},{"line_number":22,"context_line":"    \"\"\"HealthCheck Api"},{"line_number":23,"context_line":"    HealthCheckApi server information regarding health of the Api"},{"line_number":24,"context_line":"    \"\"\""},{"line_number":25,"context_line":""}],"source_content_type":"text/x-python","patch_set":3,"id":"ff0f0b1f_21361454","line":22,"updated":"2017-05-22 04:15:00.000000000","message":"There should be an empty line between doc header and doc body","commit_id":"e555806667958c7b241aef821565528e59df0938"},{"author":{"_account_id":20033,"name":"Artur Basiak","email":"artur.basiak@ts.fujitsu.com","username":"abasiak"},"change_message_id":"b83a01f4a7332c1b8148e5f9e56b91b4dd514a3e","unresolved":false,"context_lines":[{"line_number":19,"context_line":""},{"line_number":20,"context_line":""},{"line_number":21,"context_line":"class HealthCheckApi(object):"},{"line_number":22,"context_line":"    \"\"\"HealthCheck Api"},{"line_number":23,"context_line":"    HealthCheckApi server information regarding health of the Api"},{"line_number":24,"context_line":"    \"\"\""},{"line_number":25,"context_line":""}],"source_content_type":"text/x-python","patch_set":3,"id":"ff0f0b1f_76683b20","line":22,"in_reply_to":"ff0f0b1f_21361454","updated":"2017-05-22 06:46:51.000000000","message":"Done","commit_id":"e555806667958c7b241aef821565528e59df0938"},{"author":{"_account_id":16168,"name":"Tomasz Trębski","email":"kornicameister@gmail.com","username":"trebskit"},"change_message_id":"bbc169257cfb829a204831037f921935afa5e418","unresolved":false,"context_lines":[{"line_number":36,"context_line":"        :param falcon.Request req: current request"},{"line_number":37,"context_line":"        :param falcon.Response res: current response"},{"line_number":38,"context_line":"        \"\"\""},{"line_number":39,"context_line":"        res.status \u003d falcon.HTTP_501"},{"line_number":40,"context_line":""},{"line_number":41,"context_line":"    def on_head(self, req, res):"},{"line_number":42,"context_line":"        \"\"\"Simple healthcheck report on HEAD."}],"source_content_type":"text/x-python","patch_set":3,"id":"ff0f0b1f_010ada88","line":39,"updated":"2017-05-22 04:15:00.000000000","message":"# pragma: no cover","commit_id":"e555806667958c7b241aef821565528e59df0938"},{"author":{"_account_id":20033,"name":"Artur Basiak","email":"artur.basiak@ts.fujitsu.com","username":"abasiak"},"change_message_id":"b83a01f4a7332c1b8148e5f9e56b91b4dd514a3e","unresolved":false,"context_lines":[{"line_number":36,"context_line":"        :param falcon.Request req: current request"},{"line_number":37,"context_line":"        :param falcon.Response res: current response"},{"line_number":38,"context_line":"        \"\"\""},{"line_number":39,"context_line":"        res.status \u003d falcon.HTTP_501"},{"line_number":40,"context_line":""},{"line_number":41,"context_line":"    def on_head(self, req, res):"},{"line_number":42,"context_line":"        \"\"\"Simple healthcheck report on HEAD."}],"source_content_type":"text/x-python","patch_set":3,"id":"ff0f0b1f_56777703","line":39,"in_reply_to":"ff0f0b1f_010ada88","updated":"2017-05-22 06:46:51.000000000","message":"Done","commit_id":"e555806667958c7b241aef821565528e59df0938"},{"author":{"_account_id":16168,"name":"Tomasz Trębski","email":"kornicameister@gmail.com","username":"trebskit"},"change_message_id":"bbc169257cfb829a204831037f921935afa5e418","unresolved":false,"context_lines":[{"line_number":48,"context_line":"        :param falcon.Request req: current request"},{"line_number":49,"context_line":"        :param falcon.Response res: current response"},{"line_number":50,"context_line":"        \"\"\""},{"line_number":51,"context_line":"        res.status \u003d falcon.HTTP_501"}],"source_content_type":"text/x-python","patch_set":3,"id":"ff0f0b1f_c103c272","line":51,"updated":"2017-05-22 04:15:00.000000000","message":"# pragma: no cover","commit_id":"e555806667958c7b241aef821565528e59df0938"},{"author":{"_account_id":20033,"name":"Artur Basiak","email":"artur.basiak@ts.fujitsu.com","username":"abasiak"},"change_message_id":"b83a01f4a7332c1b8148e5f9e56b91b4dd514a3e","unresolved":false,"context_lines":[{"line_number":48,"context_line":"        :param falcon.Request req: current request"},{"line_number":49,"context_line":"        :param falcon.Response res: current response"},{"line_number":50,"context_line":"        \"\"\""},{"line_number":51,"context_line":"        res.status \u003d falcon.HTTP_501"}],"source_content_type":"text/x-python","patch_set":3,"id":"ff0f0b1f_3672c312","line":51,"in_reply_to":"ff0f0b1f_c103c272","updated":"2017-05-22 06:46:51.000000000","message":"Done","commit_id":"e555806667958c7b241aef821565528e59df0938"}],"monasca_api/common/repositories/exceptions.py":[{"author":{"_account_id":16168,"name":"Tomasz Trębski","email":"kornicameister@gmail.com","username":"trebskit"},"change_message_id":"2373471882577f17826d98cd12891431374a5dd0","unresolved":false,"context_lines":[{"line_number":26,"context_line":""},{"line_number":27,"context_line":"class UnsupportedDriverException(Exception):"},{"line_number":28,"context_line":"    pass"},{"line_number":29,"context_line":""},{"line_number":30,"context_line":"__all__ \u003d (AlreadyExistsException, DoesNotExistException, InvalidUpdateException,"},{"line_number":31,"context_line":"           RepositoryException, MultipleMetricsException, UnsupportedDriverException)"}],"source_content_type":"text/x-python","patch_set":11,"id":"ff0f0b1f_794ea038","line":29,"updated":"2017-05-24 05:22:13.000000000","message":"add one extra empty line.","commit_id":"15173e6b99c6a3627c43edd3d62caf80033918a6"},{"author":{"_account_id":20033,"name":"Artur Basiak","email":"artur.basiak@ts.fujitsu.com","username":"abasiak"},"change_message_id":"a03e5e7e057d8734eed2ccf249ce3b2099f855ce","unresolved":false,"context_lines":[{"line_number":26,"context_line":""},{"line_number":27,"context_line":"class UnsupportedDriverException(Exception):"},{"line_number":28,"context_line":"    pass"},{"line_number":29,"context_line":""},{"line_number":30,"context_line":"__all__ \u003d (AlreadyExistsException, DoesNotExistException, InvalidUpdateException,"},{"line_number":31,"context_line":"           RepositoryException, MultipleMetricsException, UnsupportedDriverException)"}],"source_content_type":"text/x-python","patch_set":11,"id":"ff0f0b1f_833e96be","line":29,"in_reply_to":"ff0f0b1f_794ea038","updated":"2017-05-24 11:07:54.000000000","message":"Done","commit_id":"15173e6b99c6a3627c43edd3d62caf80033918a6"}],"monasca_api/healtcheck/kafka_check.py":[{"author":{"_account_id":11809,"name":"Craig Bryant","email":"craig.bryant@hpe.com","username":"craig-bryant"},"change_message_id":"d4373b3598959583db289336492edf9d284aae92","unresolved":false,"context_lines":[{"line_number":41,"context_line":""},{"line_number":42,"context_line":"    @staticmethod"},{"line_number":43,"context_line":"    def _verify_topics(kafka_client):"},{"line_number":44,"context_line":"        topics \u003d CONF.kafka.metrics_topic"},{"line_number":45,"context_line":""},{"line_number":46,"context_line":"        for topic in topics:"},{"line_number":47,"context_line":"            for_topic \u003d topic in kafka_client.topic_partitions"}],"source_content_type":"text/x-python","patch_set":1,"id":"ff0f0b1f_6fa571b5","line":44,"range":{"start_line":44,"start_character":28,"end_line":44,"end_character":41},"updated":"2017-05-17 14:30:10.000000000","message":"There are two other kafka topics used by the API: events and alarm-state-transitions. Unfortunately, in one of the refactorings, events was removed from the conf file. So, unless they get added to the conf file, we\u0027ll have to just hard code them.","commit_id":"2d244a0af4fc6854f34557b2dc4eaca984217d02"},{"author":{"_account_id":20033,"name":"Artur Basiak","email":"artur.basiak@ts.fujitsu.com","username":"abasiak"},"change_message_id":"7d82082b872bcf1773221b3e1579fcc0eb1e185c","unresolved":false,"context_lines":[{"line_number":41,"context_line":""},{"line_number":42,"context_line":"    @staticmethod"},{"line_number":43,"context_line":"    def _verify_topics(kafka_client):"},{"line_number":44,"context_line":"        topics \u003d CONF.kafka.metrics_topic"},{"line_number":45,"context_line":""},{"line_number":46,"context_line":"        for topic in topics:"},{"line_number":47,"context_line":"            for_topic \u003d topic in kafka_client.topic_partitions"}],"source_content_type":"text/x-python","patch_set":1,"id":"ff0f0b1f_5820f2b0","line":44,"range":{"start_line":44,"start_character":28,"end_line":44,"end_character":41},"in_reply_to":"ff0f0b1f_6fa571b5","updated":"2017-05-19 11:07:18.000000000","message":"I will add those topics to configuration options.","commit_id":"2d244a0af4fc6854f34557b2dc4eaca984217d02"},{"author":{"_account_id":11809,"name":"Craig Bryant","email":"craig.bryant@hpe.com","username":"craig-bryant"},"change_message_id":"d4373b3598959583db289336492edf9d284aae92","unresolved":false,"context_lines":[{"line_number":49,"context_line":"                error_str \u003d \u0027Kafka: Topic {0} not found\u0027.format(for_topic)"},{"line_number":50,"context_line":"                LOG.error(error_str)"},{"line_number":51,"context_line":"                return base.CheckResult(health\u003dFalse, message\u003derror_str)"},{"line_number":52,"context_line":"        return base.CheckResult(health\u003dTrue, message\u003d\u0027OK\u0027)"},{"line_number":53,"context_line":""},{"line_number":54,"context_line":"    @staticmethod"},{"line_number":55,"context_line":"    def _disconnect_gracefully(kafka_client):"}],"source_content_type":"text/x-python","patch_set":1,"id":"ff0f0b1f_6f50d133","line":52,"range":{"start_line":52,"start_character":15,"end_line":52,"end_character":31},"updated":"2017-05-17 14:30:10.000000000","message":"The other ones don\u0027t return a base.CheckResult","commit_id":"2d244a0af4fc6854f34557b2dc4eaca984217d02"},{"author":{"_account_id":11809,"name":"Craig Bryant","email":"craig.bryant@hpe.com","username":"craig-bryant"},"change_message_id":"d4373b3598959583db289336492edf9d284aae92","unresolved":false,"context_lines":[{"line_number":56,"context_line":"        try:"},{"line_number":57,"context_line":"            kafka_client.close()"},{"line_number":58,"context_line":"        except Exception as ex:"},{"line_number":59,"context_line":"            LOG.exception(str(ex))"}],"source_content_type":"text/x-python","patch_set":1,"id":"ff0f0b1f_2f9d3959","line":59,"range":{"start_line":59,"start_character":26,"end_line":59,"end_character":33},"updated":"2017-05-17 14:30:10.000000000","message":"This would be clearer if you used \u0027Closing Kafka Connection\u0027. LOG.exception already prints all of the exception information including the message.","commit_id":"2d244a0af4fc6854f34557b2dc4eaca984217d02"}],"monasca_api/healtcheck/timeseries_db_check.py":[{"author":{"_account_id":11809,"name":"Craig Bryant","email":"craig.bryant@hpe.com","username":"craig-bryant"},"change_message_id":"d4373b3598959583db289336492edf9d284aae92","unresolved":false,"context_lines":[{"line_number":42,"context_line":"        if \u0027influxdb\u0027 in driver:"},{"line_number":43,"context_line":"            return \u0027influxdb\u0027"},{"line_number":44,"context_line":"        elif \u0027cassandra\u0027 in driver:"},{"line_number":45,"context_line":"            return \u0027casandra\u0027"},{"line_number":46,"context_line":"        else:"},{"line_number":47,"context_line":"            raise Exception("},{"line_number":48,"context_line":"                \u0027Driver {0} is not supported by Healthcheck\u0027.format(driver))"}],"source_content_type":"text/x-python","patch_set":1,"id":"ff0f0b1f_8f05657d","line":45,"range":{"start_line":45,"start_character":20,"end_line":45,"end_character":28},"updated":"2017-05-17 14:30:10.000000000","message":"Misspelled","commit_id":"2d244a0af4fc6854f34557b2dc4eaca984217d02"},{"author":{"_account_id":20033,"name":"Artur Basiak","email":"artur.basiak@ts.fujitsu.com","username":"abasiak"},"change_message_id":"7d82082b872bcf1773221b3e1579fcc0eb1e185c","unresolved":false,"context_lines":[{"line_number":42,"context_line":"        if \u0027influxdb\u0027 in driver:"},{"line_number":43,"context_line":"            return \u0027influxdb\u0027"},{"line_number":44,"context_line":"        elif \u0027cassandra\u0027 in driver:"},{"line_number":45,"context_line":"            return \u0027casandra\u0027"},{"line_number":46,"context_line":"        else:"},{"line_number":47,"context_line":"            raise Exception("},{"line_number":48,"context_line":"                \u0027Driver {0} is not supported by Healthcheck\u0027.format(driver))"}],"source_content_type":"text/x-python","patch_set":1,"id":"ff0f0b1f_d350630d","line":45,"range":{"start_line":45,"start_character":20,"end_line":45,"end_character":28},"in_reply_to":"ff0f0b1f_8f05657d","updated":"2017-05-19 11:07:18.000000000","message":"thx","commit_id":"2d244a0af4fc6854f34557b2dc4eaca984217d02"}],"monasca_api/healthcheck/alarms_db_check.py":[{"author":{"_account_id":16168,"name":"Tomasz Trębski","email":"kornicameister@gmail.com","username":"trebskit"},"change_message_id":"2373471882577f17826d98cd12891431374a5dd0","unresolved":false,"context_lines":[{"line_number":21,"context_line":"LOG \u003d log.getLogger(__name__)"},{"line_number":22,"context_line":""},{"line_number":23,"context_line":""},{"line_number":24,"context_line":"class AlarmsDbHealthCheck(base.BaseHealthCheck,"},{"line_number":25,"context_line":"                          sql_repository.SQLRepository):"},{"line_number":26,"context_line":""},{"line_number":27,"context_line":"    def health_check(self):"}],"source_content_type":"text/x-python","patch_set":11,"id":"ff0f0b1f_3966e8c2","line":24,"updated":"2017-05-24 05:22:13.000000000","message":"Might be nice to add some documentation.","commit_id":"15173e6b99c6a3627c43edd3d62caf80033918a6"},{"author":{"_account_id":20033,"name":"Artur Basiak","email":"artur.basiak@ts.fujitsu.com","username":"abasiak"},"change_message_id":"a03e5e7e057d8734eed2ccf249ce3b2099f855ce","unresolved":false,"context_lines":[{"line_number":21,"context_line":"LOG \u003d log.getLogger(__name__)"},{"line_number":22,"context_line":""},{"line_number":23,"context_line":""},{"line_number":24,"context_line":"class AlarmsDbHealthCheck(base.BaseHealthCheck,"},{"line_number":25,"context_line":"                          sql_repository.SQLRepository):"},{"line_number":26,"context_line":""},{"line_number":27,"context_line":"    def health_check(self):"}],"source_content_type":"text/x-python","patch_set":11,"id":"ff0f0b1f_633942d5","line":24,"in_reply_to":"ff0f0b1f_3966e8c2","updated":"2017-05-24 11:07:54.000000000","message":"Done","commit_id":"15173e6b99c6a3627c43edd3d62caf80033918a6"},{"author":{"_account_id":2419,"name":"Roland Hochmuth","email":"roland.hochmuth@hpe.com","username":"roland-hochmuth-s"},"change_message_id":"92908030bd7b4b96a65bbdb4d68567a56bc3eca3","unresolved":false,"context_lines":[{"line_number":22,"context_line":""},{"line_number":23,"context_line":""},{"line_number":24,"context_line":"class AlarmsDbHealthCheck(base.BaseHealthCheck,"},{"line_number":25,"context_line":"                          sql_repository.SQLRepository):"},{"line_number":26,"context_line":"    \"\"\"Evaluates alarm db health"},{"line_number":27,"context_line":""},{"line_number":28,"context_line":"    Health check verifies if:"}],"source_content_type":"text/x-python","patch_set":13,"id":"ff0f0b1f_d1dfaa0a","line":25,"updated":"2017-05-24 19:43:39.000000000","message":"Should this class be moved to the common/repositories/alarms_repository.py?","commit_id":"3f6a8ca11367ea9f4ca4dc5d7f5bb531f6e627ba"},{"author":{"_account_id":20033,"name":"Artur Basiak","email":"artur.basiak@ts.fujitsu.com","username":"abasiak"},"change_message_id":"124944b9ad4f2cb9a729753b2f319ec6ee84dd2b","unresolved":false,"context_lines":[{"line_number":22,"context_line":""},{"line_number":23,"context_line":""},{"line_number":24,"context_line":"class AlarmsDbHealthCheck(base.BaseHealthCheck,"},{"line_number":25,"context_line":"                          sql_repository.SQLRepository):"},{"line_number":26,"context_line":"    \"\"\"Evaluates alarm db health"},{"line_number":27,"context_line":""},{"line_number":28,"context_line":"    Health check verifies if:"}],"source_content_type":"text/x-python","patch_set":13,"id":"ff0f0b1f_5fa9558d","line":25,"in_reply_to":"ff0f0b1f_d1dfaa0a","updated":"2017-05-25 06:46:04.000000000","message":"It can be moved to the alarms_repository but AlarmsRepository is an metaclass and if I move it to there and inherit by this class a also need to overwrite all the abstract methods and that might not be a good idea.","commit_id":"3f6a8ca11367ea9f4ca4dc5d7f5bb531f6e627ba"}],"monasca_api/healthcheck/base.py":[{"author":{"_account_id":16168,"name":"Tomasz Trębski","email":"kornicameister@gmail.com","username":"trebskit"},"change_message_id":"bbc169257cfb829a204831037f921935afa5e418","unresolved":false,"context_lines":[{"line_number":27,"context_line":"    @abc.abstractmethod"},{"line_number":28,"context_line":"    def health_check(self):"},{"line_number":29,"context_line":"        \"\"\"Evaluate health of given service\"\"\""},{"line_number":30,"context_line":"        raise NotImplementedError"}],"source_content_type":"text/x-python","patch_set":3,"id":"ff0f0b1f_61f4f686","line":30,"updated":"2017-05-22 04:15:00.000000000","message":"# pragma: no cover","commit_id":"e555806667958c7b241aef821565528e59df0938"},{"author":{"_account_id":20033,"name":"Artur Basiak","email":"artur.basiak@ts.fujitsu.com","username":"abasiak"},"change_message_id":"b83a01f4a7332c1b8148e5f9e56b91b4dd514a3e","unresolved":false,"context_lines":[{"line_number":27,"context_line":"    @abc.abstractmethod"},{"line_number":28,"context_line":"    def health_check(self):"},{"line_number":29,"context_line":"        \"\"\"Evaluate health of given service\"\"\""},{"line_number":30,"context_line":"        raise NotImplementedError"}],"source_content_type":"text/x-python","patch_set":3,"id":"ff0f0b1f_d6d147cf","line":30,"in_reply_to":"ff0f0b1f_61f4f686","updated":"2017-05-22 06:46:51.000000000","message":"Done","commit_id":"e555806667958c7b241aef821565528e59df0938"},{"author":{"_account_id":16168,"name":"Tomasz Trębski","email":"kornicameister@gmail.com","username":"trebskit"},"change_message_id":"2373471882577f17826d98cd12891431374a5dd0","unresolved":false,"context_lines":[{"line_number":17,"context_line":""},{"line_number":18,"context_line":"import six"},{"line_number":19,"context_line":""},{"line_number":20,"context_line":"CheckResult \u003d collections.namedtuple(\u0027CheckResult\u0027, [\u0027health\u0027, \u0027message\u0027])"},{"line_number":21,"context_line":""},{"line_number":22,"context_line":""},{"line_number":23,"context_line":"@six.add_metaclass(abc.ABCMeta)"}],"source_content_type":"text/x-python","patch_set":11,"id":"ff0f0b1f_f95bd0f2","line":20,"updated":"2017-05-24 05:22:13.000000000","message":"Documentation","commit_id":"15173e6b99c6a3627c43edd3d62caf80033918a6"},{"author":{"_account_id":20033,"name":"Artur Basiak","email":"artur.basiak@ts.fujitsu.com","username":"abasiak"},"change_message_id":"a03e5e7e057d8734eed2ccf249ce3b2099f855ce","unresolved":false,"context_lines":[{"line_number":17,"context_line":""},{"line_number":18,"context_line":"import six"},{"line_number":19,"context_line":""},{"line_number":20,"context_line":"CheckResult \u003d collections.namedtuple(\u0027CheckResult\u0027, [\u0027health\u0027, \u0027message\u0027])"},{"line_number":21,"context_line":""},{"line_number":22,"context_line":""},{"line_number":23,"context_line":"@six.add_metaclass(abc.ABCMeta)"}],"source_content_type":"text/x-python","patch_set":11,"id":"ff0f0b1f_43b75e3b","line":20,"in_reply_to":"ff0f0b1f_f95bd0f2","updated":"2017-05-24 11:07:54.000000000","message":"Done","commit_id":"15173e6b99c6a3627c43edd3d62caf80033918a6"},{"author":{"_account_id":2419,"name":"Roland Hochmuth","email":"roland.hochmuth@hpe.com","username":"roland-hochmuth-s"},"change_message_id":"92908030bd7b4b96a65bbdb4d68567a56bc3eca3","unresolved":false,"context_lines":[{"line_number":23,"context_line":""},{"line_number":24,"context_line":"    health - boolean"},{"line_number":25,"context_line":"    message - string"},{"line_number":26,"context_line":"    \"\"\""},{"line_number":27,"context_line":""},{"line_number":28,"context_line":""},{"line_number":29,"context_line":"@six.add_metaclass(abc.ABCMeta)"}],"source_content_type":"text/x-python","patch_set":13,"id":"ff0f0b1f_acd29ecf","line":26,"updated":"2017-05-24 19:43:39.000000000","message":"I was just wondering why the change from the monasca-log-api? I think the log-api returns HealthCheckResult with status and details in the response body. But, here you are returning health and message. Should these be the same or am I misunderstanding?","commit_id":"3f6a8ca11367ea9f4ca4dc5d7f5bb531f6e627ba"},{"author":{"_account_id":20033,"name":"Artur Basiak","email":"artur.basiak@ts.fujitsu.com","username":"abasiak"},"change_message_id":"124944b9ad4f2cb9a729753b2f319ec6ee84dd2b","unresolved":false,"context_lines":[{"line_number":23,"context_line":""},{"line_number":24,"context_line":"    health - boolean"},{"line_number":25,"context_line":"    message - string"},{"line_number":26,"context_line":"    \"\"\""},{"line_number":27,"context_line":""},{"line_number":28,"context_line":""},{"line_number":29,"context_line":"@six.add_metaclass(abc.ABCMeta)"}],"source_content_type":"text/x-python","patch_set":13,"id":"ff0f0b1f_7c942737","line":26,"in_reply_to":"ff0f0b1f_acd29ecf","updated":"2017-05-25 06:46:04.000000000","message":"This is the same approach as in monasca-log-api. I took the code from the just refactored a little bit. Status and details are returned in the response body.","commit_id":"3f6a8ca11367ea9f4ca4dc5d7f5bb531f6e627ba"}],"monasca_api/healthcheck/kafka_check.py":[{"author":{"_account_id":16168,"name":"Tomasz Trębski","email":"kornicameister@gmail.com","username":"trebskit"},"change_message_id":"bbc169257cfb829a204831037f921935afa5e418","unresolved":false,"context_lines":[{"line_number":45,"context_line":"        topics \u003d (CONF.kafka.metrics_topic,"},{"line_number":46,"context_line":"                  CONF.kafka.events_topic,"},{"line_number":47,"context_line":"                  CONF.kafka.alarm_state_transitions_topic"},{"line_number":48,"context_line":"                  )"},{"line_number":49,"context_line":""},{"line_number":50,"context_line":"        for topic in topics:"},{"line_number":51,"context_line":"            for_topic \u003d topic in kafka_client.topic_partitions"}],"source_content_type":"text/x-python","patch_set":3,"id":"ff0f0b1f_212cbe00","line":48,"updated":"2017-05-22 04:15:00.000000000","message":"Move it to L47","commit_id":"e555806667958c7b241aef821565528e59df0938"},{"author":{"_account_id":20033,"name":"Artur Basiak","email":"artur.basiak@ts.fujitsu.com","username":"abasiak"},"change_message_id":"b83a01f4a7332c1b8148e5f9e56b91b4dd514a3e","unresolved":false,"context_lines":[{"line_number":45,"context_line":"        topics \u003d (CONF.kafka.metrics_topic,"},{"line_number":46,"context_line":"                  CONF.kafka.events_topic,"},{"line_number":47,"context_line":"                  CONF.kafka.alarm_state_transitions_topic"},{"line_number":48,"context_line":"                  )"},{"line_number":49,"context_line":""},{"line_number":50,"context_line":"        for topic in topics:"},{"line_number":51,"context_line":"            for_topic \u003d topic in kafka_client.topic_partitions"}],"source_content_type":"text/x-python","patch_set":3,"id":"ff0f0b1f_56e537a7","line":48,"in_reply_to":"ff0f0b1f_212cbe00","updated":"2017-05-22 06:46:51.000000000","message":"Done","commit_id":"e555806667958c7b241aef821565528e59df0938"},{"author":{"_account_id":16168,"name":"Tomasz Trębski","email":"kornicameister@gmail.com","username":"trebskit"},"change_message_id":"2373471882577f17826d98cd12891431374a5dd0","unresolved":false,"context_lines":[{"line_number":22,"context_line":"CONF \u003d cfg.CONF"},{"line_number":23,"context_line":""},{"line_number":24,"context_line":""},{"line_number":25,"context_line":"class KafkaHealthCheck(base.BaseHealthCheck):"},{"line_number":26,"context_line":""},{"line_number":27,"context_line":"    def health_check(self):"},{"line_number":28,"context_line":"        url \u003d CONF.kafka.uri"}],"source_content_type":"text/x-python","patch_set":11,"id":"ff0f0b1f_f9de303c","line":25,"updated":"2017-05-24 05:22:13.000000000","message":"Documentation","commit_id":"15173e6b99c6a3627c43edd3d62caf80033918a6"},{"author":{"_account_id":2419,"name":"Roland Hochmuth","email":"roland.hochmuth@hpe.com","username":"roland-hochmuth-s"},"change_message_id":"92908030bd7b4b96a65bbdb4d68567a56bc3eca3","unresolved":false,"context_lines":[{"line_number":46,"context_line":"        except client.KafkaUnavailableError as ex:"},{"line_number":47,"context_line":"            LOG.error(repr(ex))"},{"line_number":48,"context_line":"            error_str \u003d \u0027Could not connect to Kafka at {0}\u0027.format(url)"},{"line_number":49,"context_line":"            return base.CheckResult(health\u003dFalse, message\u003derror_str)"},{"line_number":50,"context_line":""},{"line_number":51,"context_line":"        status \u003d self._verify_topics(kafka_client)"},{"line_number":52,"context_line":"        self._disconnect_gracefully(kafka_client)"}],"source_content_type":"text/x-python","patch_set":13,"id":"ff0f0b1f_6c7486cf","line":49,"updated":"2017-05-24 19:43:39.000000000","message":"nit, but the log api returns \"healthy\" instead of \"health\".","commit_id":"3f6a8ca11367ea9f4ca4dc5d7f5bb531f6e627ba"},{"author":{"_account_id":20033,"name":"Artur Basiak","email":"artur.basiak@ts.fujitsu.com","username":"abasiak"},"change_message_id":"124944b9ad4f2cb9a729753b2f319ec6ee84dd2b","unresolved":false,"context_lines":[{"line_number":46,"context_line":"        except client.KafkaUnavailableError as ex:"},{"line_number":47,"context_line":"            LOG.error(repr(ex))"},{"line_number":48,"context_line":"            error_str \u003d \u0027Could not connect to Kafka at {0}\u0027.format(url)"},{"line_number":49,"context_line":"            return base.CheckResult(health\u003dFalse, message\u003derror_str)"},{"line_number":50,"context_line":""},{"line_number":51,"context_line":"        status \u003d self._verify_topics(kafka_client)"},{"line_number":52,"context_line":"        self._disconnect_gracefully(kafka_client)"}],"source_content_type":"text/x-python","patch_set":13,"id":"ff0f0b1f_5c0cc392","line":49,"in_reply_to":"ff0f0b1f_6c7486cf","updated":"2017-05-25 06:46:04.000000000","message":"Done","commit_id":"3f6a8ca11367ea9f4ca4dc5d7f5bb531f6e627ba"},{"author":{"_account_id":2419,"name":"Roland Hochmuth","email":"roland.hochmuth@hpe.com","username":"roland-hochmuth-s"},"change_message_id":"92908030bd7b4b96a65bbdb4d68567a56bc3eca3","unresolved":false,"context_lines":[{"line_number":72,"context_line":"    def _disconnect_gracefully(kafka_client):"},{"line_number":73,"context_line":"        try:"},{"line_number":74,"context_line":"            kafka_client.close()"},{"line_number":75,"context_line":"        except Exception:"},{"line_number":76,"context_line":"            LOG.exception(\u0027Closing Kafka Connection\u0027)"}],"source_content_type":"text/x-python","patch_set":13,"id":"ff0f0b1f_6c2246bb","line":75,"updated":"2017-05-24 19:43:39.000000000","message":"log-api logs an error, but you are logging an exception here.","commit_id":"3f6a8ca11367ea9f4ca4dc5d7f5bb531f6e627ba"},{"author":{"_account_id":16168,"name":"Tomasz Trębski","email":"kornicameister@gmail.com","username":"trebskit"},"change_message_id":"7d308c8ee4254424fa58a0f2ae1d7e18fccef36c","unresolved":false,"context_lines":[{"line_number":25,"context_line":"class KafkaHealthCheck(base.BaseHealthCheck):"},{"line_number":26,"context_line":"    \"\"\"Evaluates kafka health"},{"line_number":27,"context_line":""},{"line_number":28,"context_line":"    Health check verifies if:"},{"line_number":29,"context_line":""},{"line_number":30,"context_line":"    * kafka server is up and running"},{"line_number":31,"context_line":"    * there is a configured topic in kafka"}],"source_content_type":"text/x-python","patch_set":18,"id":"df140735_6147a51f","line":28,"updated":"2017-05-30 09:20:28.000000000","message":"nit: Healthcheck","commit_id":"1139393e8bbd752e966885cbe614b2577e5639cd"},{"author":{"_account_id":20033,"name":"Artur Basiak","email":"artur.basiak@ts.fujitsu.com","username":"abasiak"},"change_message_id":"9fef7ad5ffb305718128fe1f05ed98d428272ef7","unresolved":false,"context_lines":[{"line_number":25,"context_line":"class KafkaHealthCheck(base.BaseHealthCheck):"},{"line_number":26,"context_line":"    \"\"\"Evaluates kafka health"},{"line_number":27,"context_line":""},{"line_number":28,"context_line":"    Health check verifies if:"},{"line_number":29,"context_line":""},{"line_number":30,"context_line":"    * kafka server is up and running"},{"line_number":31,"context_line":"    * there is a configured topic in kafka"}],"source_content_type":"text/x-python","patch_set":18,"id":"df140735_41c94176","line":28,"in_reply_to":"df140735_6147a51f","updated":"2017-05-30 09:30:28.000000000","message":"Done","commit_id":"1139393e8bbd752e966885cbe614b2577e5639cd"},{"author":{"_account_id":16168,"name":"Tomasz Trębski","email":"kornicameister@gmail.com","username":"trebskit"},"change_message_id":"7d308c8ee4254424fa58a0f2ae1d7e18fccef36c","unresolved":false,"context_lines":[{"line_number":34,"context_line":"    Otherwise unhealthy status is returned with message."},{"line_number":35,"context_line":""},{"line_number":36,"context_line":"    Note:"},{"line_number":37,"context_line":"        Health check checks 3 type of topics given in configuration:"},{"line_number":38,"context_line":"        metrics_topic, events_topic and alarm_state_transition_topic."},{"line_number":39,"context_line":"    \"\"\""},{"line_number":40,"context_line":""}],"source_content_type":"text/x-python","patch_set":18,"id":"df140735_0160e9a4","line":37,"updated":"2017-05-30 09:20:28.000000000","message":"nit: Healthcheck","commit_id":"1139393e8bbd752e966885cbe614b2577e5639cd"},{"author":{"_account_id":20033,"name":"Artur Basiak","email":"artur.basiak@ts.fujitsu.com","username":"abasiak"},"change_message_id":"9fef7ad5ffb305718128fe1f05ed98d428272ef7","unresolved":false,"context_lines":[{"line_number":34,"context_line":"    Otherwise unhealthy status is returned with message."},{"line_number":35,"context_line":""},{"line_number":36,"context_line":"    Note:"},{"line_number":37,"context_line":"        Health check checks 3 type of topics given in configuration:"},{"line_number":38,"context_line":"        metrics_topic, events_topic and alarm_state_transition_topic."},{"line_number":39,"context_line":"    \"\"\""},{"line_number":40,"context_line":""}],"source_content_type":"text/x-python","patch_set":18,"id":"df140735_21c64d69","line":37,"in_reply_to":"df140735_0160e9a4","updated":"2017-05-30 09:30:28.000000000","message":"Done","commit_id":"1139393e8bbd752e966885cbe614b2577e5639cd"}],"monasca_api/healthcheck/metrics_db_check.py":[{"author":{"_account_id":16168,"name":"Tomasz Trębski","email":"kornicameister@gmail.com","username":"trebskit"},"change_message_id":"2373471882577f17826d98cd12891431374a5dd0","unresolved":false,"context_lines":[{"line_number":25,"context_line":"CONF \u003d cfg.CONF"},{"line_number":26,"context_line":""},{"line_number":27,"context_line":""},{"line_number":28,"context_line":"class MetricsDbCheck(base.BaseHealthCheck):"},{"line_number":29,"context_line":""},{"line_number":30,"context_line":"    def health_check(self):"},{"line_number":31,"context_line":"        metric_driver \u003d CONF.repositories.metrics_driver"}],"source_content_type":"text/x-python","patch_set":11,"id":"ff0f0b1f_99ef34e8","line":28,"updated":"2017-05-24 05:22:13.000000000","message":"Documentation","commit_id":"15173e6b99c6a3627c43edd3d62caf80033918a6"},{"author":{"_account_id":20033,"name":"Artur Basiak","email":"artur.basiak@ts.fujitsu.com","username":"abasiak"},"change_message_id":"a03e5e7e057d8734eed2ccf249ce3b2099f855ce","unresolved":false,"context_lines":[{"line_number":25,"context_line":"CONF \u003d cfg.CONF"},{"line_number":26,"context_line":""},{"line_number":27,"context_line":""},{"line_number":28,"context_line":"class MetricsDbCheck(base.BaseHealthCheck):"},{"line_number":29,"context_line":""},{"line_number":30,"context_line":"    def health_check(self):"},{"line_number":31,"context_line":"        metric_driver \u003d CONF.repositories.metrics_driver"}],"source_content_type":"text/x-python","patch_set":11,"id":"ff0f0b1f_636a621a","line":28,"in_reply_to":"ff0f0b1f_99ef34e8","updated":"2017-05-24 11:07:54.000000000","message":"Done","commit_id":"15173e6b99c6a3627c43edd3d62caf80033918a6"},{"author":{"_account_id":2419,"name":"Roland Hochmuth","email":"roland.hochmuth@hpe.com","username":"roland-hochmuth-s"},"change_message_id":"92908030bd7b4b96a65bbdb4d68567a56bc3eca3","unresolved":false,"context_lines":[{"line_number":14,"context_line":""},{"line_number":15,"context_line":"import requests"},{"line_number":16,"context_line":""},{"line_number":17,"context_line":"from cassandra import cluster"},{"line_number":18,"context_line":"from oslo_config import cfg"},{"line_number":19,"context_line":"from oslo_log import log"},{"line_number":20,"context_line":""}],"source_content_type":"text/x-python","patch_set":13,"id":"ff0f0b1f_51e95ae3","line":17,"updated":"2017-05-24 19:43:39.000000000","message":"Just wondering if cassandra should be removed, as it isn\u0027t officially supported and importing here forces a dependency on Cassandra.","commit_id":"3f6a8ca11367ea9f4ca4dc5d7f5bb531f6e627ba"},{"author":{"_account_id":20033,"name":"Artur Basiak","email":"artur.basiak@ts.fujitsu.com","username":"abasiak"},"change_message_id":"124944b9ad4f2cb9a729753b2f319ec6ee84dd2b","unresolved":false,"context_lines":[{"line_number":14,"context_line":""},{"line_number":15,"context_line":"import requests"},{"line_number":16,"context_line":""},{"line_number":17,"context_line":"from cassandra import cluster"},{"line_number":18,"context_line":"from oslo_config import cfg"},{"line_number":19,"context_line":"from oslo_log import log"},{"line_number":20,"context_line":""}],"source_content_type":"text/x-python","patch_set":13,"id":"ff0f0b1f_9f624dad","line":17,"in_reply_to":"ff0f0b1f_51e95ae3","updated":"2017-05-25 06:46:04.000000000","message":"AFAIK Cassandra is optional database so it might be a good idea to also check it status.","commit_id":"3f6a8ca11367ea9f4ca4dc5d7f5bb531f6e627ba"},{"author":{"_account_id":2419,"name":"Roland Hochmuth","email":"roland.hochmuth@hpe.com","username":"roland-hochmuth-s"},"change_message_id":"92908030bd7b4b96a65bbdb4d68567a56bc3eca3","unresolved":false,"context_lines":[{"line_number":64,"context_line":"                \u0027Driver {0} is not supported by Healthcheck\u0027.format(driver))"},{"line_number":65,"context_line":""},{"line_number":66,"context_line":"    @staticmethod"},{"line_number":67,"context_line":"    def _check_influxdb_status():"},{"line_number":68,"context_line":"        uri \u003d \u0027http://{0}:{1}/ping\u0027.format(CONF.influxdb.ip_address,"},{"line_number":69,"context_line":"                                           CONF.influxdb.port)"},{"line_number":70,"context_line":"        try:"}],"source_content_type":"text/x-python","patch_set":13,"id":"ff0f0b1f_b1943638","line":67,"updated":"2017-05-24 19:43:39.000000000","message":"Was going to suggest that a method \"check_status\" be added to the metrics repo. For example, add to the AbstractMetricsRepository the check_status method. This would also address the Cassandra dependency.","commit_id":"3f6a8ca11367ea9f4ca4dc5d7f5bb531f6e627ba"},{"author":{"_account_id":20033,"name":"Artur Basiak","email":"artur.basiak@ts.fujitsu.com","username":"abasiak"},"change_message_id":"124944b9ad4f2cb9a729753b2f319ec6ee84dd2b","unresolved":false,"context_lines":[{"line_number":64,"context_line":"                \u0027Driver {0} is not supported by Healthcheck\u0027.format(driver))"},{"line_number":65,"context_line":""},{"line_number":66,"context_line":"    @staticmethod"},{"line_number":67,"context_line":"    def _check_influxdb_status():"},{"line_number":68,"context_line":"        uri \u003d \u0027http://{0}:{1}/ping\u0027.format(CONF.influxdb.ip_address,"},{"line_number":69,"context_line":"                                           CONF.influxdb.port)"},{"line_number":70,"context_line":"        try:"}],"source_content_type":"text/x-python","patch_set":13,"id":"ff0f0b1f_7f3c1992","line":67,"in_reply_to":"ff0f0b1f_b1943638","updated":"2017-05-25 06:46:04.000000000","message":"I don\u0027t think this is a good idea. If I add check_status method to the metric repository I would need to create repositories objects to check their health status and it would be little redundant.","commit_id":"3f6a8ca11367ea9f4ca4dc5d7f5bb531f6e627ba"},{"author":{"_account_id":16168,"name":"Tomasz Trębski","email":"kornicameister@gmail.com","username":"trebskit"},"change_message_id":"7d308c8ee4254424fa58a0f2ae1d7e18fccef36c","unresolved":false,"context_lines":[{"line_number":28,"context_line":"class MetricsDbCheck(base.BaseHealthCheck):"},{"line_number":29,"context_line":"    \"\"\"Evaluates metrics db health"},{"line_number":30,"context_line":""},{"line_number":31,"context_line":"    Health check what type of database is used (InfluxDB, Cassandra)"},{"line_number":32,"context_line":"    and provide health according to the given db."},{"line_number":33,"context_line":""},{"line_number":34,"context_line":"    Health for InfluxDB verifies if:"}],"source_content_type":"text/x-python","patch_set":18,"id":"df140735_814ab924","line":31,"updated":"2017-05-30 09:20:28.000000000","message":"nit: Healthcheck","commit_id":"1139393e8bbd752e966885cbe614b2577e5639cd"},{"author":{"_account_id":20033,"name":"Artur Basiak","email":"artur.basiak@ts.fujitsu.com","username":"abasiak"},"change_message_id":"9fef7ad5ffb305718128fe1f05ed98d428272ef7","unresolved":false,"context_lines":[{"line_number":28,"context_line":"class MetricsDbCheck(base.BaseHealthCheck):"},{"line_number":29,"context_line":"    \"\"\"Evaluates metrics db health"},{"line_number":30,"context_line":""},{"line_number":31,"context_line":"    Health check what type of database is used (InfluxDB, Cassandra)"},{"line_number":32,"context_line":"    and provide health according to the given db."},{"line_number":33,"context_line":""},{"line_number":34,"context_line":"    Health for InfluxDB verifies if:"}],"source_content_type":"text/x-python","patch_set":18,"id":"df140735_419ee163","line":31,"in_reply_to":"df140735_814ab924","updated":"2017-05-30 09:30:28.000000000","message":"Done","commit_id":"1139393e8bbd752e966885cbe614b2577e5639cd"},{"author":{"_account_id":16168,"name":"Tomasz Trębski","email":"kornicameister@gmail.com","username":"trebskit"},"change_message_id":"7d308c8ee4254424fa58a0f2ae1d7e18fccef36c","unresolved":false,"context_lines":[{"line_number":31,"context_line":"    Health check what type of database is used (InfluxDB, Cassandra)"},{"line_number":32,"context_line":"    and provide health according to the given db."},{"line_number":33,"context_line":""},{"line_number":34,"context_line":"    Health for InfluxDB verifies if:"},{"line_number":35,"context_line":"    * check the db status by the /ping endpoint."},{"line_number":36,"context_line":""},{"line_number":37,"context_line":"    Health for the Cassandra verifies if:"}],"source_content_type":"text/x-python","patch_set":18,"id":"df140735_41bf01fb","line":34,"updated":"2017-05-30 09:20:28.000000000","message":"nit: Healthcheck","commit_id":"1139393e8bbd752e966885cbe614b2577e5639cd"},{"author":{"_account_id":20033,"name":"Artur Basiak","email":"artur.basiak@ts.fujitsu.com","username":"abasiak"},"change_message_id":"9fef7ad5ffb305718128fe1f05ed98d428272ef7","unresolved":false,"context_lines":[{"line_number":31,"context_line":"    Health check what type of database is used (InfluxDB, Cassandra)"},{"line_number":32,"context_line":"    and provide health according to the given db."},{"line_number":33,"context_line":""},{"line_number":34,"context_line":"    Health for InfluxDB verifies if:"},{"line_number":35,"context_line":"    * check the db status by the /ping endpoint."},{"line_number":36,"context_line":""},{"line_number":37,"context_line":"    Health for the Cassandra verifies if:"}],"source_content_type":"text/x-python","patch_set":18,"id":"df140735_219bed72","line":34,"in_reply_to":"df140735_41bf01fb","updated":"2017-05-30 09:30:28.000000000","message":"Done","commit_id":"1139393e8bbd752e966885cbe614b2577e5639cd"},{"author":{"_account_id":16168,"name":"Tomasz Trębski","email":"kornicameister@gmail.com","username":"trebskit"},"change_message_id":"7d308c8ee4254424fa58a0f2ae1d7e18fccef36c","unresolved":false,"context_lines":[{"line_number":34,"context_line":"    Health for InfluxDB verifies if:"},{"line_number":35,"context_line":"    * check the db status by the /ping endpoint."},{"line_number":36,"context_line":""},{"line_number":37,"context_line":"    Health for the Cassandra verifies if:"},{"line_number":38,"context_line":"    * Cassandra is up and running (it is possible to create new connection)"},{"line_number":39,"context_line":"    * keyspace exists"},{"line_number":40,"context_line":""}],"source_content_type":"text/x-python","patch_set":18,"id":"df140735_0137c9b2","line":37,"updated":"2017-05-30 09:20:28.000000000","message":"nit: Healthcheck","commit_id":"1139393e8bbd752e966885cbe614b2577e5639cd"},{"author":{"_account_id":20033,"name":"Artur Basiak","email":"artur.basiak@ts.fujitsu.com","username":"abasiak"},"change_message_id":"9fef7ad5ffb305718128fe1f05ed98d428272ef7","unresolved":false,"context_lines":[{"line_number":34,"context_line":"    Health for InfluxDB verifies if:"},{"line_number":35,"context_line":"    * check the db status by the /ping endpoint."},{"line_number":36,"context_line":""},{"line_number":37,"context_line":"    Health for the Cassandra verifies if:"},{"line_number":38,"context_line":"    * Cassandra is up and running (it is possible to create new connection)"},{"line_number":39,"context_line":"    * keyspace exists"},{"line_number":40,"context_line":""}],"source_content_type":"text/x-python","patch_set":18,"id":"df140735_018a291a","line":37,"in_reply_to":"df140735_0137c9b2","updated":"2017-05-30 09:30:28.000000000","message":"Done","commit_id":"1139393e8bbd752e966885cbe614b2577e5639cd"}],"monasca_api/healthchecks.py":[{"author":{"_account_id":11809,"name":"Craig Bryant","email":"craig.bryant@hpe.com","username":"craig-bryant"},"change_message_id":"d4373b3598959583db289336492edf9d284aae92","unresolved":false,"context_lines":[{"line_number":28,"context_line":""},{"line_number":29,"context_line":"    HEALTHY_CODE_GET \u003d falcon.HTTP_OK"},{"line_number":30,"context_line":"    HEALTHY_CODE_HEAD \u003d falcon.HTTP_NO_CONTENT"},{"line_number":31,"context_line":"    NOT_HEALTHY_CODE \u003d falcon.HTTP_SERVICE_UNAVAILABLE"},{"line_number":32,"context_line":""},{"line_number":33,"context_line":"    def __init__(self):"},{"line_number":34,"context_line":"        self._kafka_check \u003d kafka_check.KafkaHealthHealthCheck()"}],"source_content_type":"text/x-python","patch_set":1,"id":"ff0f0b1f_21dc2d73","line":31,"range":{"start_line":31,"start_character":30,"end_line":31,"end_character":54},"updated":"2017-05-17 14:30:10.000000000","message":"I\u0027m not sure about this. If you front the API by something like nginx, then it may return 503 when it can\u0027t contact the Monasca API. How do you distinguish that from the health check returning unhealthy? But, I would be interested in other people\u0027s opinions.","commit_id":"2d244a0af4fc6854f34557b2dc4eaca984217d02"},{"author":{"_account_id":20033,"name":"Artur Basiak","email":"artur.basiak@ts.fujitsu.com","username":"abasiak"},"change_message_id":"7d82082b872bcf1773221b3e1579fcc0eb1e185c","unresolved":false,"context_lines":[{"line_number":28,"context_line":""},{"line_number":29,"context_line":"    HEALTHY_CODE_GET \u003d falcon.HTTP_OK"},{"line_number":30,"context_line":"    HEALTHY_CODE_HEAD \u003d falcon.HTTP_NO_CONTENT"},{"line_number":31,"context_line":"    NOT_HEALTHY_CODE \u003d falcon.HTTP_SERVICE_UNAVAILABLE"},{"line_number":32,"context_line":""},{"line_number":33,"context_line":"    def __init__(self):"},{"line_number":34,"context_line":"        self._kafka_check \u003d kafka_check.KafkaHealthHealthCheck()"}],"source_content_type":"text/x-python","patch_set":1,"id":"ff0f0b1f_930c2b3c","line":31,"range":{"start_line":31,"start_character":30,"end_line":31,"end_character":54},"in_reply_to":"ff0f0b1f_21dc2d73","updated":"2017-05-19 11:07:18.000000000","message":"This was taken from monasca-log-api and this solution works there. The change was accepted without any doubts.","commit_id":"2d244a0af4fc6854f34557b2dc4eaca984217d02"},{"author":{"_account_id":11809,"name":"Craig Bryant","email":"craig.bryant@hpe.com","username":"craig-bryant"},"change_message_id":"d4373b3598959583db289336492edf9d284aae92","unresolved":false,"context_lines":[{"line_number":48,"context_line":"        status_data \u003d {"},{"line_number":49,"context_line":"            \u0027kafka\u0027: kafka_result.message,"},{"line_number":50,"context_line":"            \u0027relational_database\u0027: relational_db_result.message,"},{"line_number":51,"context_line":"            \u0027timestamp_database\u0027: timestamp_db_result.message"},{"line_number":52,"context_line":"        }"},{"line_number":53,"context_line":"        health \u003d (kafka_result.health and relational_db_result.health and"},{"line_number":54,"context_line":"                  timestamp_db_result.health)"}],"source_content_type":"text/x-python","patch_set":1,"id":"ff0f0b1f_41a961dd","line":51,"range":{"start_line":51,"start_character":13,"end_line":51,"end_character":31},"updated":"2017-05-17 14:30:10.000000000","message":"This is really the metrics_database","commit_id":"2d244a0af4fc6854f34557b2dc4eaca984217d02"},{"author":{"_account_id":20033,"name":"Artur Basiak","email":"artur.basiak@ts.fujitsu.com","username":"abasiak"},"change_message_id":"7d82082b872bcf1773221b3e1579fcc0eb1e185c","unresolved":false,"context_lines":[{"line_number":48,"context_line":"        status_data \u003d {"},{"line_number":49,"context_line":"            \u0027kafka\u0027: kafka_result.message,"},{"line_number":50,"context_line":"            \u0027relational_database\u0027: relational_db_result.message,"},{"line_number":51,"context_line":"            \u0027timestamp_database\u0027: timestamp_db_result.message"},{"line_number":52,"context_line":"        }"},{"line_number":53,"context_line":"        health \u003d (kafka_result.health and relational_db_result.health and"},{"line_number":54,"context_line":"                  timestamp_db_result.health)"}],"source_content_type":"text/x-python","patch_set":1,"id":"ff0f0b1f_733cf7c7","line":51,"range":{"start_line":51,"start_character":13,"end_line":51,"end_character":31},"in_reply_to":"ff0f0b1f_41a961dd","updated":"2017-05-19 11:07:18.000000000","message":"ok :) I will also change relational_database to alarms_database","commit_id":"2d244a0af4fc6854f34557b2dc4eaca984217d02"}],"monasca_api/tests/test_keystone_protocol.py":[{"author":{"_account_id":16168,"name":"Tomasz Trębski","email":"kornicameister@gmail.com","username":"trebskit"},"change_message_id":"2373471882577f17826d98cd12891431374a5dd0","unresolved":false,"context_lines":[{"line_number":17,"context_line":""},{"line_number":18,"context_line":"from monasca_api.healthcheck import keystone_protocol"},{"line_number":19,"context_line":""},{"line_number":20,"context_line":"_APP \u003d mock.Mock()"},{"line_number":21,"context_line":"_CONF \u003d {}"},{"line_number":22,"context_line":""},{"line_number":23,"context_line":""}],"source_content_type":"text/x-python","patch_set":11,"id":"ff0f0b1f_b9cd5886","line":20,"updated":"2017-05-24 05:22:13.000000000","message":"why mocks done here ?","commit_id":"15173e6b99c6a3627c43edd3d62caf80033918a6"},{"author":{"_account_id":20033,"name":"Artur Basiak","email":"artur.basiak@ts.fujitsu.com","username":"abasiak"},"change_message_id":"a03e5e7e057d8734eed2ccf249ce3b2099f855ce","unresolved":false,"context_lines":[{"line_number":17,"context_line":""},{"line_number":18,"context_line":"from monasca_api.healthcheck import keystone_protocol"},{"line_number":19,"context_line":""},{"line_number":20,"context_line":"_APP \u003d mock.Mock()"},{"line_number":21,"context_line":"_CONF \u003d {}"},{"line_number":22,"context_line":""},{"line_number":23,"context_line":""}],"source_content_type":"text/x-python","patch_set":11,"id":"ff0f0b1f_a35d1a7a","line":20,"in_reply_to":"ff0f0b1f_b9cd5886","updated":"2017-05-24 11:07:54.000000000","message":"Sorry this test was copied pasted from monasca-log-api:) Will fix it.","commit_id":"15173e6b99c6a3627c43edd3d62caf80033918a6"}],"monasca_api/tests/test_metrics_db_health_check.py":[{"author":{"_account_id":16168,"name":"Tomasz Trębski","email":"kornicameister@gmail.com","username":"trebskit"},"change_message_id":"a3ec3bc25121d02786e8879605d37f78bda74948","unresolved":false,"context_lines":[{"line_number":45,"context_line":"        db_health \u003d tdc.MetricsDbCheck()"},{"line_number":46,"context_line":""},{"line_number":47,"context_line":"        # check if influxdb is detected"},{"line_number":48,"context_line":"        self.assertEqual(\u0027influxdb\u0027, db_health._detected_database_type("},{"line_number":49,"context_line":"            \u0027influxdb.metrics_repository\u0027))"},{"line_number":50,"context_line":""},{"line_number":51,"context_line":"        # check if cassandra is detected"}],"source_content_type":"text/x-python","patch_set":17,"id":"df140735_c9eb3dae","line":48,"updated":"2017-05-30 04:41:36.000000000","message":"Such test should be splitted into 3 seperate cases.","commit_id":"9894e1b53ee8a4c40b9788196f2e66843cffb080"},{"author":{"_account_id":20033,"name":"Artur Basiak","email":"artur.basiak@ts.fujitsu.com","username":"abasiak"},"change_message_id":"52ee2b00aa3d9dd0dbdc10e88376a158d8e59e21","unresolved":false,"context_lines":[{"line_number":45,"context_line":"        db_health \u003d tdc.MetricsDbCheck()"},{"line_number":46,"context_line":""},{"line_number":47,"context_line":"        # check if influxdb is detected"},{"line_number":48,"context_line":"        self.assertEqual(\u0027influxdb\u0027, db_health._detected_database_type("},{"line_number":49,"context_line":"            \u0027influxdb.metrics_repository\u0027))"},{"line_number":50,"context_line":""},{"line_number":51,"context_line":"        # check if cassandra is detected"}],"source_content_type":"text/x-python","patch_set":17,"id":"df140735_0a1923d6","line":48,"in_reply_to":"df140735_c9eb3dae","updated":"2017-05-30 08:08:50.000000000","message":"Done","commit_id":"9894e1b53ee8a4c40b9788196f2e66843cffb080"}]}
