)]}'
{"doc/source/operation.rst":[{"author":{"_account_id":27582,"name":"Simon Westphahl","email":"simon.westphahl@bmw.de","username":"simon.westphahl"},"change_message_id":"ab843542d228d0f247e362756684202ca7fd44d2","unresolved":true,"context_lines":[{"line_number":497,"context_line":"   :type: gauge"},{"line_number":498,"context_line":""},{"line_number":499,"context_line":"   Number of manual build requests outstanding (does not include"},{"line_number":500,"context_line":"   currently running builds) for the specified image."},{"line_number":501,"context_line":""},{"line_number":502,"context_line":".. zuul:stat:: nodepool.builder.\u003chostname\u003e.current_builds"},{"line_number":503,"context_line":"   :type: gauge"}],"source_content_type":"text/x-rst","patch_set":1,"id":"0be64d4d_f1236b14","line":500,"updated":"2024-02-28 14:29:43.000000000","message":"This means this gauge will be either 0 or 1, right?","commit_id":"646b7f49279b89850aa95671f64ebbbf392fc1d2"},{"author":{"_account_id":1,"name":"James E. Blair","email":"jim@acmegating.com","username":"corvus"},"change_message_id":"e5a7837ecde29a3096a7bf29796c94b15ccd976e","unresolved":false,"context_lines":[{"line_number":497,"context_line":"   :type: gauge"},{"line_number":498,"context_line":""},{"line_number":499,"context_line":"   Number of manual build requests outstanding (does not include"},{"line_number":500,"context_line":"   currently running builds) for the specified image."},{"line_number":501,"context_line":""},{"line_number":502,"context_line":".. zuul:stat:: nodepool.builder.\u003chostname\u003e.current_builds"},{"line_number":503,"context_line":"   :type: gauge"}],"source_content_type":"text/x-rst","patch_set":1,"id":"2d78f689_bf39e3cb","line":500,"in_reply_to":"0be64d4d_f1236b14","updated":"2024-02-28 14:32:09.000000000","message":"Currently, yes.","commit_id":"646b7f49279b89850aa95671f64ebbbf392fc1d2"}],"nodepool/builder.py":[{"author":{"_account_id":27582,"name":"Simon Westphahl","email":"simon.westphahl@bmw.de","username":"simon.westphahl"},"change_message_id":"ab843542d228d0f247e362756684202ca7fd44d2","unresolved":true,"context_lines":[{"line_number":437,"context_line":"                        image_name, STATUS_IDLE),"},{"line_number":438,"context_line":"                    build_status)"},{"line_number":439,"context_line":"            key \u003d (f\u0027nodepool.builder.{self._hostname}.image.\u0027"},{"line_number":440,"context_line":"                   f\u0027{image_name}.build.state\u0027)"},{"line_number":441,"context_line":"            pipeline.gauge(key, build_status)"},{"line_number":442,"context_line":"            upload_status_by_provider \u003d {}"},{"line_number":443,"context_line":"            for upload_worker in self.builder._upload_workers:"}],"source_content_type":"text/x-python","patch_set":1,"id":"3c8b6de7_a52bd571","line":440,"updated":"2024-02-28 14:29:43.000000000","message":"Do we have to sanitize the image name here (no dots, spaces, ...) and also in other places where we use that in a metric?","commit_id":"646b7f49279b89850aa95671f64ebbbf392fc1d2"},{"author":{"_account_id":1,"name":"James E. Blair","email":"jim@acmegating.com","username":"corvus"},"change_message_id":"e5a7837ecde29a3096a7bf29796c94b15ccd976e","unresolved":false,"context_lines":[{"line_number":437,"context_line":"                        image_name, STATUS_IDLE),"},{"line_number":438,"context_line":"                    build_status)"},{"line_number":439,"context_line":"            key \u003d (f\u0027nodepool.builder.{self._hostname}.image.\u0027"},{"line_number":440,"context_line":"                   f\u0027{image_name}.build.state\u0027)"},{"line_number":441,"context_line":"            pipeline.gauge(key, build_status)"},{"line_number":442,"context_line":"            upload_status_by_provider \u003d {}"},{"line_number":443,"context_line":"            for upload_worker in self.builder._upload_workers:"}],"source_content_type":"text/x-python","patch_set":1,"id":"d15771bb_2dae3420","line":440,"in_reply_to":"3c8b6de7_a52bd571","updated":"2024-02-28 14:32:09.000000000","message":"That is something to consider, but since we don\u0027t in similar places, I don\u0027t think we should here. Strictly speaking, including dots isn\u0027t terrible, just weird.  The rest get translated by statsd anyway.","commit_id":"646b7f49279b89850aa95671f64ebbbf392fc1d2"},{"author":{"_account_id":27582,"name":"Simon Westphahl","email":"simon.westphahl@bmw.de","username":"simon.westphahl"},"change_message_id":"f7f77438019f92a73e7a034e896def5b239da666","unresolved":true,"context_lines":[{"line_number":706,"context_line":"        \u0027\u0027\u0027"},{"line_number":707,"context_line":"        # Check if diskimage builds are paused."},{"line_number":708,"context_line":"        if diskimage.pause:"},{"line_number":709,"context_line":"            self._image_status[diskimage.name] \u003d STATUS_PAUSED"},{"line_number":710,"context_line":"            return"},{"line_number":711,"context_line":"        if self._zk.getImagePaused(diskimage.name):"},{"line_number":712,"context_line":"            self._image_status[diskimage.name] \u003d STATUS_PAUSED"}],"source_content_type":"text/x-python","patch_set":1,"id":"a4461eba_3d1e2d36","line":709,"updated":"2024-02-28 14:36:15.000000000","message":"Could we end up publishing stale metrics when all the upload and build workers are busy?","commit_id":"646b7f49279b89850aa95671f64ebbbf392fc1d2"},{"author":{"_account_id":1,"name":"James E. Blair","email":"jim@acmegating.com","username":"corvus"},"change_message_id":"83feaca2d7934462cc28e1df6c786ba2bb3d1ef2","unresolved":false,"context_lines":[{"line_number":706,"context_line":"        \u0027\u0027\u0027"},{"line_number":707,"context_line":"        # Check if diskimage builds are paused."},{"line_number":708,"context_line":"        if diskimage.pause:"},{"line_number":709,"context_line":"            self._image_status[diskimage.name] \u003d STATUS_PAUSED"},{"line_number":710,"context_line":"            return"},{"line_number":711,"context_line":"        if self._zk.getImagePaused(diskimage.name):"},{"line_number":712,"context_line":"            self._image_status[diskimage.name] \u003d STATUS_PAUSED"}],"source_content_type":"text/x-python","patch_set":1,"id":"a27ca532_e1b4f968","line":709,"in_reply_to":"a4461eba_3d1e2d36","updated":"2024-02-28 14:42:04.000000000","message":"Yes, but the metrics are from the perspective of the individual builder, so that kind of makes sense.  If we don\u0027t like that, we could move the paused check out of this thread and into the cleanup thread; or we could drop it and just have idle/building.","commit_id":"646b7f49279b89850aa95671f64ebbbf392fc1d2"},{"author":{"_account_id":4146,"name":"Clark Boylan","email":"cboylan@sapwetik.org","username":"cboylan"},"change_message_id":"f505c9e7cd43526231461d3bc1812d2807e974e4","unresolved":true,"context_lines":[{"line_number":709,"context_line":"            self._image_status[diskimage.name] \u003d STATUS_PAUSED"},{"line_number":710,"context_line":"            return"},{"line_number":711,"context_line":"        if self._zk.getImagePaused(diskimage.name):"},{"line_number":712,"context_line":"            self._image_status[diskimage.name] \u003d STATUS_PAUSED"},{"line_number":713,"context_line":"            return"},{"line_number":714,"context_line":""},{"line_number":715,"context_line":"        self._image_status[diskimage.name] \u003d STATUS_IDLE"}],"source_content_type":"text/x-python","patch_set":1,"id":"a09af42f_79c9d4c3","line":712,"updated":"2024-03-07 19:08:52.000000000","message":"We access _image_status for upload workers when reporting in the cleanup method this way:\n\n```\nupload_worker._image_status.get(image_name, {}).items()\n```\n\nHere in the build worker we have a different type for _image_status which is to just assign constant integer values rather than dicts to the keys. Personally I find this mismatch a bit confusing particularly since the attribute name is the same and is initialized in the base class. Maybe use two different keys initialized in the appropriate worker to make this more clear or use a consistent type?","commit_id":"646b7f49279b89850aa95671f64ebbbf392fc1d2"},{"author":{"_account_id":1,"name":"James E. Blair","email":"jim@acmegating.com","username":"corvus"},"change_message_id":"33404b592a7ba6c7cfe7267c90d0a9c6d4b57be3","unresolved":false,"context_lines":[{"line_number":709,"context_line":"            self._image_status[diskimage.name] \u003d STATUS_PAUSED"},{"line_number":710,"context_line":"            return"},{"line_number":711,"context_line":"        if self._zk.getImagePaused(diskimage.name):"},{"line_number":712,"context_line":"            self._image_status[diskimage.name] \u003d STATUS_PAUSED"},{"line_number":713,"context_line":"            return"},{"line_number":714,"context_line":""},{"line_number":715,"context_line":"        self._image_status[diskimage.name] \u003d STATUS_IDLE"}],"source_content_type":"text/x-python","patch_set":1,"id":"01657d80_8bca34d6","line":712,"in_reply_to":"a09af42f_79c9d4c3","updated":"2024-03-07 19:46:00.000000000","message":"True, and distinct variable names probably would have been a good idea in retrospect.  But I think this probably looks more confusing in review than in the code; the two classes handle images differently enough that it wasn\u0027t confusing when working on it.  My line of thinking at the time was: They both have an image status, but each just has a different data format for the value.","commit_id":"646b7f49279b89850aa95671f64ebbbf392fc1d2"},{"author":{"_account_id":1,"name":"James E. Blair","email":"jim@acmegating.com","username":"corvus"},"change_message_id":"33404b592a7ba6c7cfe7267c90d0a9c6d4b57be3","unresolved":false,"context_lines":[{"line_number":709,"context_line":"            self._image_status[diskimage.name] \u003d STATUS_PAUSED"},{"line_number":710,"context_line":"            return"},{"line_number":711,"context_line":"        if self._zk.getImagePaused(diskimage.name):"},{"line_number":712,"context_line":"            self._image_status[diskimage.name] \u003d STATUS_PAUSED"},{"line_number":713,"context_line":"            return"},{"line_number":714,"context_line":""},{"line_number":715,"context_line":"        self._image_status[diskimage.name] \u003d STATUS_IDLE"}],"source_content_type":"text/x-python","patch_set":1,"id":"1c607097_37ccfee6","line":712,"in_reply_to":"a09af42f_79c9d4c3","updated":"2024-03-07 19:46:00.000000000","message":"True, and distinct variable names probably would have been a good idea in retrospect.  But I think this probably looks more confusing in review than in the code; the two classes handle images differently enough that it wasn\u0027t confusing when working on it.  My line of thinking at the time was: They both have an image status, but each just has a different data format for the value.","commit_id":"646b7f49279b89850aa95671f64ebbbf392fc1d2"},{"author":{"_account_id":1,"name":"James E. Blair","email":"jim@acmegating.com","username":"corvus"},"change_message_id":"33404b592a7ba6c7cfe7267c90d0a9c6d4b57be3","unresolved":false,"context_lines":[{"line_number":709,"context_line":"            self._image_status[diskimage.name] \u003d STATUS_PAUSED"},{"line_number":710,"context_line":"            return"},{"line_number":711,"context_line":"        if self._zk.getImagePaused(diskimage.name):"},{"line_number":712,"context_line":"            self._image_status[diskimage.name] \u003d STATUS_PAUSED"},{"line_number":713,"context_line":"            return"},{"line_number":714,"context_line":""},{"line_number":715,"context_line":"        self._image_status[diskimage.name] \u003d STATUS_IDLE"}],"source_content_type":"text/x-python","patch_set":1,"id":"4a31d33e_1fb9527d","line":712,"in_reply_to":"a09af42f_79c9d4c3","updated":"2024-03-07 19:46:00.000000000","message":"True, and distinct variable names probably would have been a good idea in retrospect.  But I think this probably looks more confusing in review than in the code; the two classes handle images differently enough that it wasn\u0027t confusing when working on it.  My line of thinking at the time was: They both have an image status, but each just has a different data format for the value.","commit_id":"646b7f49279b89850aa95671f64ebbbf392fc1d2"},{"author":{"_account_id":4146,"name":"Clark Boylan","email":"cboylan@sapwetik.org","username":"cboylan"},"change_message_id":"c074b5279fac9e41b0678ff2deafb46992a640ee","unresolved":true,"context_lines":[{"line_number":709,"context_line":"            self._image_status[diskimage.name] \u003d STATUS_PAUSED"},{"line_number":710,"context_line":"            return"},{"line_number":711,"context_line":"        if self._zk.getImagePaused(diskimage.name):"},{"line_number":712,"context_line":"            self._image_status[diskimage.name] \u003d STATUS_PAUSED"},{"line_number":713,"context_line":"            return"},{"line_number":714,"context_line":""},{"line_number":715,"context_line":"        self._image_status[diskimage.name] \u003d STATUS_IDLE"}],"source_content_type":"text/x-python","patch_set":1,"id":"5fdb4624_3a5cdaeb","line":712,"in_reply_to":"a09af42f_79c9d4c3","updated":"2024-03-07 19:45:32.000000000","message":"We discussed this really quickly and decided it isn\u0027t worth the churn and effort to rewrite this change. But something to try and be aware of in the future.","commit_id":"646b7f49279b89850aa95671f64ebbbf392fc1d2"}]}
