<feed xmlns='http://www.w3.org/2005/Atom'>
<title>delta/openstack/python-ceilometerclient.git/ceilometerclient/tests/test_utils.py, branch kilo-eol</title>
<subtitle>opendev.org: openstack/python-ceilometerclient.git
</subtitle>
<link rel='alternate' type='text/html' href='http://git.baserock.org/cgit/delta/openstack/python-ceilometerclient.git/'/>
<entry>
<title>Support unicode for alarm</title>
<updated>2015-04-16T12:58:59+00:00</updated>
<author>
<name>ZhiQiang Fan</name>
<email>zhiqiang.fan@huawei.com</email>
</author>
<published>2015-01-19T06:52:08+00:00</published>
<link rel='alternate' type='text/html' href='http://git.baserock.org/cgit/delta/openstack/python-ceilometerclient.git/commit/?id=09bcf5c89a437524aa9d02a6b5c2dada605d9d0d'/>
<id>09bcf5c89a437524aa9d02a6b5c2dada605d9d0d</id>
<content type='text'>
We're using ceilometer.common.utils.print_dict() for displaying alarm,
but assume only contain ascii characters, which will cause UnicodeEncodeError
when alarm's name or description has unicode characters.

The oslo-incubator.cliutils.print_dict() is more friendly to unicode,
but it has no sort option, and has different line wrap strategy. Since
the upstream improvement can be low progress, this patch adds unicode
support based on current code.

Change-Id: Ia58d5813c6f80cb8b44bf7636e1efc0cdd6e6d5b
Closes-Bug: #1412300
(cherry picked from commit f1f452405a80884c7a9cd78cad4aa4d73e290745)
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
We're using ceilometer.common.utils.print_dict() for displaying alarm,
but assume only contain ascii characters, which will cause UnicodeEncodeError
when alarm's name or description has unicode characters.

The oslo-incubator.cliutils.print_dict() is more friendly to unicode,
but it has no sort option, and has different line wrap strategy. Since
the upstream improvement can be low progress, this patch adds unicode
support based on current code.

Change-Id: Ia58d5813c6f80cb8b44bf7636e1efc0cdd6e6d5b
Closes-Bug: #1412300
(cherry picked from commit f1f452405a80884c7a9cd78cad4aa4d73e290745)
</pre>
</div>
</content>
</entry>
<entry>
<title>Fix old-style classes declaration</title>
<updated>2014-12-10T10:20:33+00:00</updated>
<author>
<name>Dina Belova</name>
<email>dbelova@mirantis.com</email>
</author>
<published>2014-12-10T10:13:57+00:00</published>
<link rel='alternate' type='text/html' href='http://git.baserock.org/cgit/delta/openstack/python-ceilometerclient.git/commit/?id=dd67d3bd259494ac94731aed3d92ac4177c65bf4'/>
<id>dd67d3bd259494ac94731aed3d92ac4177c65bf4</id>
<content type='text'>
Change-Id: I8759dd64637e5150f6744d0989eaa5e584487f5e
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Change-Id: I8759dd64637e5150f6744d0989eaa5e584487f5e
</pre>
</div>
</content>
</entry>
<entry>
<title>Alarm TimeConstraint display incorrect</title>
<updated>2014-11-25T22:44:51+00:00</updated>
<author>
<name>Rohit Jaiswal</name>
<email>rohit.jaiswal@hp.com</email>
</author>
<published>2014-11-21T19:58:02+00:00</published>
<link rel='alternate' type='text/html' href='http://git.baserock.org/cgit/delta/openstack/python-ceilometerclient.git/commit/?id=5fd0b4102a6a8f4e510534e67d0db4d9ab9639bc'/>
<id>5fd0b4102a6a8f4e510534e67d0db4d9ab9639bc</id>
<content type='text'>
Added test case for print_dict function

Change-Id: I3ab8a4e25f946b409ede2a598a5b9cf8593a044e
Closes-Bug: #1395110
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Added test case for print_dict function

