Skip to content
Browse files

added slowlog len, removed some other totals we also monitored, and s…

…topped deleting the tags
  • Loading branch information...
1 parent 34e9a01 commit 2242182a23fd3f26160727e28f556b7a96324875 @truthtrap truthtrap committed Mar 26, 2012
Showing with 24 additions and 21 deletions.
  1. +7 −5 leave.py
  2. +17 −16 monitor.py
View
12 leave.py
@@ -55,12 +55,14 @@ def log(message, logging='info'):
if __name__ == '__main__':
log('leaving the cluster', 'info')
- try:
+ #try:
+ # do not remove the tag, we might want to work on this later
+
# delete all there is to us
- log('unset the tag', 'info')
- ec2.unset_tag()
- except Exception as e:
- log(e, 'error')
+ #log('unset the tag', 'info')
+ #ec2.unset_tag()
+ #except Exception as e:
+ #log(e, 'error')
try:
log('delete the Route53 record', 'info')
View
33 monitor.py
@@ -66,6 +66,11 @@ def collect(self):
dimensions = { 'node' : self.node,
'cluster' : self.cluster }
+ slowlog_len = self.redis.execute_command('SLOWLOG','LEN')
+ names.append('slowlog_len')
+ values.append(slowlog_len)
+ units.append('Count')
+
if items['aof_enabled']:
names.append('bgrewriteaof_in_progress')
values.append(items['bgrewriteaof_in_progress'])
@@ -189,13 +194,13 @@ def collect(self):
units.append('Count')
# connection/command totals
- names.append('total_connections_received')
- values.append(items['total_connections_received'])
- units.append('Count')
+ #names.append('total_connections_received')
+ #values.append(items['total_connections_received'])
+ #units.append('Count')
- names.append('total_commands_processed')
- values.append(items['total_commands_processed'])
- units.append('Count')
+ #names.append('total_commands_processed')
+ #values.append(items['total_commands_processed'])
+ #units.append('Count')
# client input/output
names.append('client_biggest_input_buf')
@@ -221,13 +226,13 @@ def collect(self):
units.append('Count')
# keyspace
- names.append('keyspace_misses')
- values.append(items['keyspace_misses'])
- units.append('Count')
+ #names.append('keyspace_misses')
+ #values.append(items['keyspace_misses'])
+ #units.append('Count')
- names.append('keyspace_hits')
- values.append(items['keyspace_hits'])
- units.append('Count')
+ #names.append('keyspace_hits')
+ #values.append(items['keyspace_hits'])
+ #units.append('Count')
return [names, values, units, dimensions]
@@ -238,10 +243,6 @@ def put(self):
if self.userdata['cloudwatch'] == "on":
# first get all we need
[names, values, units, dimensions] = self.collect()
- print names
- print values
- print units
- print dimensions
while len(names) > 0:
names20 = names[:20]
values20 = values[:20]

0 comments on commit 2242182

Please sign in to comment.
Something went wrong with that request. Please try again.