postgres-vacuum-monitor 0.5.0 → 0.6.0

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: e764680ab6a464db250c1c47b04cef57d9662760c388daf96bf73987f542ba2d
4
- data.tar.gz: 6fca9d4989d2c9db092ff78a6ec2429053e0600b4ea1c31f1226d986c6cf20ef
3
+ metadata.gz: 0fee499969b39fb4a978796ea02938e41b3bcfd2bc9cc359c6ccd7bc3f899baf
4
+ data.tar.gz: 8560faf84d65d94e45bcaff906ca32ec85f2e8f2f917445f5fb2ed26eb162196
5
5
  SHA512:
6
- metadata.gz: 6477ea77d2c5b0d7e3f926ec794c69df057c7cc94026789e341c1e1318b8739e3d36d2eef26003b124ea7f63b10d74f6237ade609c6c2fa6d6986f399b6879df
7
- data.tar.gz: 49b19ea6107c6771d7c3bce1690ba294cc8e0ecb9d378f0cb08afa574b6d99350c72201ced9390db7b2c55a516f4a6ce13b5dfa3638aa6bd2939160b6cc549d3
6
+ metadata.gz: a56a0f9106ed71b00cfe4121065a441ffbf35c5365217d1e2f0ac4ae7d41dfbd6d7ba1b8693727f06bed87c8ebe2d73358aed33bbd8fdd16d70af9f1ee2437e9
7
+ data.tar.gz: 3c1c355e1fd736f397faef12c9ca96520b2266a7747fd65db49da17bd752c99d1d11db09d943b324ddb05e65c2bfdb7fe6ec441720a436b8fcddba1a3f95679e
@@ -1,4 +1,7 @@
1
1
  # postgres-vacuum-monitor
2
+ ## v.0.5.0
3
+ - Add `wait_event_type`, `transaction_id` and `min_transaction_id` to `LongTransactions` events.
4
+
2
5
  ## v.0.5.0
3
6
  - Renamed `LongQueries` event to `LongTransactions`.
4
7
  - Renamed `LongTransactions.query` to `LongTransactions.most_recent_query` and added a
data/README.md CHANGED
@@ -52,7 +52,10 @@ For long running transactions, the event name is `LongTransactions` and the attr
52
52
  running_time: # How long has it been running in seconds.
53
53
  application_name: # What's the application name that is running the query.
54
54
  most_recent_query: # The last query started by the transaction
55
- state: # The state of the transaction - either "active" or ""
55
+ state: # The state of the transaction - either "active" or "idle in transaction"
56
+ wait_event_type: # The type of lock the transaction is waiting for if applicable
57
+ transaction_id: # The transaction_id which will be null for read-only transactions
58
+ min_transaction_id: # The mininum transaction id horizon
56
59
  }
57
60
  ```
58
61
 
@@ -16,7 +16,10 @@ module Postgres
16
16
  running_time: row['seconds'],
17
17
  application_name: row['application_name'],
18
18
  most_recent_query: row['query'],
19
- state: row['state']
19
+ state: row['state'],
20
+ wait_event_type: row['wait_event_type'],
21
+ transaction_id: row['backend_xid'],
22
+ min_transaction_id: row['backend_xmin']
20
23
  )
21
24
  end
22
25
 
@@ -21,7 +21,10 @@ module Postgres
21
21
  EXTRACT(EPOCH FROM (now() - xact_start)) AS seconds,
22
22
  application_name,
23
23
  query,
24
- state
24
+ state,
25
+ backend_xid,
26
+ backend_xmin,
27
+ wait_event_type
25
28
  FROM pg_stat_activity
26
29
  WHERE state IN (#{STATES.join(', ')})
27
30
  ORDER BY seconds DESC
@@ -1,7 +1,7 @@
1
1
  module Postgres
2
2
  module Vacuum
3
3
  module Monitor
4
- VERSION = '0.5.0'.freeze
4
+ VERSION = '0.6.0'.freeze
5
5
  end
6
6
  end
7
7
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: postgres-vacuum-monitor
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.5.0
4
+ version: 0.6.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Fernando Garces
8
8
  autorequire:
9
9
  bindir: exe
10
10
  cert_chain: []
11
- date: 2020-02-06 00:00:00.000000000 Z
11
+ date: 2020-02-07 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: appraisal