Change-Id: I3ab8a4e25f946b409ede2a598a5b9cf8593a044e
Closes-Bug: #1395110
</pre>
</div>
</content>
</entry>
<entry>
<title>Fix hacking rules: H302,H305,H307,H402</title>
<updated>2014-06-11T09:32:16+00:00</updated>
<author>
<name>ZhiQiang Fan</name>
<email>zhiqiang.fan@huawei.com</email>
</author>
<published>2014-06-11T08:32:20+00:00</published>
<link rel='alternate' type='text/html' href='http://git.baserock.org/cgit/delta/openstack/python-ceilometerclient.git/commit/?id=55227d6d32deb49b9a8728d217eece9d4ecfeedc'/>
<id>55227d6d32deb49b9a8728d217eece9d4ecfeedc</id>
<content type='text'>
Currently, OpenStack Proposal Bot tries to update requirements with
global requirements, while the upgraded hacking has introduced some
new rules which are not fully handled by current code.

This patch fixes some simple rules which are quite straight-forward.

Change-Id: If8334f69fb1ad34fbbd6ad898e0e92eb3f81e95a
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Currently, OpenStack Proposal Bot tries to update requirements with
global requirements, while the upgraded hacking has introduced some
new rules which are not fully handled by current code.

This patch fixes some simple rules which are quite straight-forward.

Change-Id: If8334f69fb1ad34fbbd6ad898e0e92eb3f81e95a
</pre>
</div>
</content>
</entry>
<entry>
<title>use mock instead of try...finally</title>
<updated>2014-05-30T09:24:27+00:00</updated>
<author>
<name>ZhiQiang Fan</name>
<email>zhiqiang.fan@huawei.com</email>
</author>
<published>2014-05-30T09:20:47+00:00</published>
<link rel='alternate' type='text/html' href='http://git.baserock.org/cgit/delta/openstack/python-ceilometerclient.git/commit/?id=c343b184b80d339389a8af1b994f3e82187a6435'/>
<id>c343b184b80d339389a8af1b994f3e82187a6435</id>
<content type='text'>
There are some test code use try...finally block to catch or ignore
the stdout message. The job can be done by mock too, and it is cleaner.

Change-Id: I0c29382e7bcd0b7f399565b26f27315f7e17a8fc
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
There are some test code use try...finally block to catch or ignore
the stdout message. The job can be done by mock too, and it is cleaner.

Change-Id: I0c29382e7bcd0b7f399565b26f27315f7e17a8fc
</pre>
</div>
</content>
</entry>
<entry>
<title>Adds alarm time constraint support to ceilometer CLI</title>
<updated>2014-03-26T08:24:56+00:00</updated>
<author>
<name>Uros Jovanovic</name>
<email>uros.jovanovic@gmail.com</email>
</author>
<published>2014-03-05T18:49:14+00:00</published>
<link rel='alternate' type='text/html' href='http://git.baserock.org/cgit/delta/openstack/python-ceilometerclient.git/commit/?id=7146571b702579fa1367598ab278ca2f8ec1e156'/>
<id>7146571b702579fa1367598ab278ca2f8ec1e156</id>
<content type='text'>
Time constraints can be specified for create and update
families of commands with the following format:

--time-constraint name=constraint1;start='0 11 * * *';duration=300

This switch can be specified multiple times in the case of
multiple time constraints.

With update commands, time constraints are updated by name,
e.g. --time-constraint name=constraint1;duration=500 updates
the constraint 'constraint1' with a new duration 500.

Time constraints can be removed with update commands using the
switch --remove-time-constraint=constraint1,constraint2 .

Example of display outputs:

