directory-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From conflue...@apache.org
Subject [CONF] Apache Directory Server v1.5 > 0.1. Reporting Bugs
Date Thu, 12 Nov 2009 21:20:00 GMT
<html>
<head>
    <base href="http://cwiki.apache.org/confluence">
            <link rel="stylesheet" href="/confluence/s/1519/1/1/_/styles/combined.css?spaceKey=DIRxSRVx11&amp;forWysiwyg=true"
type="text/css">
    </head>
<body style="background-color: white" bgcolor="white">
<div id="pageContent">
<div id="notificationFormat">
<div class="wiki-content">
<div class="email">
     <h2><a href="http://cwiki.apache.org/confluence/display/DIRxSRVx11/0.1.+Reporting+Bugs">0.1.
Reporting Bugs</a></h2>
     <h4>Page <b>edited</b> by             <a href="http://cwiki.apache.org/confluence/display/~seelmann">Stefan
Seelmann</a>
    </h4>
     
          <br/>
     <div class="notificationGreySide">
         <style type='text/css'>/*<![CDATA[*/
table.ScrollbarTable  {border: none;padding: 3px;width: 100%;padding: 3px;margin: 0px;background-color:
#f0f0f0}
table.ScrollbarTable td.ScrollbarPrevIcon {text-align: center;width: 16px;border: none;}
table.ScrollbarTable td.ScrollbarPrevName {text-align: left;border: none;}
table.ScrollbarTable td.ScrollbarParent {text-align: center;border: none;}
table.ScrollbarTable td.ScrollbarNextName {text-align: right;border: none;}
table.ScrollbarTable td.ScrollbarNextIcon {text-align: center;width: 16px;border: none;}

/*]]>*/</style><div class="Scrollbar"><table class='ScrollbarTable'><tr><td
width='33%' class='ScrollbarPrevName'>&nbsp;</td><td width='33%' class='ScrollbarParent'><sup><a
href="/confluence/display/DIRxSRVx11/0.+Community"><img border='0' align='middle' src='/confluence/images/icons/up_16.gif'
width='8' height='8'></a></sup><a href="/confluence/display/DIRxSRVx11/0.+Community">0.
Community</a></td><td width='33%' class='ScrollbarNextName'>&nbsp;<a
href="/confluence/display/DIRxSRVx11/0.2.+Building+trunks">0.2. Building trunks</a></td><td
class='ScrollbarNextIcon'><a href="/confluence/display/DIRxSRVx11/0.2.+Building+trunks"><img
border='0' align='middle' src='/confluence/images/icons/forwd_16.gif' width='16' height='16'></a></td></tr></table></div>

<h1><a name="0.1.ReportingBugs-ReportingBugs"></a>Reporting Bugs</h1>

<div class='panelMacro'><table class='tipMacro'><colgroup><col width='24'><col></colgroup><tr><td
valign='top'><img src="/confluence/images/icons/emoticons/check.gif" width="16" height="16"
align="absmiddle" alt="" border="0"></td><td><b>ApacheDS 1.5.5</b><br
/>This site was updated for ApacheDS 1.5.5.</td></tr></table></div>

<h2><a name="0.1.ReportingBugs-Introduction"></a>Introduction</h2>

<p>So you found a bug in ApacheDS.  Don't worry this is a good thing&#33;  We can
fix it really fast but need your help.  There are different degrees to your ability to help
out.  Some of you have developer skills so you might be able to write a test case that pin
points that bug.  If you can do this we will prioritize your bug report above all others.
 Yes we will put your bug to the top most important fixes that should be fixed first.  But
if you can't do this and your bug is serious then we're prioritize it ahead of others anyway.</p>

<p>This wiki page shows you how you can help us to help you&#33;&#33;&#33;</p>

<h2><a name="0.1.ReportingBugs-Creatingatestcaseproject%3Ausingtheapachedsarchetypetestcase."></a>Creating
a testcase project: using the apacheds-archetype-testcase.</h2>

<p>We've created a simple archetype for you to rapidly create a Maven project that fires
up ApacheDS in embedded mode within a JUnit testcase. This test case will start up ApacheDS
as a server on any available port above 1024 on your machine. You can then use JNDI or the
Netscape LDAP API (more APIs to come) going over the wire on that port above 1024. You can
also use the ApacheDS core API to access the data directly.</p>

<p>So you can write client code in your test case immediately. Just add your code, tar
gzip the project, and attach it to your JIRA issue on the ApacheDS JIRA here:</p>

<p> <a href="https://issues.apache.org/jira/browse/DIRSERVER" rel="nofollow">https://issues.apache.org/jira/browse/DIRSERVER</a></p>

<p>We'll prioritize your bug higher than others and probably fix it rapidly because
the problem is isolated thanks to your testcase submission. We will in fact strip out your
testcase and add it to our suite of test cases to make sure ApacheDS always passes this integration
test you've provided.</p>

<h3><a name="0.1.ReportingBugs-Installingtheapachedsarchetypetestcase"></a>Installing
the apacheds-archetype-testcase</h3>

<p>To use the archetype you'll need to check it out and install it. Here's how you can
do that for the leading edge of 1.5.5:</p>
<div class="preformatted panel" style="border-width: 1px;"><div class="preformattedContent
panelContent">
<pre>svn co http://svn.apache.org/repos/asf/directory/samples/trunk/apacheds-archetype-testcase
cd apacheds-archetype-testcase
mvn install
</pre>
</div></div>
<p>This will install the archetype onto your local repository. Now you can invoke the
archetype.</p>

<h3><a name="0.1.ReportingBugs-Invoking%28running%29thearchetype%3Ageneratingthetestcaseproject"></a>Invoking
(running) the archetype: generating the testcase project</h3>

<p>Once you checkout the archetype plugin and install it you can use it like so to generate
a foo-test project:</p>
<div class="preformatted panel" style="border-width: 1px;"><div class="preformattedContent
panelContent">
<pre>mvn archetype:generate -DarchetypeGroupId=org.apache.directory.samples \
                       -DarchetypeArtifactId=apacheds-archetype-testcase \
                       -DarchetypeVersion=1.5.5-SNAPSHOT \
                       -DgroupId=com.acme -DartifactId=foo-test -Dpackage=com.acme
</pre>
</div></div>
<p>This will generate the default test case project with the following tree structure:</p>
<div class="preformatted panel" style="border-width: 1px;"><div class="preformattedContent
panelContent">
<pre>~/foo-test$ tree
.
|-- pom.xml
`-- src
    |-- main
    |   `-- java
    |       `-- com
    |           `-- acme
    |               `-- Dummy.java
    `-- test
        |-- java
        |   `-- com
        |       `-- acme
        |           |-- AdvancedTest.java
        |           |-- AdvancedTestApacheDsFactory.java
        |           `-- MinimalTest.java
        `-- resources
            |-- log4j.properties
            |-- sevenSeas_data.ldif
            `-- sevenSeas_schema.ldif

10 directories, 8 files
</pre>
</div></div>
<ul>
	<li>Dummy.java - this is just a placeholder file to make sure that Maven works properly.</li>
	<li>MinimalTest - a minimal ApacheDS Integration Test. It contains two test methods
to demonstrate usage of JNDI and the ApacheDS core API. Add your own test method here.</li>
	<li>AdvancedTest - an advanced ApacheDS Integration Test in case you need a special
configuration for your test. It demonstrates how to add a new partition, how to enable LDAPS,
how to enable a disabled schema, how to inject a custom schema, and how to inject custom test
data.</li>
	<li>AdvancedTestApacheDsFactory - configures ApacheDS for the advanced test</li>
	<li>pom.xml - the Maven Project Object Model (POM) for your new testcase project (can
remain as is).</li>
	<li>log4j.properties - Log4j configuration file that controls ApacheDS logging for
your convenience; edit this file to control logging output.</li>
	<li>sevenSeas_data.ldif - sample custom test data used by the advanced test.</li>
	<li>sevenSeas_schema.ldif - sample custom schema used by the advanced test.</li>
</ul>


<p>Once you do this you can cd into foo-test and just build and test it for fun to see
what happens.  This will build, and test the sample test cases (they should pass) that comes
packaged with the project you just created. CD into foo-test and run the following command:</p>
<div class="preformatted panel" style="border-width: 1px;"><div class="preformattedContent
panelContent">
<pre>mvn test
</pre>
</div></div>
<p>Now you can customize the MinimalTest.java or AdvancedTest.java file to isolate your
bug. Open the classes with your favorite editor and goto town.  However if you want to pull
this project into your IDE and edit it there you can use Maven's IDEA, Eclipse and Netbeans
integration to create IDE project descriptors for them.  Then you can import this project
into your IDE.  Here's how:</p>

<h4><a name="0.1.ReportingBugs-ForIDEA"></a>For IDEA</h4>

<div class="preformatted panel" style="border-width: 1px;"><div class="preformattedContent
panelContent">
<pre>mvn idea:idea
</pre>
</div></div>

<h4><a name="0.1.ReportingBugs-ForEclipse"></a>For Eclipse</h4>

<div class="preformatted panel" style="border-width: 1px;"><div class="preformattedContent
panelContent">
<pre>mvn eclipse:eclipse
</pre>
</div></div>

<h4><a name="0.1.ReportingBugs-ForNetbeans"></a>For Netbeans</h4>

<p>See this page: <a href="http://maven.apache.org/guides/mini/guide-ide-netbeans/guide-ide-netbeans.html"
rel="nofollow">http://maven.apache.org/guides/mini/guide-ide-netbeans/guide-ide-netbeans.html</a>.</p>

<h3><a name="0.1.ReportingBugs-Noteaboutversion"></a>Note about version</h3>

<p>Note that this archetype is specific for ApacheDS 1.5.5.</p>

<h2><a name="0.1.ReportingBugs-WhyaMavenArchetypeforTesting%3F"></a>Why
a Maven Archetype for Testing?</h2>

<ol>
	<li>Easy and fast to start integration testing ApacheDS.</li>
	<li>We (developers of ApacheDS) can use it ourselves.</li>
	<li>We want users of ApacheDS to help us help them.</li>
	<li>Users need to customize a project with perhaps additional dependencies.</li>
	<li>Users can add many test cases to the project.</li>
	<li>Tests isolating custom bugs can be incorporated into our community test suite for
ApacheDS.</li>
</ol>


     </div>
     <div id="commentsSection" class="wiki-content pageSection">
       <div style="float: right;">
            <a href="http://cwiki.apache.org/confluence/users/viewnotifications.action"
class="grey">Change Notification Preferences</a>
       </div>

       <a href="http://cwiki.apache.org/confluence/display/DIRxSRVx11/0.1.+Reporting+Bugs">View
Online</a>
       |
       <a href="http://cwiki.apache.org/confluence/pages/diffpagesbyversion.action?pageId=55294&revisedVersion=7&originalVersion=6">View
Change</a>
            </div>
</div>
</div>
</div>
</div>
</body>
</html>

Mime
View raw message