)]}'
{"/PATCHSET_LEVEL":[{"author":{"_account_id":1179,"name":"Clay Gerrard","email":"clay.gerrard@gmail.com","username":"clay-gerrard"},"change_message_id":"de8b38dfafd79f3c6dff7347140f95769e792f6f","unresolved":false,"context_lines":[],"source_content_type":"","patch_set":1,"id":"be1c9d91_0837aa1d","updated":"2022-05-17 14:41:17.000000000","message":"I\u0027m not sold on doing this as an optional dependency\n\nI could definately see thinking \"it\u0027s not worth it\"; but if we\u0027re gunna do it making it optional might be more friction - not sure what\u0027s the easiest way to get buy-in or what threshold we\u0027d need to cross for the benifit.\n\nAt some level I think: why would you NOT want setproctitle on your swift daemons!?\n\n... maybe we should support some sort of configurability in-case anyone is doing some sophisticated process life-cycle management; dunno - that might also be worse.","commit_id":"30ae33e777ebcda378257411ff8aae90803c09b4"},{"author":{"_account_id":15343,"name":"Tim Burke","email":"tburke@nvidia.com","username":"tburke"},"change_message_id":"b3727b7b774d9a997c315891da4769505b008322","unresolved":false,"context_lines":[],"source_content_type":"","patch_set":1,"id":"8fc6d622_696c5c36","updated":"2022-05-18 23:10:57.000000000","message":"Optional dep felt right to me -- it\u0027s not strictly necessary, just looking to add more value if we can. Honestly, it kind of bugs me that I can\u0027t stand up a single-replica swift without installing pyeclib and liberasurecode -- the latter requires that you either get a (likely fairly old?) version from system packages, or you install a whole build chain so you can build it from source.\n\nHonestly, that was a sizeable part of why I did https://review.opendev.org/c/openstack/pyeclib/+/817498 -- I want to be able to run `pip install swift` and get something that Just Works. I\u0027m pretty sure all our other deps offer manylinux wheels now.\n\nI debated about adding some config plumbing for it -- maybe something like\n\n set_worker_titles \u003d false\n\n? And then raise an exception if you set it true but don\u0027t have setproctitle installed.","commit_id":"30ae33e777ebcda378257411ff8aae90803c09b4"}],"swift/common/daemon.py":[{"author":{"_account_id":1179,"name":"Clay Gerrard","email":"clay.gerrard@gmail.com","username":"clay-gerrard"},"change_message_id":"de8b38dfafd79f3c6dff7347140f95769e792f6f","unresolved":true,"context_lines":[{"line_number":180,"context_line":"            stred_args \u003d \u0027, \u0027.join("},{"line_number":181,"context_line":"                \u0027%s\u003d%r\u0027 % (k, v) for k, v in kwargs.items()"},{"line_number":182,"context_line":"                if not isinstance(v, list) or v)"},{"line_number":183,"context_line":"            setproctitle(\u0027%s [%s]\u0027 % (getproctitle(), stred_args))"},{"line_number":184,"context_line":""},{"line_number":185,"context_line":"            self.daemon.run(once, **kwargs)"},{"line_number":186,"context_line":""}],"source_content_type":"text/x-python","patch_set":1,"id":"e5ea81fe_dbe90a67","line":183,"updated":"2022-05-17 14:41:17.000000000","message":"I think we could do a lot better than this:\n\nvagrant@saio:/vagrant/swift$ ps -ef | grep object-replicator\nvagrant    19363       1  4 14:34 ?        00:00:00 /usr/bin/python /usr/local/bin/swift-object-replicator /etc/swift/object-server/1.conf.d\nvagrant    19364       1  4 14:34 ?        00:00:00 /usr/bin/python /usr/local/bin/swift-object-replicator /etc/swift/object-server/2.conf.d\nvagrant    19365       1  4 14:34 ?        00:00:00 /usr/bin/python /usr/local/bin/swift-object-replicator /etc/swift/object-server/3.conf.d\nvagrant    19366       1  4 14:34 ?        00:00:00 /usr/bin/python /usr/local/bin/swift-object-replicator /etc/swift/object-server/4.conf.d\nvagrant    19387   19363  0 14:34 ?        00:00:00 /usr/bin/python /usr/local/bin/swift-object-replicator /etc/swift/object-server/1.conf.d [override_devices\u003d[\u0027sdb1\u0027], have_overrides\u003dFalse, multiprocess_worker_index\u003d0]\nvagrant    19388   19364  0 14:34 ?        00:00:00 /usr/bin/python /usr/local/bin/swift-object-replicator /etc/swift/object-server/2.conf.d [override_devices\u003d[\u0027sdb2\u0027], have_overrides\u003dFalse, multiprocess_worker_index\u003d0]\nvagrant    19389   19365  0 14:34 ?        00:00:00 /usr/bin/python /usr/local/bin/swift-object-replicator /etc/swift/object-server/3.conf.d [override_devices\u003d[\u0027sdb3\u0027], have_overrides\u003dFalse, multiprocess_worker_index\u003d0]\nvagrant    19390   19366  0 14:34 ?        00:00:00 /usr/bin/python /usr/local/bin/swift-object-replicator /etc/swift/object-server/4.conf.d [override_devices\u003d[\u0027sdb4\u0027], have_overrides\u003dFalse, multiprocess_worker_index\u003d0]\n\nthe \"have_overrides\" doesn\u0027t add much, and maybe the formatting of the worker index and devices listing could be easier to see at a glance","commit_id":"30ae33e777ebcda378257411ff8aae90803c09b4"},{"author":{"_account_id":15343,"name":"Tim Burke","email":"tburke@nvidia.com","username":"tburke"},"change_message_id":"b3727b7b774d9a997c315891da4769505b008322","unresolved":true,"context_lines":[{"line_number":180,"context_line":"            stred_args \u003d \u0027, \u0027.join("},{"line_number":181,"context_line":"                \u0027%s\u003d%r\u0027 % (k, v) for k, v in kwargs.items()"},{"line_number":182,"context_line":"                if not isinstance(v, list) or v)"},{"line_number":183,"context_line":"            setproctitle(\u0027%s [%s]\u0027 % (getproctitle(), stred_args))"},{"line_number":184,"context_line":""},{"line_number":185,"context_line":"            self.daemon.run(once, **kwargs)"},{"line_number":186,"context_line":""}],"source_content_type":"text/x-python","patch_set":1,"id":"a9eb0703_b3ff98e5","line":183,"in_reply_to":"e5ea81fe_dbe90a67","updated":"2022-05-18 23:10:57.000000000","message":"Not my fault we have some bad hygiene ;-)\n\nFWIW, I tried a couple other things to filter kwargs:\n\n if v\n\n* worked reasonably well, except it dropped worker_index\u003d0\n\n if v or v \u003d\u003d 0\n\n* includes have_overrides, as False \u003d\u003d 0\n\n if v or v is 0\n\n* works, but emits \u0027SyntaxWarning: \"is\" with a literal. Did you mean \"\u003d\u003d\"?\u0027\n\nArguably, override_devices is the only one we actually care about, but if we\u0027re going to extend this to things like the auditor (and I *do* want to do that), we don\u0027t really want to hardcode it as we want to distinguish the ZBF auditor.\n\nMaybe I should add a proc_title_for_worker_args() method to Daemon subclasses?","commit_id":"30ae33e777ebcda378257411ff8aae90803c09b4"}]}
