1 <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01//EN"
2 "http://www.w3.org/TR/html4/strict.dtd">
5 <meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
6 <meta name="GENERATOR" content="Mozilla/4.61 [en] (Win98; U) [Netscape]">
8 <title>ClearSCM: ECRDig</title>
10 <link rel="stylesheet" type="text/css" media="screen" href="/css/Article.css">
11 <link rel="stylesheet" type="text/css" media="screen" href="/css/Code.css">
12 <link rel="stylesheet" type="text/css" media="print" href="/css/Print.css">
13 <link rel="SHORTCUT ICON" href="http://clearscm.com/favicon.ico" type="image/png">
16 <script src="http://www.google-analytics.com/urchin.js" type="text/javascript">
18 <script type="text/javascript">
19 _uacct = "UA-89317-1";
25 include "clearscm.php";
36 <?php start_box ("cs3");?>
39 <h4 style="text-align:center">by <a
40 href="/people.php">Andrew DeFaria</a></h4>
42 <p>ECRs, or Electronic Change Records, was a bug tracking
43 systems in used at <a href="http://lynuxworks.com">LynuxWorks,
44 Inc.</a>. What started as a simple quest to display an ECR as a
45 web pages turned into a full blown, full text search of the
46 defect/issue tracking system. Here's how it developed...</p>
51 <p>While at LynuxWorks I decided to leverage some code that I had
52 previously developed (See <a href="/clearquest/cqd">Clearquest
53 Daemon</a>) that utilizes a client/server model to provide a
54 service that interogates a database and returns information. Again
55 this database happens to be a defect tracking database residing on
60 <p>The daemon opens the database then listens on a socket for
61 requests, in this case a defect ID, then obtains the detail
62 information about the defect and returns it to the caller in the
63 form of a Perl hash. This avoids the overhead associated with
64 opening and closing the database or otherwise connecting to the
65 datastore. The daemon runs continually in the background listening
66 for and servicing requests (<a href="ecrd.php">ecrd source
71 <p>The caller, or client, then can process the information in
72 anyway they see fit. Often the caller is a Perl or PHP script that
73 outputs the information in to a nicely formatted web page but it
74 can as easily be a command line tool that spits out the answer to
75 a question. For example:<p>
77 <div class="code"><pre>
82 <p>uses a command line client to display the owner of the defect
83 142. (<a href="ecrc.php">ecrc source code</a>).</p>
87 <p>As PHP is a nice language for writing dynamic web pages I then
88 developed a PHP API library in order to be a client to ecrd which
89 was written in Perl. This allowed me to call the daemon to get
90 information about a defect then format out whatever web page I
91 wanted (<a href="ecrc.php.php">ecrc.php API source code</a>).</p>
93 <p>For example, here is an <a href="ecr23184.html">example</a> of
94 a web page describing a specific defect. Notics that the ECR
95 (LynuxWorks defect tracking system) displays the one line
96 description as well as other fields such as State, Status,
97 Severity and Fixed info. Additionally the long description is
98 displayed as well as parsed for references to other ECRs or
99 auxilary files, courtesy of PHP.</p>
101 <table border=0 align=right width=300px>
104 <?php start_box ("cs2");?>
105 <p>The link to ECR 22979 will not work unless you are
106 within the LynuxWorks Intranet</p>
112 <h3>Tying it into HtDig</h3>
114 <p>Since ECRs and their full text descriptions are now available
115 via a web link it was relatively trival to hook this up to <a
116 href="http://www.htdig.org/">HtDig</a> to enable full text
117 searching on all ECRs and their descriptions. All that was needed
118 was to produce a web page with all ECRs listed linked to web pages
119 of their descriptions. HtDig would then crawl through and index
120 everything. Additionally, since the ECR descriptions were scanned
121 for references to certain <i>auxilary files</i> (files not
122 necessarily in the defect database but on a network accessible
123 area and used to further support the ECR in question) HtDig would
124 crawl through and index them too. This resulted in a very flexible
125 and powerful internal search facility.</p>
128 <?php copyright ();?>
131 <script language="JavaScript" src="/JavaScript/Menus.js" type="text/javascript"></script>