Algatux / influxdb-bundle

Bundle service integration of official influxdb/influxdb-php client
MIT License
24 stars 14 forks source link

Queries profiler #56

Open soullivaneuh opened 8 years ago

soullivaneuh commented 8 years ago

It would be a very great addition to have Influx-db queries listing on the profiler.

Like Doctrine does:

image

image

What do you think?

Algatux commented 8 years ago

Will be good

Algatux commented 8 years ago

@Soullivaneuh Any idea on how to achieve this goal ? How can we get the executed queries using directly the influxdb library ?

soullivaneuh commented 8 years ago

Right now, I have absolutely no idea. :stuck_out_tongue:

I have to dig onto the Doctrine bundle code to see how it works.

Algatux commented 8 years ago

In doctrine I think uses internal events to catch queries.

It s something we cannot do without wrapping the influxdb connection IMHO

Il 21 lug 2016 09:57, "Sullivan SENECHAL" notifications@github.com ha scritto:

Right now, I have absolutely no idea. 😛

I have to dig onto the Doctrine bundle code to see how it works.

— You are receiving this because you commented. Reply to this email directly, view it on GitHub https://github.com/Algatux/influxdb-bundle/issues/56#issuecomment-234183245, or mute the thread https://github.com/notifications/unsubscribe-auth/AA2QIJtJc1FxuGHrajMAV4WWhruPD5rAks5qXyZYgaJpZM4JOyav .

soullivaneuh commented 8 years ago

It s something we cannot do without wrapping the influxdb connection IMHO

So let's wrapping it! :smile:

Algatux commented 8 years ago

Let's investigate a litte more first :smile_cat:

Algatux commented 7 years ago

@Soullivaneuh I've reached good results with a wrap of the connection class in a mongodb bundle (https://github.com/facile-it/mongodb-bundle), if you are ok with a similar approach I will try to apply the same strategy here

soullivaneuh commented 7 years ago

@Algatux Could you please elaborate your strategy?

As I understood, the mongo connection is from another library, but I guess it gives you the right information.

I'm not sure we can have this with influx...

Algatux commented 7 years ago

@Soullivaneuh as u can see here https://github.com/facile-it/mongodb-bundle/blob/cb81a76b73bec5beff24c849d4d124016ef8a530/src/Capsule/Collection.php wrapping the influx CLient class in the same mode will grant us all the informations we need (methods: selectDb, query and write).