Description of problem: Ceilometer in openstack mitaka has disabled events filtering by gt (greater than) on timestamp, so calls to ceilometer return error "Operator gt is not supported. Only equality operator is available for field start_timestamp" Version-Release number of selected component (if applicable): How reproducible: always with required configuration Steps to Reproduce: 1. setup manageiq/cfme and openstack (tested on rdo mitaka from delorean) with ceilometer enabled 2. add cloud provider, don't fill provider events fields 3. check log (log/evm.log) Actual results: No events are loaded, getting errors into log. Expected results: Events are loaded in to app, no ceilometer error in log. Additional info: Ceilometer people disabled this feature (https://bugs.launchpad.net/ceilometer/+bug/1558594/comments/2) we should start using a different API call. Getting error from fog metering "Operator gt is not supported. Only equality operator is available for field start_timestamp": [----] I, [2016-05-17T14:06:08.258224 #17810:2b0cef17f670] INFO -- : Reseting Openstack Ceilometer connection after Expected(200) <=> Actual(400 Bad Request) excon.error.response :body => "{\"error_message\": {\"debuginfo\": null, \"faultcode\": \"Client\", \"faultstring\": \"Operator gt is not supported. Only equality operator is available for field start_timestamp\"}}" :cookies => [ ] :headers => { "Content-Length" => "171" "Content-Type" => "application/json" "Date" => "Tue, 17 May 2016 12:06:08 GMT" "Server" => "Werkzeug/0.9.1 Python/2.7.5" "x-openstack-request-id" => "req-b5c690da-94f4-4d74-b394-4bbb52dd356f" } :host => "192.0.2.6" :local_address => "10...." :local_port => 47042 :path => "/v2/events" :port => 8777 :reason_phrase => "Bad Request" :remote_ip => "192.0.2.6" :status => 400 :status_line => "HTTP/1.0 400 Bad Request\r\n"
This sounds like a bug in OpenStack. Did the gt operator work in Liberty? If so, can we get some clarity from OpenStack why they disabled the gt operator? In the meantime, I guess we have to figure out how to work with eq.
I don't have liberty installation at the moment. @rrasouli What openstack version did you use to verify ceilometer events?
This has never worked, it just did not raise any error before. This commits explain it correctly: https://github.com/openstack/ceilometer/commit/ac3ff88c03ea3685d7f3511bbae16785646e56ba If you would really want that to work, you should probably open a RFE on Ceilometer I guess.
I am not sure if it was planned or not, but e.g. ceilometer in kilo worked (almost) as expected - http://paste.openstack.org/show/497913/ @jd Isn't there a different way quering events based on time? (docs I read says nothing about filtering restrictions), thanks.
Liberty should be OK at the moment. But there is a ceilometer patch backporting the operator disable code (which causes this bug) up for review. We do NOT want merge following patch to Ceilometer in Liberty https://review.openstack.org/#/c/296907/
@maufart the version I am using is liberty RHOS8
https://github.com/ManageIQ/manageiq/pull/9805
New commit detected on ManageIQ/manageiq/master: https://github.com/ManageIQ/manageiq/commit/189b59a2dbbb3d51b8ed3142f62d30139817adaa commit 189b59a2dbbb3d51b8ed3142f62d30139817adaa Author: Marek Aufart <maufart> AuthorDate: Thu Jul 14 10:29:31 2016 +0200 Commit: Marek Aufart <maufart> CommitDate: Thu Jul 14 13:03:32 2016 +0200 Fix Ceilometer Events for Openstack 9 Ceilometer Events query now uses 'ge' operator instead of 'gt' because only 'eq', 'ge', 'le' operators are allowed in Ceilomemeter API since Mitaka release (9) - rhbz#1337961. This change works on older Openstack versions with Ceilometer too. https://bugzilla.redhat.com/show_bug.cgi?id=1337429 gems/pending/openstack/events/openstack_ceilometer_event_monitor.rb | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
'ge' doesn't work either on mitaka: [----] E, [2016-08-11T02:02:14.180183 #4939:52d6d24] ERROR -- : excon.error #<Excon::Error::BadRequest: Expected(200) <=> Actual(400 Bad Request) excon.error.response :body => "{\"error_message\": {\"debuginfo\": null, \"faultcode\": \"Client\", \"faultstring\": \"Operator ge is not supported. Only equality operator is available for field start_timestamp\"}}" :cookies => [ ] :headers => { "Connection" => "close" "Content-Length" => "171" "Content-Type" => "application/json" "Date" => "Thu, 11 Aug 2016 06:02:14 GMT" "Server" => "Apache/2.4.6 (CentOS)" "x-openstack-request-id" => "req-df5a33a5-cf93-4541-8973-17ffae10b18a" }
You might need update OpenStack Ceilometer package to current stable in Mitaka. What version of Ceilometer do you use? Ceilometer change which enabled 'ge' operator was backported to Mitaka in https://review.openstack.org/#/c/341096/
Yep, that works, thanks.
verified on 5.7.0.4