Add new endpoint /activity that returns active queries

This commit is contained in:
Dan Sosedoff
2015-03-21 11:46:14 -05:00
parent fa8f3a2997
commit 38ecb5ffc4
3 changed files with 30 additions and 0 deletions

View File

@@ -127,6 +127,11 @@ func (client *Client) TableIndexes(table string) (*Result, error) {
return res, err
}
// Returns all active queriers on the server
func (client *Client) Activity() (*Result, error) {
return client.Query(PG_ACTIVITY)
}
func (client *Client) Query(query string) (*Result, error) {
res, err := client.query(query)