)]}'
{"/PATCHSET_LEVEL":[{"author":{"_account_id":30695,"name":"Pedro Henrique Pereira Martins","email":"phpm13@gmail.com","username":"pedrohpmartins"},"change_message_id":"c39fb565463940885b544528df60e45e157d323b","unresolved":false,"context_lines":[],"source_content_type":"","patch_set":1,"id":"0463e506_6402c183","updated":"2024-03-25 20:28:10.000000000","message":"Hi Rafael, thanks for this patch, it seems a good improvement allowing to multi-threading the polling process. The code seems good to me.","commit_id":"068ea6b0f770a0afe499afda89bab94c52469508"},{"author":{"_account_id":28356,"name":"Rafael Weingartner","email":"rafael@apache.org","username":"rafaelweingartner"},"change_message_id":"f833e03c6e600e369694e6213854d0270bd29357","unresolved":false,"context_lines":[],"source_content_type":"","patch_set":1,"id":"4b8f556a_b1264d59","in_reply_to":"0463e506_6402c183","updated":"2024-03-25 20:32:46.000000000","message":"Thanks!\n\nI fixed some typos in the latest patch.","commit_id":"068ea6b0f770a0afe499afda89bab94c52469508"},{"author":{"_account_id":32240,"name":"Yadnesh Kulkarni","email":"yadnesh_kulkarni@proton.me","username":"ykulkarn"},"change_message_id":"11f87e958825e5bd3439daaa59525869f2b61e84","unresolved":false,"context_lines":[],"source_content_type":"","patch_set":2,"id":"b455bda5_ef6534df","updated":"2024-04-12 12:26:20.000000000","message":"While trying out this patch, I observed a race condition\n```\nApr 12 08:25:52 devstack ceilometer-polling[657527]: 2024-04-12 08:25:52.843 657527 ERROR futurist.periodics AttributeError: \u0027_thread._local\u0027 object has no attribute \u0027hub\u0027\n.\n.\n.\nApr 12 08:25:37 devstack ceilometer-polling[657527]: 2024-04-12 08:25:37.836 657527 ERROR futurist.periodics OSError: [Errno 24] Too many open files\n```","commit_id":"b3456f928b2c0ba399d74af6dad29d61ac49dc0d"},{"author":{"_account_id":32240,"name":"Yadnesh Kulkarni","email":"yadnesh_kulkarni@proton.me","username":"ykulkarn"},"change_message_id":"a415ab9cf612ebee67dc9c9491da0216141ec58e","unresolved":false,"context_lines":[],"source_content_type":"","patch_set":2,"id":"68a82f8d_b9244a1e","in_reply_to":"1eefa3bc_6ce4d8d3","updated":"2024-04-16 05:02:10.000000000","message":"I am testing in centos9 vm with 4 cpus and I still see the same behaviour with threads count equal to number of cpus.\n```\n$ lscpu | grep \u0027CPU(s):\u0027\nCPU(s):     4\n\n[polling]\nthreads_to_process_pollsters\u003d2\ntenant_name_discovery\u003dtrue\n```","commit_id":"b3456f928b2c0ba399d74af6dad29d61ac49dc0d"},{"author":{"_account_id":28356,"name":"Rafael Weingartner","email":"rafael@apache.org","username":"rafaelweingartner"},"change_message_id":"cd2a2c1eabc447dd343f19849a75565e97d1406d","unresolved":false,"context_lines":[],"source_content_type":"","patch_set":2,"id":"75b1000a_d7c78794","in_reply_to":"68a82f8d_b9244a1e","updated":"2024-04-16 11:36:36.000000000","message":"It is funny, I tested with a containerized setup using Ubuntu containers and I do not see any issues such as the one you mentioned.","commit_id":"b3456f928b2c0ba399d74af6dad29d61ac49dc0d"},{"author":{"_account_id":32240,"name":"Yadnesh Kulkarni","email":"yadnesh_kulkarni@proton.me","username":"ykulkarn"},"change_message_id":"1ce96fbf94b7a550d7daa6bb1f67e2c2b3c7ac87","unresolved":false,"context_lines":[],"source_content_type":"","patch_set":2,"id":"c8199908_908c90eb","in_reply_to":"b455bda5_ef6534df","updated":"2024-04-12 12:26:58.000000000","message":"I set this is ceilometer.conf while testing\n```\n[polling]\nthreads_to_process_pollsters\u003d0\n```","commit_id":"b3456f928b2c0ba399d74af6dad29d61ac49dc0d"},{"author":{"_account_id":28356,"name":"Rafael Weingartner","email":"rafael@apache.org","username":"rafaelweingartner"},"change_message_id":"e5c7f4e8992a28639ebb5faa2cfbb641da3b9327","unresolved":false,"context_lines":[],"source_content_type":"","patch_set":2,"id":"1eefa3bc_6ce4d8d3","in_reply_to":"c8199908_908c90eb","updated":"2024-04-12 12:29:44.000000000","message":"This might be an issue as a lot of threads would be used, even when you have just a few CPUs. Can you try with a number that is equals to the number of CPUs that you have?","commit_id":"b3456f928b2c0ba399d74af6dad29d61ac49dc0d"},{"author":{"_account_id":5241,"name":"Martin Magr","email":"mmagr@redhat.com","username":"mmagr"},"change_message_id":"95ef47b3c86514ce366030e1840ca23290788453","unresolved":false,"context_lines":[],"source_content_type":"","patch_set":3,"id":"fdf275d3_19913c51","updated":"2025-06-10 13:01:27.000000000","message":"First of all sorry for keeping this review open for such a long time. I\u0027m not sure how this got under the radar that deep. There has been a concern how the prometheus exporter feature will behave with this patch.\n\nI\u0027ll deploy a stack and do some tests regarding the feature throughout this week.","commit_id":"ee132c6362298330392fbadff71427427a8ab301"},{"author":{"_account_id":28356,"name":"Rafael Weingartner","email":"rafael@apache.org","username":"rafaelweingartner"},"change_message_id":"b3debd332e35a709ec59162829af56f468ed026c","unresolved":false,"context_lines":[],"source_content_type":"","patch_set":3,"id":"6eae1bc9_48731b45","updated":"2024-06-06 20:53:41.000000000","message":"Hello guys, \nwhat about this one? Can we merge it?","commit_id":"ee132c6362298330392fbadff71427427a8ab301"},{"author":{"_account_id":28356,"name":"Rafael Weingartner","email":"rafael@apache.org","username":"rafaelweingartner"},"change_message_id":"3f89e2afaa7ddcea1cd08ae0afa120ebea9a49e0","unresolved":false,"context_lines":[],"source_content_type":"","patch_set":3,"id":"ce1eb378_5c25f354","updated":"2024-06-06 20:53:28.000000000","message":"Hello guys, \nwhat about this one? Can we merge it?","commit_id":"ee132c6362298330392fbadff71427427a8ab301"},{"author":{"_account_id":5241,"name":"Martin Magr","email":"mmagr@redhat.com","username":"mmagr"},"change_message_id":"b0ad017cff866c3474ca38e1e5b6af60a078692a","unresolved":false,"context_lines":[],"source_content_type":"","patch_set":3,"id":"9e22ac27_a4f8de03","in_reply_to":"00a4c53c_b2ffd19d","updated":"2025-06-12 09:45:43.000000000","message":"If you need this feature, then yes we can work on get it merged. Just make sure during the rebase that prometheus exporter feature stays functional as Juan suggested.","commit_id":"ee132c6362298330392fbadff71427427a8ab301"},{"author":{"_account_id":32968,"name":"Juan Larriba","email":"jlarriba@redhat.com","username":"jlarriba"},"change_message_id":"7a5be890ea5c868c3b6fa98fe839e15c2bf46f60","unresolved":false,"context_lines":[],"source_content_type":"","patch_set":3,"id":"00a4c53c_b2ffd19d","in_reply_to":"2cfd735b_2df1bdfe","updated":"2025-06-10 14:30:46.000000000","message":"If you work on rebasing it, take in account that the poller now opens a Prometheus Exporter that exposes all the metrics and that likely will need to change if there are multiple threads polling at the same time.","commit_id":"ee132c6362298330392fbadff71427427a8ab301"},{"author":{"_account_id":28356,"name":"Rafael Weingartner","email":"rafael@apache.org","username":"rafaelweingartner"},"change_message_id":"a17be2ab887086df38321937e1248ab706c8f30f","unresolved":false,"context_lines":[],"source_content_type":"","patch_set":3,"id":"5b69bda3_63c7e075","in_reply_to":"9e22ac27_a4f8de03","updated":"2025-06-21 00:00:04.000000000","message":"I did the rebase. The default behavior is one thread. Therefore, it will not have an impact in the Prometheus integration. Moreover, I see what you guys did. You created a way to avoid using \"ceilometer-notification\" and send metrics directly to the backend when using Prometheus. \n\nCan you guys review and provide your feedback? If there is anything missing here. Please let me know. Then we can work together to get this one merged.","commit_id":"ee132c6362298330392fbadff71427427a8ab301"},{"author":{"_account_id":28356,"name":"Rafael Weingartner","email":"rafael@apache.org","username":"rafaelweingartner"},"change_message_id":"66c9dc05d49c6edcc327b787753a574862cd9f7f","unresolved":false,"context_lines":[],"source_content_type":"","patch_set":3,"id":"2cfd735b_2df1bdfe","in_reply_to":"fdf275d3_19913c51","updated":"2025-06-10 13:21:37.000000000","message":"No worries. I need to rebase this one. If you are willing to get this one moving. Let me know. Then, I can fix the conflicts and prepare this one to get it merged.","commit_id":"ee132c6362298330392fbadff71427427a8ab301"},{"author":{"_account_id":5241,"name":"Martin Magr","email":"mmagr@redhat.com","username":"mmagr"},"change_message_id":"7bf81a957d8f0f41c7d8a83f4dff553e1f04497b","unresolved":false,"context_lines":[],"source_content_type":"","patch_set":6,"id":"3fea5e20_e828bb81","updated":"2025-06-23 10:19:59.000000000","message":"Hi Rafael, I was out till today. Will check the patch and run the tests.","commit_id":"540f6e36427b0c2ce2c5ae2b083f91a6246cb4e7"},{"author":{"_account_id":4264,"name":"Matthias Runge","email":"mrunge@redhat.com","username":"mrunge"},"change_message_id":"7013f5748a2c3fb05f3794ebfa308c7d5d9ca095","unresolved":false,"context_lines":[],"source_content_type":"","patch_set":6,"id":"1827968a_2161c955","updated":"2025-07-01 14:49:47.000000000","message":"Martin, do you have updates to share on this?","commit_id":"540f6e36427b0c2ce2c5ae2b083f91a6246cb4e7"},{"author":{"_account_id":5241,"name":"Martin Magr","email":"mmagr@redhat.com","username":"mmagr"},"change_message_id":"1a16797c231086281718253b503134ed62646273","unresolved":false,"context_lines":[],"source_content_type":"","patch_set":6,"id":"c3250837_c961aa18","updated":"2025-07-02 21:06:47.000000000","message":"Sorry for the delay. I wanted how the prometheus exporter feature will behave with multiple threads enabled. If I did not miss something the concern of the metric duplication did not happen during my manual testing, so I\u0027m +1 for this change.","commit_id":"540f6e36427b0c2ce2c5ae2b083f91a6246cb4e7"},{"author":{"_account_id":28356,"name":"Rafael Weingartner","email":"rafael@apache.org","username":"rafaelweingartner"},"change_message_id":"179752d61bc405fe2a67e4c0d6ed04e1409d9cdc","unresolved":false,"context_lines":[],"source_content_type":"","patch_set":6,"id":"34145913_4b87468d","in_reply_to":"1827968a_2161c955","updated":"2025-07-02 16:49:19.000000000","message":"If there is anything else, please let me know.","commit_id":"540f6e36427b0c2ce2c5ae2b083f91a6246cb4e7"},{"author":{"_account_id":28356,"name":"Rafael Weingartner","email":"rafael@apache.org","username":"rafaelweingartner"},"change_message_id":"ec7db1f7232b000b2eb9755b3960b5dd98bdaa2e","unresolved":false,"context_lines":[],"source_content_type":"","patch_set":6,"id":"3c37a3ad_e2c692dc","in_reply_to":"3fea5e20_e828bb81","updated":"2025-06-23 11:20:46.000000000","message":"Ok, thanks!","commit_id":"540f6e36427b0c2ce2c5ae2b083f91a6246cb4e7"},{"author":{"_account_id":4264,"name":"Matthias Runge","email":"mrunge@redhat.com","username":"mrunge"},"change_message_id":"72b4fa0cd311fac5b681f0180c8031d534c4bd47","unresolved":false,"context_lines":[],"source_content_type":"","patch_set":8,"id":"c58dba6a_89ad6c57","updated":"2025-07-04 06:39:37.000000000","message":"Thank you!","commit_id":"492974dd0b4c5666defe2398e95d80aa325e3d0c"}],"ceilometer/polling/manager.py":[{"author":{"_account_id":32240,"name":"Yadnesh Kulkarni","email":"yadnesh_kulkarni@proton.me","username":"ykulkarn"},"change_message_id":"a415ab9cf612ebee67dc9c9491da0216141ec58e","unresolved":true,"context_lines":[{"line_number":225,"context_line":"                                    poll_history, pollster, source_name):"},{"line_number":226,"context_line":"        LOG.debug(\"Registering pollster [%s] from source [%s] to be executed \""},{"line_number":227,"context_line":"                  \"via executor [%s] with cache [%s], pollster history [%s], \""},{"line_number":228,"context_line":"                  \"and discovery cache [%s].\", pollster, source_name, executor,"},{"line_number":229,"context_line":"                  cache, poll_history, discovery_cache)"},{"line_number":230,"context_line":""},{"line_number":231,"context_line":"        def _internal_function():"}],"source_content_type":"text/x-python","patch_set":2,"id":"4eb9b2e5_260c9cc3","line":228,"updated":"2024-04-16 05:02:10.000000000","message":"Here as well, log pollster.name and drop [] brackets.","commit_id":"b3456f928b2c0ba399d74af6dad29d61ac49dc0d"},{"author":{"_account_id":28356,"name":"Rafael Weingartner","email":"rafael@apache.org","username":"rafaelweingartner"},"change_message_id":"9dee3a42c6745b4ed712de46e818bce96a347a1c","unresolved":false,"context_lines":[{"line_number":225,"context_line":"                                    poll_history, pollster, source_name):"},{"line_number":226,"context_line":"        LOG.debug(\"Registering pollster [%s] from source [%s] to be executed \""},{"line_number":227,"context_line":"                  \"via executor [%s] with cache [%s], pollster history [%s], \""},{"line_number":228,"context_line":"                  \"and discovery cache [%s].\", pollster, source_name, executor,"},{"line_number":229,"context_line":"                  cache, poll_history, discovery_cache)"},{"line_number":230,"context_line":""},{"line_number":231,"context_line":"        def _internal_function():"}],"source_content_type":"text/x-python","patch_set":2,"id":"0955ff23_7977e58a","line":228,"in_reply_to":"4d6f6c62_5daaab74","updated":"2025-06-20 17:34:45.000000000","message":"Done","commit_id":"b3456f928b2c0ba399d74af6dad29d61ac49dc0d"},{"author":{"_account_id":28356,"name":"Rafael Weingartner","email":"rafael@apache.org","username":"rafaelweingartner"},"change_message_id":"cd2a2c1eabc447dd343f19849a75565e97d1406d","unresolved":true,"context_lines":[{"line_number":225,"context_line":"                                    poll_history, pollster, source_name):"},{"line_number":226,"context_line":"        LOG.debug(\"Registering pollster [%s] from source [%s] to be executed \""},{"line_number":227,"context_line":"                  \"via executor [%s] with cache [%s], pollster history [%s], \""},{"line_number":228,"context_line":"                  \"and discovery cache [%s].\", pollster, source_name, executor,"},{"line_number":229,"context_line":"                  cache, poll_history, discovery_cache)"},{"line_number":230,"context_line":""},{"line_number":231,"context_line":"        def _internal_function():"}],"source_content_type":"text/x-python","patch_set":2,"id":"4d6f6c62_5daaab74","line":228,"in_reply_to":"4eb9b2e5_260c9cc3","updated":"2024-04-16 11:36:36.000000000","message":"I do prefer using the ``[]`` because when looking at the logs, it allows operators and developers to identify what is a parameter in the log message. Therefore, this facilitates for somebody to find the place in the code where the log message is generated.","commit_id":"b3456f928b2c0ba399d74af6dad29d61ac49dc0d"},{"author":{"_account_id":32240,"name":"Yadnesh Kulkarni","email":"yadnesh_kulkarni@proton.me","username":"ykulkarn"},"change_message_id":"a415ab9cf612ebee67dc9c9491da0216141ec58e","unresolved":true,"context_lines":[{"line_number":231,"context_line":"        def _internal_function():"},{"line_number":232,"context_line":"            self._internal_pollster_run(cache, discovery_cache, poll_history,"},{"line_number":233,"context_line":"                                        pollster, source_name)"},{"line_number":234,"context_line":"            return \"Finished processing pollster [%s].\" % pollster"},{"line_number":235,"context_line":""},{"line_number":236,"context_line":"        return executor.submit(_internal_function)"},{"line_number":237,"context_line":""}],"source_content_type":"text/x-python","patch_set":2,"id":"1a7d709b_2980bb57","line":234,"updated":"2024-04-16 05:02:10.000000000","message":"Right now this gets logged as \n```\nFinished processing pollster [\u003cstevedore.extension.Extension object at 0x7f134dc1d040\u003e]\n```\n\nCan you log `pollster.name` instead of `pollster` which will \n```\nFinished processing pollster [disk.device.capacity]\n```\n\nHow about if we drop the [] brackets around pollster names. We log pollster names a few other places as well and they don\u0027t have brackets. I think it would look better if we render those kind of logs the same.","commit_id":"b3456f928b2c0ba399d74af6dad29d61ac49dc0d"},{"author":{"_account_id":28356,"name":"Rafael Weingartner","email":"rafael@apache.org","username":"rafaelweingartner"},"change_message_id":"9dee3a42c6745b4ed712de46e818bce96a347a1c","unresolved":false,"context_lines":[{"line_number":231,"context_line":"        def _internal_function():"},{"line_number":232,"context_line":"            self._internal_pollster_run(cache, discovery_cache, poll_history,"},{"line_number":233,"context_line":"                                        pollster, source_name)"},{"line_number":234,"context_line":"            return \"Finished processing pollster [%s].\" % pollster"},{"line_number":235,"context_line":""},{"line_number":236,"context_line":"        return executor.submit(_internal_function)"},{"line_number":237,"context_line":""}],"source_content_type":"text/x-python","patch_set":2,"id":"bef07583_674e9270","line":234,"in_reply_to":"0a766774_0d60481c","updated":"2025-06-20 17:34:45.000000000","message":"Done","commit_id":"b3456f928b2c0ba399d74af6dad29d61ac49dc0d"},{"author":{"_account_id":28356,"name":"Rafael Weingartner","email":"rafael@apache.org","username":"rafaelweingartner"},"change_message_id":"cd2a2c1eabc447dd343f19849a75565e97d1406d","unresolved":true,"context_lines":[{"line_number":231,"context_line":"        def _internal_function():"},{"line_number":232,"context_line":"            self._internal_pollster_run(cache, discovery_cache, poll_history,"},{"line_number":233,"context_line":"                                        pollster, source_name)"},{"line_number":234,"context_line":"            return \"Finished processing pollster [%s].\" % pollster"},{"line_number":235,"context_line":""},{"line_number":236,"context_line":"        return executor.submit(_internal_function)"},{"line_number":237,"context_line":""}],"source_content_type":"text/x-python","patch_set":2,"id":"0a766774_0d60481c","line":234,"in_reply_to":"1a7d709b_2980bb57","updated":"2024-04-16 11:36:36.000000000","message":"I changed to name here as well. Thanks for the suggestion. \n\nRegarding the use of ``[]``, I have explained in the previous comment why I tend to use them. If this is a no go just because of them, I can remove though.","commit_id":"b3456f928b2c0ba399d74af6dad29d61ac49dc0d"}],"ceilometer/tests/unit/polling/test_manager.py":[{"author":{"_account_id":32968,"name":"Juan Larriba","email":"jlarriba@redhat.com","username":"jlarriba"},"change_message_id":"c915858521e40028235f677de320e9f64b325c74","unresolved":true,"context_lines":[{"line_number":688,"context_line":"        ])"},{"line_number":689,"context_line":""},{"line_number":690,"context_line":"    @mock.patch(\u0027ceilometer.polling.manager.LOG\u0027)"},{"line_number":691,"context_line":"    def test_skip_polling_and_notify_with_no_resources(self, LOG):"},{"line_number":692,"context_line":"        self.polling_cfg[\u0027sources\u0027][0][\u0027resources\u0027] \u003d []"},{"line_number":693,"context_line":"        self.setup_polling()"},{"line_number":694,"context_line":"        polling_task \u003d list(self.mgr.setup_polling_tasks().values())[0]"}],"source_content_type":"text/x-python","patch_set":6,"id":"b02bcb5a_f023a19b","line":691,"updated":"2025-07-03 07:12:57.000000000","message":"I see that the usage of multiple pollsters is optional, which is awesome. However, I fail to see any test that performs a poll with multiple threads enabled.\n\nCould we have a test that enables 3 pollsters and check that the expected result is the same as we get with 1 pollster enabled?","commit_id":"540f6e36427b0c2ce2c5ae2b083f91a6246cb4e7"},{"author":{"_account_id":28356,"name":"Rafael Weingartner","email":"rafael@apache.org","username":"rafaelweingartner"},"change_message_id":"23bc9581da087689b3ecb5ed4dc18af2204ef938","unresolved":false,"context_lines":[{"line_number":688,"context_line":"        ])"},{"line_number":689,"context_line":""},{"line_number":690,"context_line":"    @mock.patch(\u0027ceilometer.polling.manager.LOG\u0027)"},{"line_number":691,"context_line":"    def test_skip_polling_and_notify_with_no_resources(self, LOG):"},{"line_number":692,"context_line":"        self.polling_cfg[\u0027sources\u0027][0][\u0027resources\u0027] \u003d []"},{"line_number":693,"context_line":"        self.setup_polling()"},{"line_number":694,"context_line":"        polling_task \u003d list(self.mgr.setup_polling_tasks().values())[0]"}],"source_content_type":"text/x-python","patch_set":6,"id":"99b00f9f_cc12344d","line":691,"in_reply_to":"b02bcb5a_f023a19b","updated":"2025-07-03 14:17:04.000000000","message":"Done","commit_id":"540f6e36427b0c2ce2c5ae2b083f91a6246cb4e7"}]}