&gt; ceilometer alarm-list
+--------------------------------------+-------+-------------------+---------+------------+----------------------------+--------------------------------------------------------------+
| Alarm ID                             | Name  | State             | Enabled | Continuous | Alarm condition            | Time constraints                                             |
+--------------------------------------+-------+-------------------+---------+------------+----------------------------+--------------------------------------------------------------+
| 2ead776d-2fc7-47a2-b0bb-0f88dcefa457 | test2 | insufficient data | True    | False      | cpu == 50.0 during 1 x 60s | cons1 at 0 11 * * *  for 300s, cons2 at 0 23 * * *  for 600s |
+--------------------------------------+-------+-------------------+---------+------------+----------------------------+--------------------------------------------------------------+

&gt; ceilometer alarm-show -a
+---------------------------+-----------------------------------------------------------------------+
| Property                  | Value                                                                 |
+---------------------------+-----------------------------------------------------------------------+
| alarm_actions             | []                                                                    |
| alarm_id                  | 2ead776d-2fc7-47a2-b0bb-0f88dcefa457                                  |
| comparison_operator       | eq                                                                    |
| description               | Alarm when cpu is eq a avg of 50.0 over 60 seconds                    |
| enabled                   | True                                                                  |
| evaluation_periods        | 1                                                                     |
| exclude_outliers          | False                                                                 |
| insufficient_data_actions | []                                                                    |
| meter_name                | cpu                                                                   |
| name                      | test2                                                                 |
| ok_actions                | []                                                                    |
| period                    | 60                                                                    |
| project_id                | 962f75ad22c24cbf99d40d7b82718505                                      |
| query                     |                                                                       |
| repeat_actions            | False                                                                 |
| state                     | insufficient data                                                     |
| statistic                 | avg                                                                   |
| threshold                 | 50.0                                                                  |
| time_constraints          | [{name: cons1,                                                        |
|                           |   description: Time constraint at 0 11 * * * lasting for 300 seconds, |
|                           |   start: 0 11 * * *,                                                  |
|                           |   duration: 300},                                                     |
|                           |  {name: cons2,                                                        |
|                           |   description: Time constraint at 0 23 * * * lasting for 600 seconds, |
|                           |   start: 0 23 * * *,                                                  |
|                           |   duration: 600}]                                                     |
| type                      | threshold                                                             |
| user_id                   | 76f335df8e2f4c7e9e8185e26ea85759                                      |
+---------------------------+-----------------------------------------------------------------------+

&gt; ceilometer alarm-history -a 2ead776d-2fc7-47a2-b0bb-0f88dcefa457
+----------+----------------------------+--------------------------------------------------------------------------------+
| Type     | Timestamp                  | Detail                                                                         |
+----------+----------------------------+--------------------------------------------------------------------------------+
| creation | 2014-03-06T07:41:35.362050 | name: test2                                                                    |
|          |                            | description: Alarm when cpu is eq a avg of 50.0 over 60 seconds                |
|          |                            | type: threshold                                                                |
|          |                            | rule: cpu == 50.0 during 1 x 60s                                               |
|          |                            | time_constraints: cons1 at 0 11 * * *  for 300s, cons2 at 0 23 * * *  for 600s |
+----------+----------------------------+--------------------------------------------------------------------------------+

Change-Id: I3953276537b4526e46e5e6d229d6fa154f8ab0fc
Closes-Bug: #1288246
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Time constraints can be specified for create and update
families of commands with the following format:

--time-constraint name=constraint1;start='0 11 * * *';duration=300

This switch can be specified multiple times in the case of
multiple time constraints.

With update commands, time constraints are updated by name,
e.g. --time-constraint name=constraint1;duration=500 updates
the constraint 'constraint1' with a new duration 500.

Time constraints can be removed with update commands using the
switch --remove-time-constraint=constraint1,constraint2 .

Example of display outputs:

