)]}'
{"specs/juno/instance-active-intervals.rst":[{"author":{"_account_id":6537,"name":"gordon chung","email":"gord@live.ca","username":"chungg"},"change_message_id":"e2fd9e9c850157a651601062436a9fdd254aa0c6","unresolved":false,"context_lines":[{"line_number":36,"context_line":"STOP(T2), ACTIVE(T3), ACTIVE(T4), ACTIVE(T5), STOP(T6), ACTIVE(T7), ACTIVE(T8)."},{"line_number":37,"context_line":"The new meters after transformation will be: T4-T3, T5-T4, T8-T7. There are"},{"line_number":38,"context_line":"three new samples generated with the value roughly 5mins(300secs) each. So"},{"line_number":39,"context_line":"during this period of time, the instance is being ACTIVE approximately 900 secs"},{"line_number":40,"context_line":"which can be queried by using statistics API with sum aggregation."},{"line_number":41,"context_line":""},{"line_number":42,"context_line":"Alternatives"}],"source_content_type":"text/x-rst","patch_set":10,"id":"baada198_c638fccd","line":39,"updated":"2014-07-30 20:17:04.000000000","message":"so this meter would be an approximation? for something that you are billing against, i\u0027m not sure customers will like that this is an approximate value...\n\ni\u0027m inclined to agree with fabio/dan. this really what events were designed for.","commit_id":"5c69be972f4a5d0d96a1ba088010c6fb3b55a6d1"},{"author":{"_account_id":12260,"name":"Kurt Rao","email":"dingyuan.rao@gmail.com","username":"kurtrao"},"change_message_id":"fad66ad23995406bfe4ca38b845c2002eb8fea67","unresolved":false,"context_lines":[{"line_number":36,"context_line":"STOP(T2), ACTIVE(T3), ACTIVE(T4), ACTIVE(T5), STOP(T6), ACTIVE(T7), ACTIVE(T8)."},{"line_number":37,"context_line":"The new meters after transformation will be: T4-T3, T5-T4, T8-T7. There are"},{"line_number":38,"context_line":"three new samples generated with the value roughly 5mins(300secs) each. So"},{"line_number":39,"context_line":"during this period of time, the instance is being ACTIVE approximately 900 secs"},{"line_number":40,"context_line":"which can be queried by using statistics API with sum aggregation."},{"line_number":41,"context_line":""},{"line_number":42,"context_line":"Alternatives"}],"source_content_type":"text/x-rst","patch_set":10,"id":"baada198_7a3f4eb5","line":39,"in_reply_to":"baada198_5201ffb3","updated":"2014-08-11 14:47:17.000000000","message":"As to the precision, although this \"instance.uptime\" is an approximation, the maximum amount of error is several five-minutes. For example, if a VM is turned on and off once everyday, after one month, the maximum amount of error is1.5 hour (30*5 mins) out of 720 hours, that\u0027s 0.2%. If a VM is turned on and off 5 times everyday (who would do that repeatedly everyday?), the maximum error rate is 1%. We can see that the approximation is actually quite accurate.\n\nUsing notification, as I already mentioned, (besides the reliability question) billing system will need complex logic to calculate the \"instance uptime\". And if we want to improve it, the billing system will have to change accordingly.\n\nUsing polling, we may lose 0.2% precision, but if we want to improve it, the billing system don\u0027t need to change. I think this is important.\n\nAnd, as this \"instance.uptime\" is an important metric, I\u0027d prefer to have it implemented using polling now and, maybe, have some improvements in the future.","commit_id":"5c69be972f4a5d0d96a1ba088010c6fb3b55a6d1"},{"author":{"_account_id":3012,"name":"Dina Belova","email":"dbelova@mirantis.com","username":"dbelova"},"change_message_id":"d53b9b9ccf393b7eae70eaac6354457e18d53935","unresolved":false,"context_lines":[{"line_number":36,"context_line":"STOP(T2), ACTIVE(T3), ACTIVE(T4), ACTIVE(T5), STOP(T6), ACTIVE(T7), ACTIVE(T8)."},{"line_number":37,"context_line":"The new meters after transformation will be: T4-T3, T5-T4, T8-T7. There are"},{"line_number":38,"context_line":"three new samples generated with the value roughly 5mins(300secs) each. So"},{"line_number":39,"context_line":"during this period of time, the instance is being ACTIVE approximately 900 secs"},{"line_number":40,"context_line":"which can be queried by using statistics API with sum aggregation."},{"line_number":41,"context_line":""},{"line_number":42,"context_line":"Alternatives"}],"source_content_type":"text/x-rst","patch_set":10,"id":"baada198_74a89a21","line":39,"in_reply_to":"baada198_5658088a","updated":"2014-07-31 14:10:47.000000000","message":"Ildiko, I think I may argue here actually... What Fabio and Dan were proposing earlier (events) seems to be right approach for this type of functionality - I mean, that looks quite logical for me to use billable events (like instance created, instance stopped, etc.) as a way of defining of instance run-time - well, at least, *billable events* definition seems to fit ok... Probably I don\u0027t understand some issues here to impl this feature as a events? anyway, some more descriptional info here will be actually welcome.","commit_id":"5c69be972f4a5d0d96a1ba088010c6fb3b55a6d1"},{"author":{"_account_id":9562,"name":"Ildiko Vancsa","email":"ildiko.vancsa@gmail.com","username":"ildikov"},"change_message_id":"21e20e94b06f13703fda6091699837d53af8fb50","unresolved":false,"context_lines":[{"line_number":36,"context_line":"STOP(T2), ACTIVE(T3), ACTIVE(T4), ACTIVE(T5), STOP(T6), ACTIVE(T7), ACTIVE(T8)."},{"line_number":37,"context_line":"The new meters after transformation will be: T4-T3, T5-T4, T8-T7. There are"},{"line_number":38,"context_line":"three new samples generated with the value roughly 5mins(300secs) each. So"},{"line_number":39,"context_line":"during this period of time, the instance is being ACTIVE approximately 900 secs"},{"line_number":40,"context_line":"which can be queried by using statistics API with sum aggregation."},{"line_number":41,"context_line":""},{"line_number":42,"context_line":"Alternatives"}],"source_content_type":"text/x-rst","patch_set":10,"id":"baada198_b4d13531","line":39,"in_reply_to":"baada198_74a89a21","updated":"2014-08-01 07:01:12.000000000","message":"So I wrote above that we need a mechanism which makes samples from these billable events, if we would like to go to this direction. If we store these notifications, it is still far from having an instance.uptime meter.\n\nIf we say that we only store these events and the user should figure it out how he/she will calculate uptime based on them, I think it\u0027s already done. But it\u0027s not that user friendly, so that is why it is an aim to have an exact meter for this purpose.\n\nIf we create a new meter based on these events, then we need to consider a few things that how we will handle the different types of notifications, will we use transformers to create the new samples or smth else, etc and we also need to consider several factors, that I mentioned in my earlier comments and also raised by Kurt Rao in his previous review comment regarding to usability and reliablility.\n\nThis spec in its current state is only an approximate instance.uptime counter, that is why I asked the author to rename the meter to be clear about what it exactly is and what not in this state.\n\nWhat I was asking for in my former review comments is that if someone thinks that the notifications direction would work, then let\u0027s provide some explanation of that mechanism and the changes that would be needed in Ceilometer to support it, if any. So again, I\u0027m not against notifications, moreover, as we cannot poll the exact uptime from the hypervisor or its too difficult to do, it seems to be the most precise option, I just would like to see the next step, that how it would actually work, so that we could move on with the discussions.","commit_id":"5c69be972f4a5d0d96a1ba088010c6fb3b55a6d1"},{"author":{"_account_id":12260,"name":"Kurt Rao","email":"dingyuan.rao@gmail.com","username":"kurtrao"},"change_message_id":"bce1cb9515f01a31577b1095901c11bf3706ae4f","unresolved":false,"context_lines":[{"line_number":36,"context_line":"STOP(T2), ACTIVE(T3), ACTIVE(T4), ACTIVE(T5), STOP(T6), ACTIVE(T7), ACTIVE(T8)."},{"line_number":37,"context_line":"The new meters after transformation will be: T4-T3, T5-T4, T8-T7. There are"},{"line_number":38,"context_line":"three new samples generated with the value roughly 5mins(300secs) each. So"},{"line_number":39,"context_line":"during this period of time, the instance is being ACTIVE approximately 900 secs"},{"line_number":40,"context_line":"which can be queried by using statistics API with sum aggregation."},{"line_number":41,"context_line":""},{"line_number":42,"context_line":"Alternatives"}],"source_content_type":"text/x-rst","patch_set":10,"id":"baada198_d5e859e1","line":39,"in_reply_to":"baada198_b4d13531","updated":"2014-08-01 14:34:47.000000000","message":"Fully agree~","commit_id":"5c69be972f4a5d0d96a1ba088010c6fb3b55a6d1"},{"author":{"_account_id":882,"name":"shengjie min","email":"minshengjie@chinacloud.com.cn","username":"shengjie-min"},"change_message_id":"9faa594f37518c009f6942eb7ad3ab9be356b871","unresolved":false,"context_lines":[{"line_number":36,"context_line":"STOP(T2), ACTIVE(T3), ACTIVE(T4), ACTIVE(T5), STOP(T6), ACTIVE(T7), ACTIVE(T8)."},{"line_number":37,"context_line":"The new meters after transformation will be: T4-T3, T5-T4, T8-T7. There are"},{"line_number":38,"context_line":"three new samples generated with the value roughly 5mins(300secs) each. So"},{"line_number":39,"context_line":"during this period of time, the instance is being ACTIVE approximately 900 secs"},{"line_number":40,"context_line":"which can be queried by using statistics API with sum aggregation."},{"line_number":41,"context_line":""},{"line_number":42,"context_line":"Alternatives"}],"source_content_type":"text/x-rst","patch_set":10,"id":"baada198_5201ffb3","line":39,"in_reply_to":"baada198_b4d13531","updated":"2014-08-07 10:55:04.000000000","message":"That\u0027s what I said at the beginning, to go down the notification approach, I don\u0027t see Ceilometer has such mechanism to support this now. We have to have something sitting on Ceilometer side to consume the notification events. That sounds like whole new bp on which this one would depend. What you guys think? If it\u0027s needed, I\u0027ll think about it and file one.","commit_id":"5c69be972f4a5d0d96a1ba088010c6fb3b55a6d1"},{"author":{"_account_id":12260,"name":"Kurt Rao","email":"dingyuan.rao@gmail.com","username":"kurtrao"},"change_message_id":"086a281c02123af85cd7d42384de3c599a50dac8","unresolved":false,"context_lines":[{"line_number":36,"context_line":"STOP(T2), ACTIVE(T3), ACTIVE(T4), ACTIVE(T5), STOP(T6), ACTIVE(T7), ACTIVE(T8)."},{"line_number":37,"context_line":"The new meters after transformation will be: T4-T3, T5-T4, T8-T7. There are"},{"line_number":38,"context_line":"three new samples generated with the value roughly 5mins(300secs) each. So"},{"line_number":39,"context_line":"during this period of time, the instance is being ACTIVE approximately 900 secs"},{"line_number":40,"context_line":"which can be queried by using statistics API with sum aggregation."},{"line_number":41,"context_line":""},{"line_number":42,"context_line":"Alternatives"}],"source_content_type":"text/x-rst","patch_set":10,"id":"baada198_dcf4488a","line":39,"in_reply_to":"baada198_c638fccd","updated":"2014-07-30 22:57:04.000000000","message":"Hi Gordon,\n\nWhat Fabio and Dan suggested is \"notification only\". This spec tries to create a new meter by transforming the *instance* meter which handles both polling and notification. I think it\u0027s more accurate.\n\nWhat I was arguing with Fabio and Dan was that the *notification only* method cannot fully satisfy the customer needs. So, notifications are definitely not to be ignored, but I really think we should add polling too.\n\nThe \"approximate\" the spec said here actually means the polling interval is not always accurately 300 sec. The transformer calculates the interval using \"current_timestamp - last_timestamp\". It will be accurate.\n\nBut yes, maybe we should update this spec to describe more clearly. Thanks a lot for bringing it up :)","commit_id":"5c69be972f4a5d0d96a1ba088010c6fb3b55a6d1"},{"author":{"_account_id":9562,"name":"Ildiko Vancsa","email":"ildiko.vancsa@gmail.com","username":"ildikov"},"change_message_id":"a5858adbfabe1361fc741b91a8cbd5f7b126933a","unresolved":false,"context_lines":[{"line_number":36,"context_line":"STOP(T2), ACTIVE(T3), ACTIVE(T4), ACTIVE(T5), STOP(T6), ACTIVE(T7), ACTIVE(T8)."},{"line_number":37,"context_line":"The new meters after transformation will be: T4-T3, T5-T4, T8-T7. There are"},{"line_number":38,"context_line":"three new samples generated with the value roughly 5mins(300secs) each. So"},{"line_number":39,"context_line":"during this period of time, the instance is being ACTIVE approximately 900 secs"},{"line_number":40,"context_line":"which can be queried by using statistics API with sum aggregation."},{"line_number":41,"context_line":""},{"line_number":42,"context_line":"Alternatives"}],"source_content_type":"text/x-rst","patch_set":10,"id":"baada198_5658088a","line":39,"in_reply_to":"baada198_dcf4488a","updated":"2014-07-31 08:50:48.000000000","message":"I think this spec is polling only or mostly...\n\nUsing both notifications and polling seems to be the most bullet proof, but the most complicated too. This spec really gives an approximate value, that is why I suggested earlier that if we go to this direction, then we shouldn\u0027t call this meter instance.uptime, because that would mislead the users.\n\nI\u0027m not against using notifications, but we need a mechanism then, to make it work.","commit_id":"5c69be972f4a5d0d96a1ba088010c6fb3b55a6d1"}],"specs/juno/instance-uptime.rst":[{"author":{"_account_id":2284,"name":"Eoghan Glynn","email":"eglynn@redhat.com","username":"eglynn"},"change_message_id":"1878af863955f7604898a80c08654861f63411dc","unresolved":false,"context_lines":[{"line_number":52,"context_line":"---------------"},{"line_number":53,"context_line":""},{"line_number":54,"context_line":"The new transformer and instance_uptime meter needs to added in the"},{"line_number":55,"context_line":"pipeline.yaml"},{"line_number":56,"context_line":""},{"line_number":57,"context_line":"Other end user impact"},{"line_number":58,"context_line":"---------------------"}],"source_content_type":"text/x-rst","patch_set":2,"id":"baada198_0ac367ed","line":55,"updated":"2014-07-06 20:47:09.000000000","message":"I wonder could this new transformer be made a bit more generic, i.e. to calculate the time duration for which *any* resource state in the sample metadata remains constant?","commit_id":"cf187ca45e7fb6c92c0e753c4251bc48758e4229"},{"author":{"_account_id":882,"name":"shengjie min","email":"minshengjie@chinacloud.com.cn","username":"shengjie-min"},"change_message_id":"e63d70221c3c3db50b2f014b5dfc63c74db6b573","unresolved":false,"context_lines":[{"line_number":52,"context_line":"---------------"},{"line_number":53,"context_line":""},{"line_number":54,"context_line":"The new transformer and instance_uptime meter needs to added in the"},{"line_number":55,"context_line":"pipeline.yaml"},{"line_number":56,"context_line":""},{"line_number":57,"context_line":"Other end user impact"},{"line_number":58,"context_line":"---------------------"}],"source_content_type":"text/x-rst","patch_set":2,"id":"baada198_21c11080","line":55,"in_reply_to":"baada198_0ac367ed","updated":"2014-07-15 05:41:34.000000000","message":"good one :) I was trying to make it as generic as possible, just like other transformers. will get this updated.","commit_id":"cf187ca45e7fb6c92c0e753c4251bc48758e4229"},{"author":{"_account_id":2284,"name":"Eoghan Glynn","email":"eglynn@redhat.com","username":"eglynn"},"change_message_id":"1878af863955f7604898a80c08654861f63411dc","unresolved":false,"context_lines":[{"line_number":67,"context_line":"Other deployer impact"},{"line_number":68,"context_line":"---------------------"},{"line_number":69,"context_line":""},{"line_number":70,"context_line":"Dedicated sources and sinks for the instance_uptime meter can be"},{"line_number":71,"context_line":"defined. An example below::"},{"line_number":72,"context_line":""},{"line_number":73,"context_line":"    sources:"}],"source_content_type":"text/x-rst","patch_set":2,"id":"baada198_6ab30398","line":70,"updated":"2014-07-06 20:47:09.000000000","message":"I\u0027m not loving \"instance_uptime\" as the meter name, due to the emerging convention to use period (\".\") as the separator in meter names. So how about \"instance.uptime\"?","commit_id":"cf187ca45e7fb6c92c0e753c4251bc48758e4229"},{"author":{"_account_id":882,"name":"shengjie min","email":"minshengjie@chinacloud.com.cn","username":"shengjie-min"},"change_message_id":"e63d70221c3c3db50b2f014b5dfc63c74db6b573","unresolved":false,"context_lines":[{"line_number":67,"context_line":"Other deployer impact"},{"line_number":68,"context_line":"---------------------"},{"line_number":69,"context_line":""},{"line_number":70,"context_line":"Dedicated sources and sinks for the instance_uptime meter can be"},{"line_number":71,"context_line":"defined. An example below::"},{"line_number":72,"context_line":""},{"line_number":73,"context_line":"    sources:"}],"source_content_type":"text/x-rst","patch_set":2,"id":"baada198_41bc4406","line":70,"in_reply_to":"baada198_6ab30398","updated":"2014-07-15 05:41:34.000000000","message":"sure, instance.uptime is the meter name then.","commit_id":"cf187ca45e7fb6c92c0e753c4251bc48758e4229"},{"author":{"_account_id":2284,"name":"Eoghan Glynn","email":"eglynn@redhat.com","username":"eglynn"},"change_message_id":"1878af863955f7604898a80c08654861f63411dc","unresolved":false,"context_lines":[{"line_number":87,"context_line":"                    unit:\"sec\""},{"line_number":88,"context_line":"                    type:\"gauge\""},{"line_number":89,"context_line":"          publishers:"},{"line_number":90,"context_line":"              - rpc://"},{"line_number":91,"context_line":""},{"line_number":92,"context_line":"Developer impact"},{"line_number":93,"context_line":"----------------"}],"source_content_type":"text/x-rst","patch_set":2,"id":"baada198_ea663329","line":90,"updated":"2014-07-06 20:47:09.000000000","message":"Can you include a note on the agent that\u0027ll be responsible for collecting this metric?\n\nI\u0027m assuming the compute agent, because:\n\n* it already polls for instance existence\n* the delta calculation will require maintaining a per-instance map in the transformer, so the natural scale of the compute agent (only concerned with the instances running on a single compute node, will make this more feasible","commit_id":"cf187ca45e7fb6c92c0e753c4251bc48758e4229"},{"author":{"_account_id":882,"name":"shengjie min","email":"minshengjie@chinacloud.com.cn","username":"shengjie-min"},"change_message_id":"e63d70221c3c3db50b2f014b5dfc63c74db6b573","unresolved":false,"context_lines":[{"line_number":87,"context_line":"                    unit:\"sec\""},{"line_number":88,"context_line":"                    type:\"gauge\""},{"line_number":89,"context_line":"          publishers:"},{"line_number":90,"context_line":"              - rpc://"},{"line_number":91,"context_line":""},{"line_number":92,"context_line":"Developer impact"},{"line_number":93,"context_line":"----------------"}],"source_content_type":"text/x-rst","patch_set":2,"id":"baada198_a13c4094","line":90,"in_reply_to":"baada198_ea663329","updated":"2014-07-15 05:41:34.000000000","message":"will do.","commit_id":"cf187ca45e7fb6c92c0e753c4251bc48758e4229"},{"author":{"_account_id":9562,"name":"Ildiko Vancsa","email":"ildiko.vancsa@gmail.com","username":"ildikov"},"change_message_id":"c828189e07dace7f606f26e15da90e8e71899577","unresolved":false,"context_lines":[{"line_number":29,"context_line":"generic transformer which caculates the delta(time duration) for which any"},{"line_number":30,"context_line":"resource state in the sample metadata. In this case, the new meter"},{"line_number":31,"context_line":"\"instance.uptime\" will be produced by the transformer based on the instance"},{"line_number":32,"context_line":"meter polled by the compute agent."},{"line_number":33,"context_line":""},{"line_number":34,"context_line":"Alternatives"},{"line_number":35,"context_line":"------------"}],"source_content_type":"text/x-rst","patch_set":3,"id":"baada198_69304e56","line":32,"updated":"2014-07-15 07:57:33.000000000","message":"I did not really get how it would work. Could you add some more detail, like which instance state is considered when you calculate instance uptime? Is this uptime since the last reboot or since the VM instance was created? How it will calculate any of these, as when the pollster collects info/a notification is received you know only the current state, where to get the missing info from?","commit_id":"c51962cd5d7a6de8e63b22ada8995721f0ada5cf"},{"author":{"_account_id":882,"name":"shengjie min","email":"minshengjie@chinacloud.com.cn","username":"shengjie-min"},"change_message_id":"72deccf8885fabb932567d1f17f60a05a62d1fb4","unresolved":false,"context_lines":[{"line_number":29,"context_line":"generic transformer which caculates the delta(time duration) for which any"},{"line_number":30,"context_line":"resource state in the sample metadata. In this case, the new meter"},{"line_number":31,"context_line":"\"instance.uptime\" will be produced by the transformer based on the instance"},{"line_number":32,"context_line":"meter polled by the compute agent."},{"line_number":33,"context_line":""},{"line_number":34,"context_line":"Alternatives"},{"line_number":35,"context_line":"------------"}],"source_content_type":"text/x-rst","patch_set":3,"id":"baada198_afccdf62","line":32,"in_reply_to":"baada198_07522b68","updated":"2014-07-16 16:49:17.000000000","message":"1. if the on-going instance samples are like: STOP(T1) STOP(T2) ACTIVE(T3) ACTIVE(T4) ACTIVE(5) STOP(T6) ACTIVE(T7) ACTIVE(T8), in this case, the new meters after transformation will be: T5-T3, T8-T7. So there\u0027s a bit logic there to check if the prev states are ACTIVE or not, NOT just a simple aggregation (of course, we will make the implementation more generic). \n\nI know u can argue if it\u0027s done this way, the instance could be up at any point(T2\u0027) between T2 to T3, then we\u0027d miss that period of time(T3-T2\u0027). In this implementation, we\u0027d assume we can tolerate that level of offset. Maybe we can use the vm on/off notification msg to make it more precise in the future. But at this point, I don\u0027t think that\u0027s fully thought through. Any thoughts? If you are ok with this, I can add this in as part of the proposed change.  \n\n2. Timestamp is part of the sample, pls see pollster/util.py make_sample_from_instance().  Just like other transformers, the new transformer needs to keep the prev states as needed at __init__ time. \n\n3. To get the total instance uptime between T1 and T2, you have to use the sum API to sum up the instance.uptime meters when T1\u003ct\u003cT2.\n\n4.  the instance.uptime would be the chunks of the instance uptime since the first time the vm is started.","commit_id":"c51962cd5d7a6de8e63b22ada8995721f0ada5cf"},{"author":{"_account_id":9562,"name":"Ildiko Vancsa","email":"ildiko.vancsa@gmail.com","username":"ildikov"},"change_message_id":"1171b2e5840d14bd9c95dc914cbabd61b14e1535","unresolved":false,"context_lines":[{"line_number":29,"context_line":"generic transformer which caculates the delta(time duration) for which any"},{"line_number":30,"context_line":"resource state in the sample metadata. In this case, the new meter"},{"line_number":31,"context_line":"\"instance.uptime\" will be produced by the transformer based on the instance"},{"line_number":32,"context_line":"meter polled by the compute agent."},{"line_number":33,"context_line":""},{"line_number":34,"context_line":"Alternatives"},{"line_number":35,"context_line":"------------"}],"source_content_type":"text/x-rst","patch_set":3,"id":"baada198_9b5f4475","line":32,"in_reply_to":"baada198_49b89111","updated":"2014-07-17 07:11:53.000000000","message":"Ok, if we focus on each interval, that could work, like in case of the \u0027reate of change\u0027 transformer. In this case if we check if the state of the instance was ACTIVE in the previous polling cycle and is still ACTIVE in the current too, we will still not be able to measure the uptime precisely. When the instance is in ERROR state, we will not get any new samples for it, so there will not be anything that would trigger this transformer, so I do not see it as a problem.\n\nI would suggest to call this new meter as \u0027instance.active.intervals\u0027 or something like this, because we have to inform the user explicitly that we collect only these inetrvals. And then in the documentation we can describe the API call, with which the user can get something approximately uptime value for a given time interval.\n\nThis solution here is not generic at this moment in the way that we will measure only the ACTIVE state of each instance. Later on it can be considered to provide the possibility to the user to set the measured state too, but I think that is a separate blueprint, let\u0027s see first how this one will work out.\n\nIf you agree with what I wrote above, then to speed up the process please update this section with more details. Also please update the Testing section below with some plans on how this could/should be tested. And it would also be good, if you could add a sentence in the documentation section that the limitations of this new meter should also be described in the documentation.","commit_id":"c51962cd5d7a6de8e63b22ada8995721f0ada5cf"},{"author":{"_account_id":882,"name":"shengjie min","email":"minshengjie@chinacloud.com.cn","username":"shengjie-min"},"change_message_id":"5e221e566009743d8e43daefc286b0930622ab3b","unresolved":false,"context_lines":[{"line_number":29,"context_line":"generic transformer which caculates the delta(time duration) for which any"},{"line_number":30,"context_line":"resource state in the sample metadata. In this case, the new meter"},{"line_number":31,"context_line":"\"instance.uptime\" will be produced by the transformer based on the instance"},{"line_number":32,"context_line":"meter polled by the compute agent."},{"line_number":33,"context_line":""},{"line_number":34,"context_line":"Alternatives"},{"line_number":35,"context_line":"------------"}],"source_content_type":"text/x-rst","patch_set":3,"id":"baada198_49b89111","line":32,"in_reply_to":"baada198_5a713fdf","updated":"2014-07-17 00:27:26.000000000","message":"Thanks IIdiko, that\u0027s a good finding. Another alternative is, instead of having T5-T3, T8-T7, we can have the new meters flushed as early as possible, like T4-T3, T5-T4, T8-T7. Every time we have a ACTIVE sample, we\u0027d check if the prev one is ACTIVE as well, if it is, we calculate the delta, then flush it out straight away. Then you\u0027d have more # of meters, it\u0027d avoid the case \"if it\u0027s never stopped, we will never get \u0027instance.uptime\". Maybe I am still missing some edge cases here, what you think? I guess the baseline here is that if the VM is screwed up or in any ERROR state, we MUST NOT keep charging customers.\n\nIn the 1st approach, to answer your question, YES, I meant the cache, just like the way the cache used in RateOfChangeTransformer.","commit_id":"c51962cd5d7a6de8e63b22ada8995721f0ada5cf"},{"author":{"_account_id":882,"name":"shengjie min","email":"minshengjie@chinacloud.com.cn","username":"shengjie-min"},"change_message_id":"89ed462479236df4d53902f8e5259aaf125274af","unresolved":false,"context_lines":[{"line_number":29,"context_line":"generic transformer which caculates the delta(time duration) for which any"},{"line_number":30,"context_line":"resource state in the sample metadata. In this case, the new meter"},{"line_number":31,"context_line":"\"instance.uptime\" will be produced by the transformer based on the instance"},{"line_number":32,"context_line":"meter polled by the compute agent."},{"line_number":33,"context_line":""},{"line_number":34,"context_line":"Alternatives"},{"line_number":35,"context_line":"------------"}],"source_content_type":"text/x-rst","patch_set":3,"id":"baada198_90b91ace","line":32,"in_reply_to":"baada198_69304e56","updated":"2014-07-16 01:17:27.000000000","message":"As described above, in this case, it\u0027s the vm_state, eg. ACTIVE.  The rough idea is to calculate the time duration between The ACTIVEs, so Timestamps will be used here. Maybe we can leave this to the code review of the implementation? We are trying to squeeze this in Juno-2.","commit_id":"c51962cd5d7a6de8e63b22ada8995721f0ada5cf"},{"author":{"_account_id":9562,"name":"Ildiko Vancsa","email":"ildiko.vancsa@gmail.com","username":"ildikov"},"change_message_id":"213d906c841166ef0ff8c4affb05322d33fd9655","unresolved":false,"context_lines":[{"line_number":29,"context_line":"generic transformer which caculates the delta(time duration) for which any"},{"line_number":30,"context_line":"resource state in the sample metadata. In this case, the new meter"},{"line_number":31,"context_line":"\"instance.uptime\" will be produced by the transformer based on the instance"},{"line_number":32,"context_line":"meter polled by the compute agent."},{"line_number":33,"context_line":""},{"line_number":34,"context_line":"Alternatives"},{"line_number":35,"context_line":"------------"}],"source_content_type":"text/x-rst","patch_set":3,"id":"baada198_07522b68","line":32,"in_reply_to":"baada198_90b91ace","updated":"2014-07-16 07:57:13.000000000","message":"Do you mean calculate between ACTIVEs and then sum it up, or?\n\nAlso how will you get the previous state and it\u0027s timestamp? You don\u0027t have that information in the pollster, nor in the transformer.\n\nAnd this instance.uptime would be the sum of the instance uptime since it was first started or the uptime since the last startup?","commit_id":"c51962cd5d7a6de8e63b22ada8995721f0ada5cf"},{"author":{"_account_id":882,"name":"shengjie min","email":"minshengjie@chinacloud.com.cn","username":"shengjie-min"},"change_message_id":"206b6deb90afca584a2476a95823a0cbd57e8412","unresolved":false,"context_lines":[{"line_number":29,"context_line":"generic transformer which caculates the delta(time duration) for which any"},{"line_number":30,"context_line":"resource state in the sample metadata. In this case, the new meter"},{"line_number":31,"context_line":"\"instance.uptime\" will be produced by the transformer based on the instance"},{"line_number":32,"context_line":"meter polled by the compute agent."},{"line_number":33,"context_line":""},{"line_number":34,"context_line":"Alternatives"},{"line_number":35,"context_line":"------------"}],"source_content_type":"text/x-rst","patch_set":3,"id":"baada198_9e7e4069","line":32,"in_reply_to":"baada198_9b5f4475","updated":"2014-07-17 14:21:41.000000000","message":"1. \u0027instance.active.intervals\u0027 makes sense.\n\n2. I agree with u on this one, making it more generic can be a separate bp.\n\nwill apply another patch this week.","commit_id":"c51962cd5d7a6de8e63b22ada8995721f0ada5cf"},{"author":{"_account_id":9562,"name":"Ildiko Vancsa","email":"ildiko.vancsa@gmail.com","username":"ildikov"},"change_message_id":"a9244200541b18c6cd8f15498ebe74165a601537","unresolved":false,"context_lines":[{"line_number":29,"context_line":"generic transformer which caculates the delta(time duration) for which any"},{"line_number":30,"context_line":"resource state in the sample metadata. In this case, the new meter"},{"line_number":31,"context_line":"\"instance.uptime\" will be produced by the transformer based on the instance"},{"line_number":32,"context_line":"meter polled by the compute agent."},{"line_number":33,"context_line":""},{"line_number":34,"context_line":"Alternatives"},{"line_number":35,"context_line":"------------"}],"source_content_type":"text/x-rst","patch_set":3,"id":"baada198_5a713fdf","line":32,"in_reply_to":"baada198_afccdf62","updated":"2014-07-16 17:20:24.000000000","message":"Ok, let\u0027s use this example then, thanks for providing it. If you say that the first chunk will be T5-T3, then it also means that you will have the first chunk in T6. So my questions to this point that if the instance is started then the first uptime value will be generated, when it is first stopped, suspended, etc and then if it\u0027s never stopped, we will never get \u0027instance.uptime\u0027? Also if the instance gets into ERROR state, then IIRC we do not get any samples for it, which would mean also that we will never get \u0027instance.uptime\u0027.\n\nThe cache you meant would contain the timestamp of the first ACTIVE state of the VM instance after a period of non-ACTIVE state and then cleaned if the instance is in any other state?","commit_id":"c51962cd5d7a6de8e63b22ada8995721f0ada5cf"},{"author":{"_account_id":9562,"name":"Ildiko Vancsa","email":"ildiko.vancsa@gmail.com","username":"ildikov"},"change_message_id":"c828189e07dace7f606f26e15da90e8e71899577","unresolved":false,"context_lines":[{"line_number":34,"context_line":"Alternatives"},{"line_number":35,"context_line":"------------"},{"line_number":36,"context_line":""},{"line_number":37,"context_line":"None"},{"line_number":38,"context_line":""},{"line_number":39,"context_line":"Data model impact"},{"line_number":40,"context_line":"-----------------"}],"source_content_type":"text/x-rst","patch_set":3,"id":"baada198_a936e64e","line":37,"updated":"2014-07-15 07:57:33.000000000","message":"Isn\u0027t there any alternatives? Like using only the instance meter and create the instance.uptime as an aggregation instead of with a transformer for instance?","commit_id":"c51962cd5d7a6de8e63b22ada8995721f0ada5cf"},{"author":{"_account_id":882,"name":"shengjie min","email":"minshengjie@chinacloud.com.cn","username":"shengjie-min"},"change_message_id":"89ed462479236df4d53902f8e5259aaf125274af","unresolved":false,"context_lines":[{"line_number":34,"context_line":"Alternatives"},{"line_number":35,"context_line":"------------"},{"line_number":36,"context_line":""},{"line_number":37,"context_line":"None"},{"line_number":38,"context_line":""},{"line_number":39,"context_line":"Data model impact"},{"line_number":40,"context_line":"-----------------"}],"source_content_type":"text/x-rst","patch_set":3,"id":"baada198_d08632db","line":37,"in_reply_to":"baada198_a936e64e","updated":"2014-07-16 01:17:27.000000000","message":"I don\u0027t quite get how that would work. As Eoghan Glynn said, I think making this transformer more generic(calculate the time durations for any resource state) would be very useful.","commit_id":"c51962cd5d7a6de8e63b22ada8995721f0ada5cf"},{"author":{"_account_id":9562,"name":"Ildiko Vancsa","email":"ildiko.vancsa@gmail.com","username":"ildikov"},"change_message_id":"c828189e07dace7f606f26e15da90e8e71899577","unresolved":false,"context_lines":[{"line_number":76,"context_line":"    sources:"},{"line_number":77,"context_line":"        - name: instance_source"},{"line_number":78,"context_line":"          interval: 600"},{"line_number":79,"context_line":"          meters:* Register the transform in the setup.cfg"},{"line_number":80,"context_line":"       which is        - \"instance\""},{"line_number":81,"context_line":"          sinks:"},{"line_number":82,"context_line":"              - instance_uptime_sink"}],"source_content_type":"text/x-rst","patch_set":3,"id":"baada198_0947d2bc","line":79,"updated":"2014-07-15 07:57:33.000000000","message":"Is this \"Register the ...\" part of the example? And also could you explain this one sentence here a bit? I did not fully get why it is here.","commit_id":"c51962cd5d7a6de8e63b22ada8995721f0ada5cf"},{"author":{"_account_id":882,"name":"shengjie min","email":"minshengjie@chinacloud.com.cn","username":"shengjie-min"},"change_message_id":"89ed462479236df4d53902f8e5259aaf125274af","unresolved":false,"context_lines":[{"line_number":76,"context_line":"    sources:"},{"line_number":77,"context_line":"        - name: instance_source"},{"line_number":78,"context_line":"          interval: 600"},{"line_number":79,"context_line":"          meters:* Register the transform in the setup.cfg"},{"line_number":80,"context_line":"       which is        - \"instance\""},{"line_number":81,"context_line":"          sinks:"},{"line_number":82,"context_line":"              - instance_uptime_sink"}],"source_content_type":"text/x-rst","patch_set":3,"id":"baada198_f06a561a","line":79,"in_reply_to":"baada198_0947d2bc","updated":"2014-07-16 01:17:27.000000000","message":"Done","commit_id":"c51962cd5d7a6de8e63b22ada8995721f0ada5cf"},{"author":{"_account_id":9562,"name":"Ildiko Vancsa","email":"ildiko.vancsa@gmail.com","username":"ildikov"},"change_message_id":"c828189e07dace7f606f26e15da90e8e71899577","unresolved":false,"context_lines":[{"line_number":84,"context_line":"        - name: instance_uptime_sink"},{"line_number":85,"context_line":"          transformers:"},{"line_number":86,"context_line":"              -name: \"state_delta_time\""},{"line_number":87,"context_line":"          parameters:"},{"line_number":88,"context_line":"                target:"},{"line_number":89,"context_line":"                    name:\"instance.uptime\""},{"line_number":90,"context_line":"                    unit:\"sec\""}],"source_content_type":"text/x-rst","patch_set":3,"id":"baada198_2919f6d0","line":87,"updated":"2014-07-15 07:57:33.000000000","message":"The \u0027parameters\u0027 block should be indented under \u0027name\u0027, as it belongs to that particular transformer.","commit_id":"c51962cd5d7a6de8e63b22ada8995721f0ada5cf"},{"author":{"_account_id":882,"name":"shengjie min","email":"minshengjie@chinacloud.com.cn","username":"shengjie-min"},"change_message_id":"89ed462479236df4d53902f8e5259aaf125274af","unresolved":false,"context_lines":[{"line_number":84,"context_line":"        - name: instance_uptime_sink"},{"line_number":85,"context_line":"          transformers:"},{"line_number":86,"context_line":"              -name: \"state_delta_time\""},{"line_number":87,"context_line":"          parameters:"},{"line_number":88,"context_line":"                target:"},{"line_number":89,"context_line":"                    name:\"instance.uptime\""},{"line_number":90,"context_line":"                    unit:\"sec\""}],"source_content_type":"text/x-rst","patch_set":3,"id":"baada198_3075aefa","line":87,"in_reply_to":"baada198_2919f6d0","updated":"2014-07-16 01:17:27.000000000","message":"Done","commit_id":"c51962cd5d7a6de8e63b22ada8995721f0ada5cf"},{"author":{"_account_id":9562,"name":"Ildiko Vancsa","email":"ildiko.vancsa@gmail.com","username":"ildikov"},"change_message_id":"c828189e07dace7f606f26e15da90e8e71899577","unresolved":false,"context_lines":[{"line_number":139,"context_line":"Documentation Impact"},{"line_number":140,"context_line":"\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d"},{"line_number":141,"context_line":""},{"line_number":142,"context_line":"None"},{"line_number":143,"context_line":""},{"line_number":144,"context_line":"References"},{"line_number":145,"context_line":"\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d"}],"source_content_type":"text/x-rst","patch_set":3,"id":"baada198_a98426d3","line":142,"updated":"2014-07-15 07:57:33.000000000","message":"Please add a note here that it has documentation impact in the sense of creating a new meter.","commit_id":"c51962cd5d7a6de8e63b22ada8995721f0ada5cf"},{"author":{"_account_id":882,"name":"shengjie min","email":"minshengjie@chinacloud.com.cn","username":"shengjie-min"},"change_message_id":"72deccf8885fabb932567d1f17f60a05a62d1fb4","unresolved":false,"context_lines":[{"line_number":139,"context_line":"Documentation Impact"},{"line_number":140,"context_line":"\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d"},{"line_number":141,"context_line":""},{"line_number":142,"context_line":"None"},{"line_number":143,"context_line":""},{"line_number":144,"context_line":"References"},{"line_number":145,"context_line":"\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d"}],"source_content_type":"text/x-rst","patch_set":3,"id":"baada198_eff7b757","line":142,"in_reply_to":"baada198_a98426d3","updated":"2014-07-16 16:49:17.000000000","message":"Done","commit_id":"c51962cd5d7a6de8e63b22ada8995721f0ada5cf"},{"author":{"_account_id":9562,"name":"Ildiko Vancsa","email":"ildiko.vancsa@gmail.com","username":"ildikov"},"change_message_id":"7fbdb749c35e9b58f3b1f682c9f5a191940b7414","unresolved":false,"context_lines":[{"line_number":26,"context_line":"Compute agent produces samples with vm_state as an attribute of the instances,"},{"line_number":27,"context_line":"this piece of info exists in resource_metadata. The rough idea is to add a new"},{"line_number":28,"context_line":"transformer which calculates the delta(time duration) for which any"},{"line_number":29,"context_line":"resource state in the sample metadata. In this case, the new meter"},{"line_number":30,"context_line":"\"instance.active.intervals\" will be produced by the transformer based on the"},{"line_number":31,"context_line":"instance meter polled by the compute agent."},{"line_number":32,"context_line":""}],"source_content_type":"text/x-rst","patch_set":6,"id":"baada198_55de5edb","line":29,"updated":"2014-07-23 08:36:42.000000000","message":"Please change the \u0027any resource state\u0027 to \u0027ACTIVE state\u0027, just to be clear about the purpose of this BP spec.","commit_id":"82c00cbbfc84e5606b0ed726146b4ea4e49baf37"},{"author":{"_account_id":882,"name":"shengjie min","email":"minshengjie@chinacloud.com.cn","username":"shengjie-min"},"change_message_id":"d79f8adc86d1f12859dd054ae433f8e63a997de9","unresolved":false,"context_lines":[{"line_number":26,"context_line":"Compute agent produces samples with vm_state as an attribute of the instances,"},{"line_number":27,"context_line":"this piece of info exists in resource_metadata. The rough idea is to add a new"},{"line_number":28,"context_line":"transformer which calculates the delta(time duration) for which any"},{"line_number":29,"context_line":"resource state in the sample metadata. In this case, the new meter"},{"line_number":30,"context_line":"\"instance.active.intervals\" will be produced by the transformer based on the"},{"line_number":31,"context_line":"instance meter polled by the compute agent."},{"line_number":32,"context_line":""}],"source_content_type":"text/x-rst","patch_set":6,"id":"baada198_e0ac0fa2","line":29,"in_reply_to":"baada198_55de5edb","updated":"2014-07-23 10:04:07.000000000","message":"Done","commit_id":"82c00cbbfc84e5606b0ed726146b4ea4e49baf37"},{"author":{"_account_id":9562,"name":"Ildiko Vancsa","email":"ildiko.vancsa@gmail.com","username":"ildikov"},"change_message_id":"7fbdb749c35e9b58f3b1f682c9f5a191940b7414","unresolved":false,"context_lines":[{"line_number":36,"context_line":"    STOP(T1), STOP(T2), ACTIVE(T3), ACTIVE(T4), ACTIVE(5), STOP(T6), ACTIVE(T7),"},{"line_number":37,"context_line":"    ACTIVE(T8). The new meters after transformation will be: T4-T3, T5-T4,"},{"line_number":38,"context_line":"    T8-T7. There are three new samples generated with the value roughly"},{"line_number":39,"context_line":"    5mins(300secs) each. So during this period of time, The instance is being"},{"line_number":40,"context_line":"    ACTIVE approximately 900 secs which can be queried by using statistics API"},{"line_number":41,"context_line":"    with sum aggregation."},{"line_number":42,"context_line":""}],"source_content_type":"text/x-rst","patch_set":6,"id":"baada198_15fb0649","line":39,"updated":"2014-07-23 08:36:42.000000000","message":"s/The/the/","commit_id":"82c00cbbfc84e5606b0ed726146b4ea4e49baf37"},{"author":{"_account_id":882,"name":"shengjie min","email":"minshengjie@chinacloud.com.cn","username":"shengjie-min"},"change_message_id":"d79f8adc86d1f12859dd054ae433f8e63a997de9","unresolved":false,"context_lines":[{"line_number":36,"context_line":"    STOP(T1), STOP(T2), ACTIVE(T3), ACTIVE(T4), ACTIVE(5), STOP(T6), ACTIVE(T7),"},{"line_number":37,"context_line":"    ACTIVE(T8). The new meters after transformation will be: T4-T3, T5-T4,"},{"line_number":38,"context_line":"    T8-T7. There are three new samples generated with the value roughly"},{"line_number":39,"context_line":"    5mins(300secs) each. So during this period of time, The instance is being"},{"line_number":40,"context_line":"    ACTIVE approximately 900 secs which can be queried by using statistics API"},{"line_number":41,"context_line":"    with sum aggregation."},{"line_number":42,"context_line":""}],"source_content_type":"text/x-rst","patch_set":6,"id":"baada198_0093c35c","line":39,"in_reply_to":"baada198_15fb0649","updated":"2014-07-23 10:04:07.000000000","message":"Done","commit_id":"82c00cbbfc84e5606b0ed726146b4ea4e49baf37"},{"author":{"_account_id":9562,"name":"Ildiko Vancsa","email":"ildiko.vancsa@gmail.com","username":"ildikov"},"change_message_id":"7fbdb749c35e9b58f3b1f682c9f5a191940b7414","unresolved":false,"context_lines":[{"line_number":144,"context_line":"Testing"},{"line_number":145,"context_line":"\u003d\u003d\u003d\u003d\u003d\u003d\u003d"},{"line_number":146,"context_line":""},{"line_number":147,"context_line":"None"},{"line_number":148,"context_line":""},{"line_number":149,"context_line":"Documentation Impact"},{"line_number":150,"context_line":"\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d"}],"source_content_type":"text/x-rst","patch_set":6,"id":"baada198_35564a2b","line":147,"updated":"2014-07-23 08:36:42.000000000","message":"Please add a comment about that this should be tested with unit tests and if the Ceilometer tests in Tempest will cover the polling mechanism, it should be considered there to check the generation of this meter too or not.","commit_id":"82c00cbbfc84e5606b0ed726146b4ea4e49baf37"},{"author":{"_account_id":882,"name":"shengjie min","email":"minshengjie@chinacloud.com.cn","username":"shengjie-min"},"change_message_id":"d79f8adc86d1f12859dd054ae433f8e63a997de9","unresolved":false,"context_lines":[{"line_number":144,"context_line":"Testing"},{"line_number":145,"context_line":"\u003d\u003d\u003d\u003d\u003d\u003d\u003d"},{"line_number":146,"context_line":""},{"line_number":147,"context_line":"None"},{"line_number":148,"context_line":""},{"line_number":149,"context_line":"Documentation Impact"},{"line_number":150,"context_line":"\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d"}],"source_content_type":"text/x-rst","patch_set":6,"id":"baada198_208e0733","line":147,"in_reply_to":"baada198_35564a2b","updated":"2014-07-23 10:04:07.000000000","message":"Done","commit_id":"82c00cbbfc84e5606b0ed726146b4ea4e49baf37"},{"author":{"_account_id":10987,"name":"Igor Degtiarov","username":"tovstun","inactive":true},"change_message_id":"27d0e7751431b500a8670101300a524477851702","unresolved":false,"context_lines":[{"line_number":6,"context_line":""},{"line_number":7,"context_line":"\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d"},{"line_number":8,"context_line":"Instance Active Interval Meter"},{"line_number":9,"context_line":"\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d"},{"line_number":10,"context_line":""},{"line_number":11,"context_line":"This blueprint aims at making instance active intervals as an available billing"},{"line_number":12,"context_line":"metric in Ceilometer."}],"source_content_type":"text/x-rst","patch_set":7,"id":"baada198_fb13e062","line":9,"updated":"2014-07-23 10:54:37.000000000","message":"Title length must match the underline.","commit_id":"d8b351db135b94df2188d1a1a6ff4c594e040823"},{"author":{"_account_id":882,"name":"shengjie min","email":"minshengjie@chinacloud.com.cn","username":"shengjie-min"},"change_message_id":"68f436ae549a45114df6c03973732132fa472e46","unresolved":false,"context_lines":[{"line_number":6,"context_line":""},{"line_number":7,"context_line":"\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d"},{"line_number":8,"context_line":"Instance Active Interval Meter"},{"line_number":9,"context_line":"\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d"},{"line_number":10,"context_line":""},{"line_number":11,"context_line":"This blueprint aims at making instance active intervals as an available billing"},{"line_number":12,"context_line":"metric in Ceilometer."}],"source_content_type":"text/x-rst","patch_set":7,"id":"baada198_a6a85321","line":9,"in_reply_to":"baada198_fb13e062","updated":"2014-07-24 01:16:23.000000000","message":"Done","commit_id":"d8b351db135b94df2188d1a1a6ff4c594e040823"},{"author":{"_account_id":10987,"name":"Igor Degtiarov","username":"tovstun","inactive":true},"change_message_id":"27d0e7751431b500a8670101300a524477851702","unresolved":false,"context_lines":[{"line_number":30,"context_line":"will be produced by the transformer based on the instance meter polled by the"},{"line_number":31,"context_line":"compute agent."},{"line_number":32,"context_line":""},{"line_number":33,"context_line":"An example below::"},{"line_number":34,"context_line":""},{"line_number":35,"context_line":"    Given the polling cycle is 5 mins, the on-going instance samples are:"},{"line_number":36,"context_line":"    STOP(T1), STOP(T2), ACTIVE(T3), ACTIVE(T4), ACTIVE(5), STOP(T6), ACTIVE(T7),"}],"source_content_type":"text/x-rst","patch_set":7,"id":"baada198_962479b3","line":33,"updated":"2014-07-23 10:54:37.000000000","message":"May be one column is enough.","commit_id":"d8b351db135b94df2188d1a1a6ff4c594e040823"},{"author":{"_account_id":882,"name":"shengjie min","email":"minshengjie@chinacloud.com.cn","username":"shengjie-min"},"change_message_id":"68f436ae549a45114df6c03973732132fa472e46","unresolved":false,"context_lines":[{"line_number":30,"context_line":"will be produced by the transformer based on the instance meter polled by the"},{"line_number":31,"context_line":"compute agent."},{"line_number":32,"context_line":""},{"line_number":33,"context_line":"An example below::"},{"line_number":34,"context_line":""},{"line_number":35,"context_line":"    Given the polling cycle is 5 mins, the on-going instance samples are:"},{"line_number":36,"context_line":"    STOP(T1), STOP(T2), ACTIVE(T3), ACTIVE(T4), ACTIVE(5), STOP(T6), ACTIVE(T7),"}],"source_content_type":"text/x-rst","patch_set":7,"id":"baada198_f9002c02","line":33,"in_reply_to":"baada198_962479b3","updated":"2014-07-24 01:16:23.000000000","message":"Done","commit_id":"d8b351db135b94df2188d1a1a6ff4c594e040823"},{"author":{"_account_id":7052,"name":"Fabio Giannetti","email":"fgiannet@cisco.com","username":"fabgia"},"change_message_id":"685c8f4ed8b531fcc900e2e03eec9be656891532","unresolved":false,"context_lines":[{"line_number":33,"context_line":"An example below:"},{"line_number":34,"context_line":""},{"line_number":35,"context_line":"Given the polling cycle is 5 mins, the on-going instance samples are: STOP(T1),"},{"line_number":36,"context_line":"STOP(T2), ACTIVE(T3), ACTIVE(T4), ACTIVE(5), STOP(T6), ACTIVE(T7), ACTIVE(T8)."},{"line_number":37,"context_line":"The new meters after transformation will be: T4-T3, T5-T4, T8-T7. There are"},{"line_number":38,"context_line":"three new samples generated with the value roughly 5mins(300secs) each. So"},{"line_number":39,"context_line":"during this period of time, the instance is being ACTIVE approximately 900 secs"}],"source_content_type":"text/x-rst","patch_set":8,"id":"baada198_dc5c36f3","line":36,"updated":"2014-07-24 02:15:21.000000000","message":"This should be ACTIVE(T5)","commit_id":"d66927dbca58efa2f72aa6b08ca00896cc9ea323"},{"author":{"_account_id":882,"name":"shengjie min","email":"minshengjie@chinacloud.com.cn","username":"shengjie-min"},"change_message_id":"8ce199724e9fb7364d0cd5f66fe6bf77f689f0f1","unresolved":false,"context_lines":[{"line_number":33,"context_line":"An example below:"},{"line_number":34,"context_line":""},{"line_number":35,"context_line":"Given the polling cycle is 5 mins, the on-going instance samples are: STOP(T1),"},{"line_number":36,"context_line":"STOP(T2), ACTIVE(T3), ACTIVE(T4), ACTIVE(5), STOP(T6), ACTIVE(T7), ACTIVE(T8)."},{"line_number":37,"context_line":"The new meters after transformation will be: T4-T3, T5-T4, T8-T7. There are"},{"line_number":38,"context_line":"three new samples generated with the value roughly 5mins(300secs) each. So"},{"line_number":39,"context_line":"during this period of time, the instance is being ACTIVE approximately 900 secs"}],"source_content_type":"text/x-rst","patch_set":8,"id":"baada198_9cc63e67","line":36,"in_reply_to":"baada198_dc5c36f3","updated":"2014-07-24 02:18:18.000000000","message":"Done","commit_id":"d66927dbca58efa2f72aa6b08ca00896cc9ea323"},{"author":{"_account_id":7052,"name":"Fabio Giannetti","email":"fgiannet@cisco.com","username":"fabgia"},"change_message_id":"685c8f4ed8b531fcc900e2e03eec9be656891532","unresolved":false,"context_lines":[{"line_number":42,"context_line":"Alternatives"},{"line_number":43,"context_line":"------------"},{"line_number":44,"context_line":""},{"line_number":45,"context_line":"None"},{"line_number":46,"context_line":""},{"line_number":47,"context_line":"Data model impact"},{"line_number":48,"context_line":"-----------------"}],"source_content_type":"text/x-rst","patch_set":8,"id":"baada198_19d080c8","line":45,"updated":"2014-07-24 02:15:21.000000000","message":"Have you considered notifications?\nNova can notify when a VM has been started or stopped. This will give you the exact starting time and stopping time instead of having to segment the time using a sampling factor of 5 min of whatever (please note the more granular the worse it is going to be a scale).\nPlease be kind and explain me why this solution is not acceptable.","commit_id":"d66927dbca58efa2f72aa6b08ca00896cc9ea323"},{"author":{"_account_id":882,"name":"shengjie min","email":"minshengjie@chinacloud.com.cn","username":"shengjie-min"},"change_message_id":"038e08b1eae0cfe2bcb948776bbcea0e5c32751f","unresolved":false,"context_lines":[{"line_number":42,"context_line":"Alternatives"},{"line_number":43,"context_line":"------------"},{"line_number":44,"context_line":""},{"line_number":45,"context_line":"None"},{"line_number":46,"context_line":""},{"line_number":47,"context_line":"Data model impact"},{"line_number":48,"context_line":"-----------------"}],"source_content_type":"text/x-rst","patch_set":8,"id":"baada198_3759c435","line":45,"in_reply_to":"baada198_11f21006","updated":"2014-07-24 08:21:25.000000000","message":"My feeling is that the notification approach adds more complexity in the mix. The collection of the new meters are heavily rely on notification bus. My suggestion is that put this one out there and see how it works out. One bp may not sort everything out at once.","commit_id":"d66927dbca58efa2f72aa6b08ca00896cc9ea323"},{"author":{"_account_id":12260,"name":"Kurt Rao","email":"dingyuan.rao@gmail.com","username":"kurtrao"},"change_message_id":"017fc7b470ea4e15f8c707c205d2ea9b9a960ea2","unresolved":false,"context_lines":[{"line_number":42,"context_line":"Alternatives"},{"line_number":43,"context_line":"------------"},{"line_number":44,"context_line":""},{"line_number":45,"context_line":"None"},{"line_number":46,"context_line":""},{"line_number":47,"context_line":"Data model impact"},{"line_number":48,"context_line":"-----------------"}],"source_content_type":"text/x-rst","patch_set":8,"id":"baada198_53aa61d2","line":45,"in_reply_to":"baada198_19d080c8","updated":"2014-07-28 11:50:54.000000000","message":"Hi Fabio,\n\nThe problem about using notification is, as Ildiko said, you don\u0027t know the state of the VM until you get the first notification. So, once the agent somehow restarts, instead of losing a 5-min sample, a big chunk of time (and you don\u0027t know how long) will be elapsed until we can monitor the state of the VM again. The agent will be hard to recover from error and this is a reliability issue. This meter should be as precise as possible since the billing system may charge people directly according to it.\n\n\"traffic\" issue you mentioned is very important, but I thought this is a generic problem caused by the \"disability\" of the collector which cannot derive new meters. There are other meters wasting traffic too, such as \"cpu_util\". In fact, all meters generated by a transformer can be seen as a waste of traffic. So, personally, I thought the best way to fix traffic issue is to add transformer module to collector. Correct me if there was discussion about this \"transformer to collector\" before, I\u0027m quite new here and not familiar with the history :) Anyway, it\u0027s a big issue, and we should talk about it in another thread.\n\nAnd what\u0027s more, if there are users thinking this meter as a waste of traffic, they can always remove it from the pipeline.yaml. But there are also people want this meter, like us. And you can see Chris Dent\u0027s comment too. So I think we should provide the ability, and let the end user choose.\n\nIn general, I think this spec is good, and the traffic issue should be talked about in a separate BP.","commit_id":"d66927dbca58efa2f72aa6b08ca00896cc9ea323"},{"author":{"_account_id":882,"name":"shengjie min","email":"minshengjie@chinacloud.com.cn","username":"shengjie-min"},"change_message_id":"b8bd3ea6812a62f50d0f350532b50fcf8187990d","unresolved":false,"context_lines":[{"line_number":42,"context_line":"Alternatives"},{"line_number":43,"context_line":"------------"},{"line_number":44,"context_line":""},{"line_number":45,"context_line":"None"},{"line_number":46,"context_line":""},{"line_number":47,"context_line":"Data model impact"},{"line_number":48,"context_line":"-----------------"}],"source_content_type":"text/x-rst","patch_set":8,"id":"baada198_28408c06","line":45,"in_reply_to":"baada198_19d080c8","updated":"2014-07-24 05:39:50.000000000","message":"Hi Fabio, I probably missed your point at the first place. By we did, I meant we have thought about using notification to make our meters more precise. Actually I think you meant just entirely depending on the notification mechanism. Does Ceilometer have a way to support the notification approach?","commit_id":"d66927dbca58efa2f72aa6b08ca00896cc9ea323"},{"author":{"_account_id":882,"name":"shengjie min","email":"minshengjie@chinacloud.com.cn","username":"shengjie-min"},"change_message_id":"8ce199724e9fb7364d0cd5f66fe6bf77f689f0f1","unresolved":false,"context_lines":[{"line_number":42,"context_line":"Alternatives"},{"line_number":43,"context_line":"------------"},{"line_number":44,"context_line":""},{"line_number":45,"context_line":"None"},{"line_number":46,"context_line":""},{"line_number":47,"context_line":"Data model impact"},{"line_number":48,"context_line":"-----------------"}],"source_content_type":"text/x-rst","patch_set":8,"id":"baada198_9c9d5e69","line":45,"in_reply_to":"baada198_19d080c8","updated":"2014-07-24 02:18:18.000000000","message":"Yes, we did, we are planning to make that another bp. Just like we can also try to make this transformer as generic as possible at once, But for now, we are planning to make that as another bp also. Just want put this one out there and see how it works out first.","commit_id":"d66927dbca58efa2f72aa6b08ca00896cc9ea323"},{"author":{"_account_id":9562,"name":"Ildiko Vancsa","email":"ildiko.vancsa@gmail.com","username":"ildikov"},"change_message_id":"f0e24eb2697a05920c17d898750c1811cbe72869","unresolved":false,"context_lines":[{"line_number":42,"context_line":"Alternatives"},{"line_number":43,"context_line":"------------"},{"line_number":44,"context_line":""},{"line_number":45,"context_line":"None"},{"line_number":46,"context_line":""},{"line_number":47,"context_line":"Data model impact"},{"line_number":48,"context_line":"-----------------"}],"source_content_type":"text/x-rst","patch_set":8,"id":"baada198_11f21006","line":45,"in_reply_to":"baada198_28408c06","updated":"2014-07-24 06:52:55.000000000","message":"There are two issues, because of which depending on simply the notifications does not seem to be the best solution.\n\nThe first is, that until we do not get a notification about that the VM instance is stopped, we cannot provide any info about the VM uptime.\n\nThe second is that I\u0027m not 100% sure about other notifications,like the instance is in ERROR state, so that Nova sends a notification about each state change or not.","commit_id":"d66927dbca58efa2f72aa6b08ca00896cc9ea323"}]}
