Re: [openstack-dev] [Panko] Ways to go through events in the order they appear in database

2017-09-06 Thread Mikhail Kebich
On Tue, Sep 5, 2017 at 9:27 PM, gordon chung wrote: > i imagine if we were to support the ability to see event3 even if the > marker is event4, we'd need to do what Jay suggested, and add a > recorded_at/created_at field. supporting sorting by id as i previously > suggested is

Re: [openstack-dev] [Panko] Ways to go through events in the order they appear in database

2017-09-05 Thread gordon chung
On 05/09/17 09:27 AM, Jay Pipes wrote: > > Why not sort by created date/timestamp? Wouldn't that give you the same > behaviour (for the most part). we actually do that by default currently. the issue Mikhail ran into was because the timestamp we store is the timestamp of the message, not the

Re: [openstack-dev] [Panko] Ways to go through events in the order they appear in database

2017-09-05 Thread Jay Pipes
On 09/05/2017 08:44 AM, gordon chung wrote: On 04/09/17 11:17 AM, Mikhail Kebich wrote: Hello Gordon, Any feedback? Did you get a chance to take a look at the cursor api prototype? Thanks, Mike On Wed, Aug 30, 2017 at 6:00 PM, Mikhail Kebich wrote: On Wed, Aug 30,

Re: [openstack-dev] [Panko] Ways to go through events in the order they appear in database

2017-09-05 Thread gordon chung
On 04/09/17 11:17 AM, Mikhail Kebich wrote: > Hello Gordon, > > Any feedback? Did you get a chance to take a look at the cursor api prototype? > > Thanks, > Mike > > On Wed, Aug 30, 2017 at 6:00 PM, Mikhail Kebich > wrote: >> On Wed, Aug 30, 2017 at 4:22 PM, gordon

Re: [openstack-dev] [Panko] Ways to go through events in the order they appear in database

2017-09-04 Thread Mikhail Kebich
Hello Gordon, Any feedback? Did you get a chance to take a look at the cursor api prototype? Thanks, Mike On Wed, Aug 30, 2017 at 6:00 PM, Mikhail Kebich wrote: > On Wed, Aug 30, 2017 at 4:22 PM, gordon chung wrote: >> ah, i see. iirc, we can choose

Re: [openstack-dev] [Panko] Ways to go through events in the order they appear in database

2017-08-30 Thread gordon chung
On 2017-08-30 08:45 AM, Mikhail Kebich wrote: > Assume, that I made a request after events 1, 2, 3 and 4 were added to > the database. After some time events 5, 6, 7, 8 and 9 were added to > the database. I made another request to get the rest of events and > received only events 8, 9 because of

Re: [openstack-dev] [Panko] Ways to go through events in the order they appear in database

2017-08-30 Thread Mikhail Kebich
Hello Gordon, Thank you for the feedback. > i'm having trouble understanding the issue. the marker (message_id in > this case) denotes the starting point of query. not sure why you would > expect message_id4 to show up if message_id3 is newer. In the case described above message_id3 is not

Re: [openstack-dev] [Panko] Ways to go through events in the order they appear in database

2017-08-29 Thread gordon chung
On 2017-08-29 06:28 AM, Mikhail Kebich wrote: > Hello Telemetry Team, > > I see that the Panko API does not provide a way to go through all events > in the order they were stored in database. Panko sorts events by > generated and message_id fields and uses message_id field as a marker > for

[openstack-dev] [Panko] Ways to go through events in the order they appear in database

2017-08-29 Thread Mikhail Kebich
Hello Telemetry Team, I see that the Panko API does not provide a way to go through all events in the order they were stored in database. Panko sorts events by generated and message_id fields and uses message_id field as a marker for pagination. So, the following case is possible: Before the