<br><font size=2 face="sans-serif">Hi all,</font>
<br>
<br><font size=2 face="sans-serif">I use aodh cli to create a event alarm
with query condition, the cli runs successfully.</font>
<br><font size=2 face="sans-serif">But when i want to update the query
condition, the cli runs failed.</font>
<br><font size=2 face="sans-serif">The help info about `--query` para with
these two cli have no difference. </font>
<br><font size=2 face="sans-serif">The information is as follows, Does
anyone else know why? Thanks~</font>
<br><font size=2 face="sans-serif"><br>
</font><font size=3>stack@cloud:~$ </font><font size=3 color=blue>aodh
alarm create</font><font size=3> --name test --type event --event-type
compute.instance.update </font><font size=3 color=blue>--query "traits.instance_id=string::3ed4fbc1-023e-4c4e-85d3-cf6d73c9ac49"</font>
<br><font size=3>+---------------------------+-----------------------------------------------------------+</font>
<br><font size=3>| Field
| Value
|</font>
<br><font size=3>+---------------------------+-----------------------------------------------------------+</font>
<br><font size=3>| alarm_actions
| []
|</font>
<br><font size=3>| alarm_id
| 8d1018bd-8f14-4f34-b47c-54588488d658
|</font>
<br><font size=3>| description
| Alarm when compute.instance.update event occurred.
|</font>
<br><font size=3>| enabled
| True
|</font>
<br><font size=3>| event_type
| compute.instance.update
|</font>
<br><font size=3>| insufficient_data_actions | []
|</font>
<br><font size=3>| name
| test
|</font>
<br><font size=3>| ok_actions
| []
|</font>
<br><font size=3>| project_id
| f0895991f44044ccba8e62b201b70360
|</font>
<br><font size=3>| query
| traits.instance_id = 3ed4fbc1-023e-4c4e-85d3-cf6d73c9ac49
|</font>
<br><font size=3>| repeat_actions |
False
|</font>
<br><font size=3>| severity
| low
|</font>
<br><font size=3>| state
| insufficient data
|</font>
<br><font size=3>| state_timestamp |
2016-11-29T06:31:50.094836
|</font>
<br><font size=3>| time_constraints |
[]
|</font>
<br><font size=3>| timestamp
| 2016-11-29T06:31:50.094836
|</font>
<br><font size=3>| type
| event
|</font>
<br><font size=3>| user_id
| 7d7531a2030d4537b60a5193bf6ab286
|</font>
<br><font size=3>+---------------------------+-----------------------------------------------------------+</font>
<br><font size=3>stack@cloud:~$ </font>
<br><font size=3>stack@cloud:~$ </font>
<br><font size=3>stack@cloud:~$ </font><font size=3 color=blue>aodh alarm
update</font><font size=3> 8d1018bd-8f14-4f34-b47c-54588488d658 --event-type
computer.instance.delete </font><font size=3 color=blue>--query "traits.instance_id=string::3ed4fbc1-023e-4c4e-85d3-cf6d73c9ac88"</font>
<br><font size=3 color=red>Invalid input for field/attribute </font><font size=3>data.
Value: '{'alarm_actions': [], 'event_rule': {'query': 'traits.instance_id=string::3ed4fbc1-023e-4c4e-85d3-cf6d73c9ac88',
'event_type': 'computer.instance.delete'}, 'ok_actions': [], 'name': 'test',
'state': 'insufficient data', 'timestamp': '2016-11-29T06:31:50.094836',
'enabled': True, 'state_timestamp': '2016-11-29T06:31:50.094836', 'severity':
'low', 'alarm_id': '8d1018bd-8f14-4f34-b47c-54588488d658', 'time_constraints':
[], 'insufficient_data_actions': [], 'repeat_actions': False, 'user_id':
'7d7531a2030d4537b60a5193bf6ab286', 'project_id': 'f0895991f44044ccba8e62b201b70360',
'type': 'event', 'description': 'Alarm when compute.instance.update event
occurred.'}'. Value not a valid list: traits.instance_id=string::3ed4fbc1-023e-4c4e-85d3-cf6d73c9ac88
(HTTP 400) (Request-ID: req-ad8bd440-2784-43b7-98d7-7e0ae27dcebc)</font>
<br><font size=3>stack@cloud:~$ <br>
<br>
</font>
<br>