We relaunched the TWiki.org project with an expanded TWiki charter, and we invite you to participate! The TWiki.org Code of Conduct agreement took effect on 27 Oct 2008. We ask existing twiki.org users to opt-in. You need to opt-in to participate in the Blog, Codev, Plugins and TWiki webs. -- PeterThoeny - 27 Oct 2008
You are here: TWiki> Plugins Web>BugzillaQueryPlugin (27 Aug 2008, SaschaVetter)
Tags:
bugs1Add my vote for this tag database1Add my vote for this tag integration1Add my vote for this tag create new tag
, view all tags

BugzillaQueryPlugin

This plugin allows you to make links to Bugzilla or directly query Bugzilla for data and results could be formated. I take a vision from BugzillaLinkPlugin but it doesn't fulfil all needs of our company.


THIS VERSION OF PLUGIN WORKS FINE WITH BUGZILLA 2.16.x OR LATER!!

Syntax Rules

  • %BGQ{"12"}%
  • %BGQ{"12, 25, 200"}%
  • %BGQ{data="on" bug_status="NEW, ASSIGNED, REOPENED" product="xxx" target_milestone="yyy"}%
  • %BGQ{data="on" bug_status!="CLOSED" product="xxx" target_milestone!="yyy"}%
  • %BGQ{data="on" bug_status="NEW, ASSIGNED" product="xxx" reporter="*mike*"}%

Allowed attributes

Attributes are named by columns in 'bugs' table in DB. It means you can use attributes "bug_id", "bug_status", "reporter", "target_milestone" etc. If you need to search by keywords then use attribute "keyword".

There are these 'special' attributes:

  • data - if set to "on" you get directly data from database
  • format - you can specify the output

Bugzilla attributes (for bugzilla v3.1.4):

  • Basic bug entries: alias, assigned_to, bug_file_loc, bug_id, bug_severity, bug_status, creation_ts, deadline, delta_ts, estimated_time, lastdiffed, priority, remaining_time, short_desc, votes
  • Additional: product, keyword, component, qa_contact, reporter, assigned_to

For more information about the bugzilla database schema, see BugzillaSchema

Syntax and variables in 'format' attribute

You can use the same naming conventions as for attributes and put before it the character '$'.
Examples:
  • format="| $bug_id | $bug_status | $assigned_to |"
123 NEW an_user@bugzillaPLEASENOSPAM.com
234 RESOLVED another_user@bugzillaPLEASENOSPAM.com
  • format="Bug $bug_id is in status $bug_status and was assigned to $assigned_to"
Bug 123 is in status NEW and was assigned to an_user@bugzilla.com
Bug 234 is in status RESOLVED and was assigned to another_user@bugzilla.com

Wildcard Patterns

Since version 1.04, BugzillaQueryPlugin handles wildcard patterns. Wildcard patterns are well known to people who are used to command lines on computers, but may be unfamiliar to the Windows generation. A wildcard is a special string that you can put into a filename so that it matches a whole range of files:
String What it does Example What the example matches
* Matches any string, including an empty string. *Cheese* Every topic with "Cheese" somewhere in the name (but not "cheese")
? Matches any single character. Example1? Example10 and Example 1X but not example1

Examples

  • %BGQ{"12"}%
  • %BGQ[bug_id="12"]%
  • %BGQ{"12, 25, 200"}%
%BGQ{data="on" bugstatus="NEW, ASSIGNED, REOPENED" product="xxx" milestone="yyy"}%

BugzillaQueryPlugin Settings

    • Set URL = https://marvin.in.idoox.com/bugzilla/
    • Set FORMAT = | $bug_id | $bug_severity | $priority | $bug_status | $resolution | $reporter | $product | $short_desc |
    • Set SHORTDESCRIPTION = This plugin is useful to display links or data results from Bugzilla.
    • Set SHOWBUGSCRIPT = show_bug.cgi
    • Set BUGLISTSCRIPT = buglist.cgi
    • Set BUGZILLA_DB_HOST =
    • Set BUGZILLA_DB_PORT =
    • Set BUGZILLA_DB_NAME = bugs
    • Set BUGZILLA_USER = guest
    • Set BUGZILLA_PASSWD =
    • Set DEBUG = 0

Plugin Installation Instructions

Extract BugzillaQueryPlugin.zip, edit the BugzillaQueryPlugin to your needs and have fun.

Files

  • lib/TWiki/Plugins/BugzillaQueryPlugin.pm
  • data/TWiki/BugzillaQueryPlugin.txt

Plugin Info

Plugin Author: RichardBaar
Plugin Version: 1.04
Change History: 27 Aug 2008: Version 1.04 - Added wildcard patterns and negation by SaschaVetter
23 Feb 2004: Version 1.03 - Added keywords and remote machine support
CPAN Dependencies: DBI
Other Dependencies: none
Perl Version: 5.0
Plugin Home: http://TWiki.org/cgi-bin/view/Plugins/BugzillaQueryPlugin
Feedback: http://TWiki.org/cgi-bin/view/Plugins/BugzillaQueryPluginDev

Related Topics: TWikiPreferences, TWikiPlugins

Sponsored by Systinet

-- RichardBaar - 23 Feb 2004

Topic attachments
I Attachment Action Size Date Who Comment
elsegz BugzillaQueryPlugin.tar.gz manage 6.7 K 27 Aug 2008 - 12:21 SaschaVetter BugzillaQueryPlugin version 1.04
zipzip BugzillaQueryPlugin.zip manage 7.6 K 27 Aug 2008 - 12:21 SaschaVetter BugzillaQueryPlugin version 1.04
Topic revision: r6 - 27 Aug 2008 - 12:21:41 - SaschaVetter
 
TWIKI.NET
This site is powered by the TWiki collaboration platformCopyright © by the contributing authors. All material on this collaboration platform is the property of the contributing authors.
Ideas, requests, problems regarding TWiki? Send feedback