[jboss-cvs] JBossAS SVN: r101219 - in projects/jboss-jca/trunk/doc/userguide/en: modules and 1 other directory.

jboss-cvs-commits at lists.jboss.org jboss-cvs-commits at lists.jboss.org
Sun Feb 21 22:21:56 EST 2010


Author: jesper.pedersen
Date: 2010-02-21 22:21:55 -0500 (Sun, 21 Feb 2010)
New Revision: 101219

Added:
   projects/jboss-jca/trunk/doc/userguide/en/modules/validator.xml
Modified:
   projects/jboss-jca/trunk/doc/userguide/en/master.xml
   projects/jboss-jca/trunk/doc/userguide/en/modules/configuration.xml
Log:
[JBJCA-272] Initial documentation for the validator

Modified: projects/jboss-jca/trunk/doc/userguide/en/master.xml
===================================================================
--- projects/jboss-jca/trunk/doc/userguide/en/master.xml	2010-02-22 03:11:24 UTC (rev 101218)
+++ projects/jboss-jca/trunk/doc/userguide/en/master.xml	2010-02-22 03:21:55 UTC (rev 101219)
@@ -8,6 +8,7 @@
         <!ENTITY configuration SYSTEM "modules/configuration.xml">
         <!ENTITY deployment SYSTEM "modules/deployment.xml">
         <!ENTITY running SYSTEM "modules/running.xml">
+        <!ENTITY validator SYSTEM "modules/validator.xml">
         <!ENTITY embedded SYSTEM "modules/embedded.xml">
         <!ENTITY community SYSTEM "modules/community.xml">
         <!ENTITY troubleshooting SYSTEM "modules/troubleshooting.xml">
@@ -36,6 +37,8 @@
 
    &running;
 
+   &validator;
+
    &embedded;
 
    &community;

Modified: projects/jboss-jca/trunk/doc/userguide/en/modules/configuration.xml
===================================================================
--- projects/jboss-jca/trunk/doc/userguide/en/modules/configuration.xml	2010-02-22 03:11:24 UTC (rev 101218)
+++ projects/jboss-jca/trunk/doc/userguide/en/modules/configuration.xml	2010-02-22 03:21:55 UTC (rev 101219)
@@ -30,7 +30,7 @@
       <para>The configuration is done in the</para>
 
       <programlisting>
-config/jbossts-properties.xml
+config/transaction.xml
       </programlisting>
 
       <para>file.</para>
@@ -79,14 +79,6 @@
             </thead>
             <tbody>
               <row>
-                <entry><code>BeanValidation</code></entry>
-                <entry><code>boolean</code></entry>
-                <entry>
-                  Toggle bean validation (JSR-303) for the deployment units.
-                  <para>Default: <code>true</code></para>
-                </entry>
-              </row>
-              <row>
                 <entry><code>ArchiveValidation</code></entry>
                 <entry><code>boolean</code></entry>
                 <entry>
@@ -110,6 +102,28 @@
                   <para>Default: <code>true</code></para>
                 </entry>
               </row>
+              <row>
+                <entry><code>BeanValidation</code></entry>
+                <entry><code>boolean</code></entry>
+                <entry>
+                  Toggle bean validation (JSR-303) for the deployment units.
+                  <para>Default: <code>true</code></para>
+                </entry>
+              </row>
+              <row>
+                <entry><code>DefaultBootstrapContext</code></entry>
+                <entry><code>org.jboss.jca.core.api.CloneableBootstrapContext</code></entry>
+                <entry>
+                  Specifies the default bootstrap context for resource adapters
+                </entry>
+              </row>
+              <row>
+                <entry><code>PrintStream</code></entry>
+                <entry><code>java.io.PrintStream</code></entry>
+                <entry>
+                  Specifies which print stream that should be used to handle the <code>LogWriter</code>s
+                </entry>
+              </row>
             </tbody>
           </tgroup>
         </table>

Added: projects/jboss-jca/trunk/doc/userguide/en/modules/validator.xml
===================================================================
--- projects/jboss-jca/trunk/doc/userguide/en/modules/validator.xml	                        (rev 0)
+++ projects/jboss-jca/trunk/doc/userguide/en/modules/validator.xml	2010-02-22 03:21:55 UTC (rev 101219)
@@ -0,0 +1,111 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<chapter id="validator">
+   <title>Validator</title>
+
+   <section id="validator_introduction">
+      <title>Introduction</title>
+
+      <para>The JBoss JCA container features a validator which checks resource adapter archives
+        against the Java Connector Architecture (JCA) specification.</para>
+
+      <para>The validator works by doing a static analysis of the resource adapter classes
+        and checks them against the rules defined in the validator.</para>
+
+      <para>The validator is used in the deployer chain of the JCA container, and is available 
+        as a standalone tool too.</para>
+   </section>
+
+   <section id="validator_reports">
+      <title>Reports</title>
+
+      <para>The validator works by scanning the resource adapter in question and output
+        a report which lists which rules have been violated.</para>
+
+      <para>An example could be</para>
+
+      <programlisting>
+Severity: ERROR
+Section: 19.4.2
+Description: A ResourceAdapter must implement a "public int hashCode()" method.
+Code: com.mycompany.myproject.ResourceAdapterImpl
+
+Severity: ERROR
+Section: 19.4.2
+Description: A ResourceAdapter must implement a "public boolean equals(Object)" method.
+Code: com.mycompany.myproject.ResourceAdapterImpl
+      </programlisting>
+
+      <para>which means that <code>com.mycompany.myproject.ResourceAdapterImpl</code> is missing
+        an <code>equals</code> and <code>hashCode</code> implementation.</para>
+
+      <table frame="all">
+        <title>Validator report</title>
+        <tgroup cols="2" align="left" colsep="1" rowsep="1">
+          <colspec colname="c1" colwidth="2*"/>
+          <colspec colname="c2" colwidth="3*"/>
+          <thead>
+            <row>
+              <entry align="left">Key</entry>
+              <entry align="left">Desciption</entry>
+            </row>
+          </thead>
+          <tbody>
+            <row>
+              <entry><code>Severity</code></entry>
+              <entry>
+                Specifies the severity of the rule.
+                <para>
+                  <itemizedlist spacing="compact">
+                    <listitem>
+                      ERROR: Critical error which must be fixed in order for the
+                      resource adapter to operate correctly.
+                    </listitem>
+                    <listitem>
+                      WARN: Error which should be fixed in order for the
+                      resource adapter to operate correctly.
+                    </listitem>
+                  </itemizedlist>
+                </para>
+              </entry>
+            </row>
+            <row>
+              <entry><code>Section</code></entry>
+              <entry>
+                A reference to a section in the Java Connector Architecture specification
+                where the requirement is defined.
+              </entry>
+            </row>
+            <row>
+              <entry><code>Descrption</code></entry>
+              <entry>
+                A short description of the rule.
+              </entry>
+            </row>
+            <row>
+              <entry><code>Code</code></entry>
+              <entry>
+                The class which triggered the rule.
+              </entry>
+            </row>
+          </tbody>
+        </tgroup>
+      </table>
+
+   </section>
+
+   <section id="validator_running">
+      <title>Running the standalone validator</title>
+
+      <para>The validator can be run on the command line by</para>
+
+      <programlisting>
+java -jar jboss-jca-validator.jar &lt;file&gt;
+      </programlisting>
+
+      <para>The reports will be generated into the current directory under the name of 
+        <code>&lt;file&gt;.log</code>.</para>
+
+   </section>
+
+
+</chapter>




More information about the jboss-cvs-commits mailing list