)]}'
{"/COMMIT_MSG":[{"author":{"_account_id":7730,"name":"Sahid Orentino Ferdjaoui","email":"sahid.ferdjaoui@industrialdiscipline.com","username":"sahid"},"change_message_id":"3745ac6da8fe93d38d2f55d93955d017a2c89a66","unresolved":false,"context_lines":[{"line_number":10,"context_line":"to liguestfs, there is no smart discovery of the system partition."},{"line_number":11,"context_line":"Thus we offer the possibility to specify the system"},{"line_number":12,"context_line":"partition number through a glance image property called inject_partition"},{"line_number":13,"context_line":""},{"line_number":14,"context_line":"Change-Id: I12cdaea31efd55c4ae0826a7ee54b73d746e8d3e"}],"source_content_type":"text/x-gerrit-commit-message","patch_set":4,"id":"ba7be1f8_f1712845","line":13,"updated":"2015-02-23 14:42:29.000000000","message":"We probably want at least a bug reported here to reference that feature as documentation.","commit_id":"ccd0aef3bd6245dd6c4ed92a760a96f33b704263"},{"author":{"_account_id":15064,"name":"raphael.glon","email":"raphael.glon@corp.ovh.com","username":"raphael"},"change_message_id":"30925bee7dd5cda51ccf92c7bc31a93798411f72","unresolved":false,"context_lines":[{"line_number":10,"context_line":"to liguestfs, there is no smart discovery of the system partition."},{"line_number":11,"context_line":"Thus we offer the possibility to specify the system"},{"line_number":12,"context_line":"partition number through a glance image property called inject_partition"},{"line_number":13,"context_line":""},{"line_number":14,"context_line":"Change-Id: I12cdaea31efd55c4ae0826a7ee54b73d746e8d3e"}],"source_content_type":"text/x-gerrit-commit-message","patch_set":4,"id":"ba7be1f8_a2a56f48","line":13,"in_reply_to":"ba7be1f8_f1712845","updated":"2015-02-24 15:32:22.000000000","message":"done... not sure of the way it is formatted though","commit_id":"ccd0aef3bd6245dd6c4ed92a760a96f33b704263"},{"author":{"_account_id":7730,"name":"Sahid Orentino Ferdjaoui","email":"sahid.ferdjaoui@industrialdiscipline.com","username":"sahid"},"change_message_id":"d3b3ac9af7015608a68e8034907415312dd6adc9","unresolved":false,"context_lines":[{"line_number":11,"context_line":"Thus we offer the possibility to specify the system"},{"line_number":12,"context_line":"partition number through a glance image property called inject_partition"},{"line_number":13,"context_line":""},{"line_number":14,"context_line":"Implements: https://blueprints.launchpad.net/nova/+spec/custom-inject-partition"},{"line_number":15,"context_line":"Change-Id: I12cdaea31efd55c4ae0826a7ee54b73d746e8d3e"}],"source_content_type":"text/x-gerrit-commit-message","patch_set":6,"id":"ba7be1f8_e9190ad8","line":14,"updated":"2015-02-24 16:58:09.000000000","message":"Implements: blueprint custom-inject-partition\n\nA DocImpact tag is also needed here with explanation of the changes you have done in the config.","commit_id":"15d16ae4775d5cd17c28ce22c2ca1c02e15bc682"}],"nova/virt/libvirt/driver.py":[{"author":{"_account_id":7730,"name":"Sahid Orentino Ferdjaoui","email":"sahid.ferdjaoui@industrialdiscipline.com","username":"sahid"},"change_message_id":"3745ac6da8fe93d38d2f55d93955d017a2c89a66","unresolved":false,"context_lines":[{"line_number":2634,"context_line":"            target_partition \u003d sys_meta.get(meta_name)"},{"line_number":2635,"context_line":"            if target_partition is not None:"},{"line_number":2636,"context_line":"                try:"},{"line_number":2637,"context_line":"                    target_partition \u003d int(target_partition)"},{"line_number":2638,"context_line":"                except ValueError:"},{"line_number":2639,"context_line":"                    LOG.warn(_LW(\u0027The image property inject_partition \u0027"},{"line_number":2640,"context_line":"                        \u0027is not an integer as expected. Ignoring it\u0027))"}],"source_content_type":"text/x-python","patch_set":4,"id":"ba7be1f8_71ec5890","line":2637,"updated":"2015-02-23 14:42:29.000000000","message":"What about if the host is configured to \u0027inject_partition\u0027 -2, this will override what the operator want. - We should check about it, no?\n\nI guess you want to activate this only if CONF.inject_partition is equal to -3","commit_id":"ccd0aef3bd6245dd6c4ed92a760a96f33b704263"},{"author":{"_account_id":15064,"name":"raphael.glon","email":"raphael.glon@corp.ovh.com","username":"raphael"},"change_message_id":"d55a0b9b65cbde888a29725dd7836bd103cf541d","unresolved":false,"context_lines":[{"line_number":2634,"context_line":"            target_partition \u003d sys_meta.get(meta_name)"},{"line_number":2635,"context_line":"            if target_partition is not None:"},{"line_number":2636,"context_line":"                try:"},{"line_number":2637,"context_line":"                    target_partition \u003d int(target_partition)"},{"line_number":2638,"context_line":"                except ValueError:"},{"line_number":2639,"context_line":"                    LOG.warn(_LW(\u0027The image property inject_partition \u0027"},{"line_number":2640,"context_line":"                        \u0027is not an integer as expected. Ignoring it\u0027))"}],"source_content_type":"text/x-python","patch_set":4,"id":"ba7be1f8_722d08a8","line":2637,"in_reply_to":"ba7be1f8_71ec5890","updated":"2015-02-24 14:47:09.000000000","message":"yes you\u0027re right. so may be we need two things: a value to tell us that we want to offer the possibility for the user to customize its inject partition and a value to give the fall back case if the property is not specified in the image. this can be done in one single config flag but may be better to have two for clarity (?). Submitting a new patchset for this asap","commit_id":"ccd0aef3bd6245dd6c4ed92a760a96f33b704263"},{"author":{"_account_id":7730,"name":"Sahid Orentino Ferdjaoui","email":"sahid.ferdjaoui@industrialdiscipline.com","username":"sahid"},"change_message_id":"d3b3ac9af7015608a68e8034907415312dd6adc9","unresolved":false,"context_lines":[{"line_number":140,"context_line":"                     \u00270 \u003d\u003e not partitioned, \u003e0 \u003d\u003e partition number, \u0027"},{"line_number":141,"context_line":"                     \u0027\u003c-2 \u003d\u003e customizable by image property, with \u0027"},{"line_number":142,"context_line":"                     \u0027default value equal to \u0027"},{"line_number":143,"context_line":"                     \u0027- CONF.libvirt.inject_partition - 5\u0027),"},{"line_number":144,"context_line":"    cfg.BoolOpt(\u0027use_usb_tablet\u0027,"},{"line_number":145,"context_line":"                default\u003dTrue,"},{"line_number":146,"context_line":"                help\u003d\u0027Sync virtual and real mouse cursors in Windows VMs\u0027),"}],"source_content_type":"text/x-python","patch_set":6,"id":"ba7be1f8_04f2c305","line":143,"updated":"2015-02-24 16:58:09.000000000","message":"Thinking again, I think we can just let users use image properties to override config if different than -2.","commit_id":"15d16ae4775d5cd17c28ce22c2ca1c02e15bc682"},{"author":{"_account_id":15064,"name":"raphael.glon","email":"raphael.glon@corp.ovh.com","username":"raphael"},"change_message_id":"cf295bd3458f01c4ab0e78d1877609e1205249dc","unresolved":false,"context_lines":[{"line_number":140,"context_line":"                     \u00270 \u003d\u003e not partitioned, \u003e0 \u003d\u003e partition number, \u0027"},{"line_number":141,"context_line":"                     \u0027\u003c-2 \u003d\u003e customizable by image property, with \u0027"},{"line_number":142,"context_line":"                     \u0027default value equal to \u0027"},{"line_number":143,"context_line":"                     \u0027- CONF.libvirt.inject_partition - 5\u0027),"},{"line_number":144,"context_line":"    cfg.BoolOpt(\u0027use_usb_tablet\u0027,"},{"line_number":145,"context_line":"                default\u003dTrue,"},{"line_number":146,"context_line":"                help\u003d\u0027Sync virtual and real mouse cursors in Windows VMs\u0027),"}],"source_content_type":"text/x-python","patch_set":6,"id":"ba7be1f8_31052b11","line":143,"in_reply_to":"ba7be1f8_04f2c305","updated":"2015-03-03 14:43:01.000000000","message":"ok. Then I think we could go back to first version of this file: users cannot override -2 because the _inject_data method is only called under the condition that libvirt.inject_partition is different than -2. need to recheck this twice though","commit_id":"15d16ae4775d5cd17c28ce22c2ca1c02e15bc682"},{"author":{"_account_id":7730,"name":"Sahid Orentino Ferdjaoui","email":"sahid.ferdjaoui@industrialdiscipline.com","username":"sahid"},"change_message_id":"8d16bed600ec8efd0cb40dbf01d0983de1f37c25","unresolved":false,"context_lines":[{"line_number":2619,"context_line":"        # Handles the partition need to be used."},{"line_number":2620,"context_line":"        target_partition \u003d None"},{"line_number":2621,"context_line":"        if not instance.kernel_id:"},{"line_number":2622,"context_line":"            # This is currently not possible for users to override"},{"line_number":2623,"context_line":"            # the data injection if it has been disabled by the"},{"line_number":2624,"context_line":"            # operator (-2), because _inject_data is only called"},{"line_number":2625,"context_line":"            # when data injection is enabled"}],"source_content_type":"text/x-python","patch_set":7,"id":"fa32b979_d2e9021c","line":2622,"updated":"2015-06-15 13:50:17.000000000","message":"Not sure if this comment in necessary.","commit_id":"60aeacbf818f253df22348892342511b27f99f92"},{"author":{"_account_id":1779,"name":"Daniel Berrange","email":"berrange@redhat.com","username":"berrange"},"change_message_id":"01cceeb706cd4789c31533c9b18fffde51dc5e39","unresolved":false,"context_lines":[{"line_number":2625,"context_line":"            # when data injection is enabled"},{"line_number":2626,"context_line":"            meta_name \u003d utils.SM_IMAGE_PROP_PREFIX + \u0027inject_partition\u0027"},{"line_number":2627,"context_line":"            sys_meta \u003d utils.instance_sys_meta(instance)"},{"line_number":2628,"context_line":"            target_partition \u003d sys_meta.get(meta_name)"},{"line_number":2629,"context_line":"            if target_partition is not None:"},{"line_number":2630,"context_line":"                try:"},{"line_number":2631,"context_line":"                    target_partition \u003d int(target_partition)"}],"source_content_type":"text/x-python","patch_set":7,"id":"7a016987_03a536b4","line":2628,"updated":"2015-05-26 10:37:45.000000000","message":"Don\u0027t re-fetch image meta - pass in the existing image meta object from the caller of inject_data.\n\nAlso the property name should be \u0027os_inject_partition\u0027","commit_id":"60aeacbf818f253df22348892342511b27f99f92"},{"author":{"_account_id":7730,"name":"Sahid Orentino Ferdjaoui","email":"sahid.ferdjaoui@industrialdiscipline.com","username":"sahid"},"change_message_id":"8d16bed600ec8efd0cb40dbf01d0983de1f37c25","unresolved":false,"context_lines":[{"line_number":2625,"context_line":"            # when data injection is enabled"},{"line_number":2626,"context_line":"            meta_name \u003d utils.SM_IMAGE_PROP_PREFIX + \u0027inject_partition\u0027"},{"line_number":2627,"context_line":"            sys_meta \u003d utils.instance_sys_meta(instance)"},{"line_number":2628,"context_line":"            target_partition \u003d sys_meta.get(meta_name)"},{"line_number":2629,"context_line":"            if target_partition is not None:"},{"line_number":2630,"context_line":"                try:"},{"line_number":2631,"context_line":"                    target_partition \u003d int(target_partition)"}],"source_content_type":"text/x-python","patch_set":7,"id":"fa32b979_52141243","line":2628,"in_reply_to":"7a016987_0067f7e9","updated":"2015-06-15 13:50:17.000000000","message":"I think Daniel is asking you to change the prototype of the method \u0027_inject_data\u0027 to accept a new argument \u0027image_meta\u0027.\n\nAbout the new image property you have introduced, you will have to update the object ImageMetaProperty in objects/image_meta.py","commit_id":"60aeacbf818f253df22348892342511b27f99f92"},{"author":{"_account_id":15064,"name":"raphael.glon","email":"raphael.glon@corp.ovh.com","username":"raphael"},"change_message_id":"8ab81e489cdfc4bc1acc73f20bd681832ab67db5","unresolved":false,"context_lines":[{"line_number":2625,"context_line":"            # when data injection is enabled"},{"line_number":2626,"context_line":"            meta_name \u003d utils.SM_IMAGE_PROP_PREFIX + \u0027inject_partition\u0027"},{"line_number":2627,"context_line":"            sys_meta \u003d utils.instance_sys_meta(instance)"},{"line_number":2628,"context_line":"            target_partition \u003d sys_meta.get(meta_name)"},{"line_number":2629,"context_line":"            if target_partition is not None:"},{"line_number":2630,"context_line":"                try:"},{"line_number":2631,"context_line":"                    target_partition \u003d int(target_partition)"}],"source_content_type":"text/x-python","patch_set":7,"id":"7a016987_0067f7e9","line":2628,"in_reply_to":"7a016987_03a536b4","updated":"2015-05-28 19:38:52.000000000","message":"thanks for the review. \n\nok for the os_inject_partition. \n\nI\u0027m not sure to understand the \"refetch\" point though. _system_metadata attr is already in the instance nova object, at least because of the previous call configdrive.required_by(instance) in the exec flow (and actually even loaded before). \n\nSo: do you mean mutualizing the utils.instance_sys_meta with the one of \u0027configdrive.required_by\u0027 ? Or do you mean bringing image_meta down to the _inject_meta call  (getting them from n-2 callers) ? Not sure of the gain obtained in any case","commit_id":"60aeacbf818f253df22348892342511b27f99f92"},{"author":{"_account_id":7730,"name":"Sahid Orentino Ferdjaoui","email":"sahid.ferdjaoui@industrialdiscipline.com","username":"sahid"},"change_message_id":"8d16bed600ec8efd0cb40dbf01d0983de1f37c25","unresolved":false,"context_lines":[{"line_number":2634,"context_line":"                except ValueError:"},{"line_number":2635,"context_line":"                    LOG.warn(_LW(\u0027The image property inject_partition \u0027"},{"line_number":2636,"context_line":"                        \u0027is not an integer greater than -2 as expected. \u0027"},{"line_number":2637,"context_line":"                        \u0027Ignoring it\u0027))"},{"line_number":2638,"context_line":"                    target_partition \u003d CONF.libvirt.inject_partition"},{"line_number":2639,"context_line":"            else:"},{"line_number":2640,"context_line":"                target_partition \u003d CONF.libvirt.inject_partition"}],"source_content_type":"text/x-python","patch_set":7,"id":"fa32b979_b2147ef5","line":2637,"updated":"2015-06-15 13:50:17.000000000","message":"Passing target_partition in the message can help when debugging also i\u0027m not sure we want a Warning which will notify the operator for a bad input from user. (But that can be discussed for sure) - I think we should block the process and raise an exception to indicate to the user the mistake.","commit_id":"60aeacbf818f253df22348892342511b27f99f92"}]}
