Merge lp:~lifeless/python-oops-tools/amqp-polish into lp:python-oops-tools

Proposed by Robert Collins
Status: Merged
Approved by: Robert Collins
Approved revision: no longer in the source branch.
Merged at revision: 9
Proposed branch: lp:~lifeless/python-oops-tools/amqp-polish
Merge into: lp:python-oops-tools
Diff against target: 38 lines (+10/-0)
2 files modified
src/oopstools/NEWS.txt (+7/-0)
src/oopstools/scripts/amqp2disk.py (+3/-0)
To merge this branch: bzr merge lp:~lifeless/python-oops-tools/amqp-polish
Reviewer Review Type Date Requested Status
Steve Kowalik (community) code Approve
Review via email: mp+80864@code.launchpad.net

Commit message

Polish to make the amqp oops experience more reliable and pleasant.

Description of the change

Polish to make the amqp oops experience more reliable and pleasant.

To post a comment you must log in.
Revision history for this message
Steve Kowalik (stevenk) :
review: Approve (code)
9. By Robert Collins

Polish to make the amqp oops experience more reliable and pleasant.

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
=== modified file 'src/oopstools/NEWS.txt'
--- src/oopstools/NEWS.txt 2011-10-31 02:07:57 +0000
+++ src/oopstools/NEWS.txt 2011-11-01 03:09:25 +0000
@@ -5,6 +5,13 @@
5NEXT5NEXT
6====6====
77
8* Flush stdout when logging an OOPS receipt in amqp2disk.
9 (Robert Collins, #884569)
10
11* Force received OOPS ids to uppercase in amqp2disk to fit in with the UI
12 - otherwise they cannot be accessed.
13 (Robert Collins, #884571)
14
80.6.1150.6.1
9=====16=====
1017
1118
=== modified file 'src/oopstools/scripts/amqp2disk.py'
--- src/oopstools/scripts/amqp2disk.py 2011-10-18 14:18:51 +0000
+++ src/oopstools/scripts/amqp2disk.py 2011-11-01 03:09:25 +0000
@@ -106,6 +106,7 @@
106 if options.verbose:106 if options.verbose:
107 def print_oops(report):107 def print_oops(report):
108 print ("Received %s" % report['id'])108 print ("Received %s" % report['id'])
109 sys.stdout.flush()
109 config.publishers.append(print_oops)110 config.publishers.append(print_oops)
110 receiver = oops_amqp.Receiver(config, factory, options.queue)111 receiver = oops_amqp.Receiver(config, factory, options.queue)
111 try:112 try:
@@ -119,6 +120,8 @@
119 # the first publisher will either inherit or assign, so this should be120 # the first publisher will either inherit or assign, so this should be
120 # impossible.121 # impossible.
121 assert report['id'] is not None122 assert report['id'] is not None
123 # Fit in with the upper-case assumption in oops-tools.
124 report['id'] = report['id'].upper()
122 # Some fallback methods could lead to duplicate paths into the DB: exit125 # Some fallback methods could lead to duplicate paths into the DB: exit
123 # early if the OOPS is already loaded.126 # early if the OOPS is already loaded.
124 try:127 try:

Subscribers

People subscribed via source and target branches

to all changes: