[RDF] Asking for the entire RSS feed can easily fill mozbot's queue

VERIFIED FIXED in 2.6

Status

P4
normal
VERIFIED FIXED
14 years ago
9 years ago

People

(Reporter: mkanat, Assigned: mkanat)

Tracking

Points:
---

Firefox Tracking Flags

(Not tracked)

Details

(Whiteboard: [has-patch])

Attachments

(1 attachment, 1 obsolete attachment)

(Assignee)

Description

14 years ago
In Fedora, we have an RSS feed that has about 320 items in it, the "Rawhide"
feed. That's not just today, that's for a few weeks.

If I send my bot a /msg of "Rawhide", I get... 320 responses. Or really, what
actually happens is that I get mozbot's queue full for about ten minutes, and he
never responds to anything else, and just keeps spamming me.

I think that he should either be hard-limited, or the RDF module needs a
maxTotal or maxLines variable.
(Assignee)

Comment 1

14 years ago
This is pretty easy, I can do it myself.
Assignee: ian → mkanat
Target Milestone: --- → Mozbot 2.6
(Assignee)

Comment 2

14 years ago
Created attachment 182249 [details] [diff] [review]
Add a maxLines parameter to the RDF module

This adds a "maxLines" var to the RDF module, and trims the @output from
ReportAll if it's longer than 20 lines (not including the first, "banner"
line).
Attachment #182249 - Flags: review?(ian)
Comment on attachment 182249 [details] [diff] [review]
Add a maxLines parameter to the RDF module

Looks good overall, but if you're going to use double-quoted strings, please interpolate the variables. As in:

unshift(@output, "The list is longer than $self->{'maxLines'}  lines, only the first $self->{'maxLines'} will be shown.");
Attachment #182249 - Flags: review?(ian) → review-
(Assignee)

Comment 4

13 years ago
Created attachment 216810 [details] [diff] [review]
v2

Okay, I changed it to interpolate the variables. :-)
Attachment #182249 - Attachment is obsolete: true
Attachment #216810 - Flags: review?(ian)
QA Contact: kerz → mozbot

Updated

10 years ago
Whiteboard: [has-attachment]

Updated

10 years ago
Attachment #216810 - Flags: review?(ian) → review+

Updated

10 years ago
Priority: -- → P4
Whiteboard: [has-attachment] → [has-patch]

Comment 5

10 years ago
Checking in BotModules/RDF.bm;
/cvsroot/mozilla/webtools/mozbot/BotModules/RDF.bm,v  <--  RDF.bm
new revision: 2.3; previous revision: 2.2
done
Status: NEW → RESOLVED
Last Resolved: 10 years ago
Resolution: --- → FIXED
Verified Fixed.

However, I think it loads 21 items instead of 20.  I will open a new bug for that.

Output for Planet:

[Thursday 11:20:17]	>firebot<	Planet
[Thursday 11:20:33]	*firebot*	The list is longer than 20 lines, only the first 20 will be shown.
[Thursday 11:20:36]	tmyoung: Items in Planet Mozilla - http://planet.mozilla.org/: Paul Rouget: Extend Firefox Contest - Hack & Be Creative
[Thursday 11:20:37]	tmyoung: Mozilla Web-Tech Blog: Background images no longer restricted to original size: explore the space with background-size
[Thursday 11:20:38]	tmyoung: about:mozilla: about:mozilla – One billion, Theora, add-ons tour, Chocolate Factory, Mozilla.org, Bugzilla, and more…
[Thursday 11:20:39]	tmyoung: Andrew Sutherland: Using VMWare Record/Replay and VProbes for low time-distortion performance profiling
[Thursday 11:20:40]	tmyoung: Mozilla Developer DevNews: Firefox 3.5.2 and 3.0.13 security updates now available for download
[Thursday 11:20:42]	tmyoung: European Mozilla Community Blog: Firefox rocked the Vieilles Charrues music festival in France
[Thursday 11:20:44]	tmyoung: Curtis Bartley: Building Firefox under Eclipse/CDT, or I gotta have my identifier completion
[Thursday 11:20:46]	tmyoung: Planet Mozilla Interns: Pejman Pour-Moezzi: The unbearable heaviness of mobile applications
[Thursday 11:20:48]	tmyoung: The Mozilla Blog: Firefox 3.5.2 and 3.0.13 security updates now available for download
[Thursday 11:20:50]	tmyoung: Meeting Notes from the Mozilla community: Mozilla Platform Meeting Minutes: 2009-08-04
[Thursday 11:20:52]	tmyoung: Meeting Notes from the Mozilla community: Mozilla Project Meeting Minutes: 2009-08-03
[Thursday 11:20:55]	tmyoung: Mike Kristoffersen: configure: error: Ogg support on Linux requires the alsa library
[Thursday 11:20:57]	tmyoung: Dion Almaer: The secret to productive software development: Creating the Happy Path -- Francesco Lodolo: 1 Billion
[Thursday 11:20:59]	tmyoung: Planet Mozilla Interns: William Reynolds: Getting to know the Campus Reps (Part 1) -- David Dahl: Timeline Hacking
[Thursday 11:21:01]	tmyoung: Meeting Notes from the Mozilla community: Thunderbird Meeting Minutes: 2009-08-04 -- Mikeal Rogers: Mutual Benefit
[Thursday 11:21:03]	tmyoung: QMO Events: Software Engineering Research at the Florida Institute of Technology -- Calendar: How to Save Sunbird
[Thursday 11:21:05]	tmyoung: Planet Mozilla Interns: Michael Sullivan: Doing whole tree analysis with Dehydra -- Chris AtLee: Faster signing
[Thursday 11:21:07]	tmyoung: Frederic Wenzel: Why Wikipedia might need a fail-pet — and why Mozilla does not -- Eric Shepherd: Unit testing MDC
[Thursday 11:21:09]	tmyoung: Mitchell Baker: Building the Open Web — Jesse Dylan and Elizabeth Stark today -- Joshua Cranmer: More jshydra news
[Thursday 11:21:11]	tmyoung: Paul Rouget: [Mozilla Camp Europe 2009] Developers & Advocates - We need you -- Robert Accettura: Google Buys On2
[Thursday 11:21:13]	tmyoung: Meeting Notes from the Mozilla community: Places Meeting Minutes: 2009-08-03 -- Alex Faaborg: The New Firefox Icon
Status: RESOLVED → VERIFIED
I have filed Bug 508844 for the extra item issue.  I have assigned it to me, and I will have a patch ready soon.
You need to log in before you can comment on or make changes to this bug.