&gt; ceilometer alarm-list
+--------------------------------------+-------+-------------------+---------+------------+----------------------------+--------------------------------------------------------------+
| Alarm ID                             | Name  | State             | Enabled | Continuous | Alarm condition            | Time constraints                                             |
+--------------------------------------+-------+-------------------+---------+------------+----------------------------+--------------------------------------------------------------+
| 2ead776d-2fc7-47a2-b0bb-0f88dcefa457 | test2 | insufficient data | True    | False      | cpu == 50.0 during 1 x 60s | cons1 at 0 11 * * *  for 300s, cons2 at 0 23 * * *  for 600s |
+--------------------------------------+-------+-------------------+---------+------------+----------------------------+--------------------------------------------------------------+

&gt; ceilometer alarm-show -a
+---------------------------+-----------------------------------------------------------------------+
| Property                  | Value                                                                 |
+---------------------------+-----------------------------------------------------------------------+
| alarm_actions             | []                                                                    |
| alarm_id                  | 2ead776d-2fc7-47a2-b0bb-0f88dcefa457                                  |
| comparison_operator       | eq                                                                    |
| description               | Alarm when cpu is eq a avg of 50.0 over 60 seconds                    |
| enabled                   | True                                                                  |
| evaluation_periods        | 1                                                                     |
| exclude_outliers          | False                                                                 |
| insufficient_data_actions | []                                                                    |
| meter_name                | cpu                                                                   |
| name                      | test2                                                                 |
| ok_actions                | []                                                                    |
| period                    | 60                                                                    |
| project_id                | 962f75ad22c24cbf99d40d7b82718505                                      |
| query                     |                                                                       |
| repeat_actions            | False                                                                 |
| state                     | insufficient data                                                     |
| statistic                 | avg                                                                   |
| threshold                 | 50.0                                                                  |
| time_constraints          | [{name: cons1,                                                        |
|                           |   description: Time constraint at 0 11 * * * lasting for 300 seconds, |
|                           |   start: 0 11 * * *,                                                  |
|                           |   duration: 300},                                                     |
|                           |  {name: cons2,                                                        |
|                           |   description: Time constraint at 0 23 * * * lasting for 600 seconds, |
|                           |   start: 0 23 * * *,                                                  |
|                           |   duration: 600}]                                                     |
| type                      | threshold                                                             |
| user_id                   | 76f335df8e2f4c7e9e8185e26ea85759                                      |
+---------------------------+-----------------------------------------------------------------------+

&gt; ceilometer alarm-history -a 2ead776d-2fc7-47a2-b0bb-0f88dcefa457
+----------+----------------------------+--------------------------------------------------------------------------------+
| Type     | Timestamp                  | Detail                                                                         |
+----------+----------------------------+--------------------------------------------------------------------------------+
| creation | 2014-03-06T07:41:35.362050 | name: test2                                                                    |
|          |                            | description: Alarm when cpu is eq a avg of 50.0 over 60 seconds                |
|          |                            | type: threshold                                                                |
|          |                            | rule: cpu == 50.0 during 1 x 60s                                               |
|          |                            | time_constraints: cons1 at 0 11 * * *  for 300s, cons2 at 0 23 * * *  for 600s |
+----------+----------------------------+--------------------------------------------------------------------------------+

Change-Id: I3953276537b4526e46e5e6d229d6fa154f8ab0fc
Closes-Bug: #1288246
</pre>
</div>
</content>
</entry>
<entry>
<title>Update client to display data type of traits</title>
<updated>2014-01-24T17:39:05+00:00</updated>
<author>
<name>John Herndon</name>
<email>john.herndon@hp.com</email>
</author>
<published>2014-01-16T16:48:59+00:00</published>
<link rel='alternate' type='text/html' href='http://git.baserock.org/cgit/delta/openstack/python-ceilometerclient.git/commit/?id=deb34163afbb2ac7e00c74613812b3bea413a807'/>
<id>deb34163afbb2ac7e00c74613812b3bea413a807</id>
<content type='text'>
fixes bug 1268032

Change-Id: I47dfd3208fb3f7e5e5e2b33bd9b00c688d8283cd
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
fixes bug 1268032

Change-Id: I47dfd3208fb3f7e5e5e2b33bd9b00c688d8283cd
</pre>
</div>
</content>
</entry>
<entry>
<title>Fix order of sample list</title>
<updated>2013-10-28T00:08:40+00:00</updated>
<author>
<name>fujioka yuuichi</name>
<email>fujioka-yuuichi@zx.mxh.nes.nec.co.jp</email>
</author>
<published>2013-10-28T00:05:57+00:00</published>
<link rel='alternate' type='text/html' href='http://git.baserock.org/cgit/delta/openstack/python-ceilometerclient.git/commit/?id=1b0f94f20580a55bea52ba468bdeeca3dd4552bd'/>
<id>1b0f94f20580a55bea52ba468bdeeca3dd4552bd</id>
<content type='text'>
Samples of "ceilometer sample-list" are sorted by Resource ID and
Volume.
Expected order is Timestamp.

This pache fixes this problem.

Change-Id: I338014e5868b2176a3afd549e13d0dd6118b3ac1
Closes-Bug: #1227495
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Samples of "ceilometer sample-list" are sorted by Resource ID and
Volume.
Expected order is Timestamp.

This pache fixes this problem.

Change-Id: I338014e5868b2176a3afd549e13d0dd6118b3ac1
Closes-Bug: #1227495
</pre>
</div>
</content>
</entry>
<entry>
<title>Import six.StringIO</title>
<updated>2013-10-14T09:15:47+00:00</updated>
<author>
<name>Kui Shi</name>
<email>skuicloud@gmail.com</email>
</author>
<published>2013-10-14T08:52:23+00:00</published>
<link rel='alternate' type='text/html' href='http://git.baserock.org/cgit/delta/openstack/python-ceilometerclient.git/commit/?id=eaae72edc92940b0e46b7d7b955e2bfbe94542c5'/>
<id>eaae72edc92940b0e46b7d7b955e2bfbe94542c5</id>
<content type='text'>
six.StringIO
This is an fake file object for textual data. It is an alias for
StringIO.StringIO in Python 2 and io.StringIO in Python 3.

Partial Implement: blueprint py33-support

Change-Id: I76c05041565614241eea7b7595e4503c88211ee8
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
six.StringIO
This is an fake file object for textual data. It is an alias for
StringIO.StringIO in Python 2 and io.StringIO in Python 3.

Partial Implement: blueprint py33-support

Change-Id: I76c05041565614241eea7b7595e4503c88211ee8
</pre>
</div>
</content>
</entry>
<entry>
<title>Allow to update an alarm partially</title>
<updated>2013-10-01T16:05:17+00:00</updated>
<author>
<name>Mehdi Abaakouk</name>
<email>mehdi.abaakouk@enovance.com</email>
</author>
<published>2013-09-26T07:50:37+00:00</published>
<link rel='alternate' type='text/html' href='http://git.baserock.org/cgit/delta/openstack/python-ceilometerclient.git/commit/?id=66ef360c1480899bcdf6ad7af8f2d581b532c5e6'/>
<id>66ef360c1480899bcdf6ad7af8f2d581b532c5e6</id>
<content type='text'>
The patch allow to only modify a part of an alarm instead of force to
set the full alarm description.

This permit to an application that have been written code around alarm
with ceilometerclient 1.0.4 and ceilometer pre havana-3. To update alarm
without any change with this and ceilometer &gt;= havana-3 (ie: heat).

Fixes bug #1231303

Change-Id: I20250131d05d20bfadbca450dfe6b8237f4b7183
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
The patch allow to only modify a part of an alarm instead of force to
set the full alarm description.

This permit to an application that have been written code around alarm
with ceilometerclient 1.0.4 and ceilometer pre havana-3. To update alarm
without any change with this and ceilometer &gt;= havana-3 (ie: heat).

Fixes bug #1231303

Change-Id: I20250131d05d20bfadbca450dfe6b8237f4b7183
</pre>
</div>
</content>
</entry>
</feed>
