Author: chirino
Date: Mon Sep 18 20:00:57 2006
New Revision: 447696

URL: http://svn.apache.org/viewvc?view=rev&rev=447696
Log:
Latest export from confluence

Modified:
    incubator/servicemix/site/sm30ug/importing-servicemix-into-eclipse.html

Modified: 
incubator/servicemix/site/sm30ug/importing-servicemix-into-eclipse.html
URL: 
http://svn.apache.org/viewvc/incubator/servicemix/site/sm30ug/importing-servicemix-into-eclipse.html?view=diff&rev=447696&r1=447695&r2=447696
==============================================================================
--- incubator/servicemix/site/sm30ug/importing-servicemix-into-eclipse.html 
(original)
+++ incubator/servicemix/site/sm30ug/importing-servicemix-into-eclipse.html Mon 
Sep 18 20:00:57 2006
@@ -155,8 +155,8 @@
                                <LI>Click &quot;OK&quot;. Now your Run-dialog 
shall look similar to this screenshot:
 <BR clear="all">
 &nbsp;
-<BR clear="all"> <IMG 
src="importing-servicemix-into-eclipse.data/Classpath%20result%20all%20projects.png"
 align="absmiddle" border="0">
-<BR clear="all"> &nbsp; </LI>
+<BR clear="all">  <IMG 
src="importing-servicemix-into-eclipse.data/Classpath%20result%20all%20projects.png"
 align="absmiddle" border="0"><BR clear="all">
+ &nbsp;</LI>
                        </OL>
                        </LI>
                        <LI>You can add JARs and classes that are stored within 
a classpath environment variable. This is not required for the file-binding 
example, but possible, e.g. if you want to run a specific ServiceMix version 
from a JAR for bug reproduction or the like - this case is used for the 
following description. Often, this way is used to reference depenedencies Maven 
downloads automatically for you.
@@ -165,13 +165,13 @@
                                <LI>Click &quot;Advanced&quot;, &quot;Add 
Classpath Variables&quot; and &quot;OK&quot;
 <BR clear="all">
 &nbsp;
-<BR clear="all"> <IMG 
src="importing-servicemix-into-eclipse.data/Classpath%20-%20Advanced%20Options%20var.png"
 align="absmiddle" border="0"><BR clear="all">
+<BR clear="all">  <IMG 
src="importing-servicemix-into-eclipse.data/Classpath%20-%20Advanced%20Options%20var.png"
 align="absmiddle" border="0"><BR clear="all">
 &nbsp;
 <BR clear="all"></LI>
                                <LI>Check M2_REPRO and click &quot;Extend&quot;
 <BR clear="all">
 &nbsp;
-<BR clear="all"> <IMG 
src="importing-servicemix-into-eclipse.data/Classpath%20-%20Advanced%20Options%20-%20Variable.png"
 align="absmiddle" border="0"><BR clear="all">
+<BR clear="all">  <IMG 
src="importing-servicemix-into-eclipse.data/Classpath%20-%20Advanced%20Options%20-%20Variable.png"
 align="absmiddle" border="0"><BR clear="all">
 &nbsp;
 <BR clear="all"></LI>
                                <LI>Choose the JAR containing the bytecode for 
the missing classes. If you want to run SOME_VERSION of ServiceMix, choose 
/org/apache/servicemix/servicemix-core/SOME_VERSION/servicemix-core-SOME_VERSION.jar
@@ -181,7 +181,7 @@
 In case you want to reference a dependency, proceed in the same way. In case 
you do not know which package you shall select, see below.
 <BR clear="all">
 &nbsp;
-<BR clear="all"> <IMG 
src="importing-servicemix-into-eclipse.data/Classpath%20-%20Advanced%20Options%20-%20Variable%20-%20Extend.png"
 align="absmiddle" border="0"><BR clear="all">
+<BR clear="all">  <IMG 
src="importing-servicemix-into-eclipse.data/Classpath%20-%20Advanced%20Options%20-%20Variable%20-%20Extend.png"
 align="absmiddle" border="0"><BR clear="all">
 &nbsp;
 <BR clear="all"></LI>
                                <LI>Click &quot;OK&quot;</LI>
@@ -197,7 +197,7 @@
                                <LI>Click &quot;Advanced&quot;, &quot;Add 
External Folder&quot; and &quot;OK&quot;
 <BR clear="all">
 &nbsp;
-<BR clear="all"> <IMG 
src="importing-servicemix-into-eclipse.data/Classpath%20-%20Advanced%20Options%20ext%20folder.png"
 align="absmiddle" border="0"><BR clear="all">
+<BR clear="all">  <IMG 
src="importing-servicemix-into-eclipse.data/Classpath%20-%20Advanced%20Options%20ext%20folder.png"
 align="absmiddle" border="0"><BR clear="all">
 &nbsp;
 <BR clear="all"></LI>
                                <LI>When S:\ is your servicemix root directory, 
select/enter<BR>
@@ -207,8 +207,7 @@
 Why this directory? Well, have a closer look at the error message presented 
above. The package <EM>org.apache.servicemix.components</EM> indicates the 
location of the missing bean <EM>FileWriter</EM> is 
<EM>servicemix-components</EM>, and as we need an executable file, the 
<EM>target\classes</EM> subdirectory is where to look. Of course we shall proof 
that <EM>FileWriter</EM> really is located here, so execute <EM>dir /s 
FileWriter.class</EM> in the given directory and watch the output.
 <BR clear="all">
 &nbsp;
-<BR clear="all">  <IMG 
src="importing-servicemix-into-eclipse.data/Classpath%20-%20Advanced%20Options%20-%20external%20folder.png"
 align="absmiddle" border="0">
-<BR clear="all">
+<BR clear="all">  <IMG 
src="importing-servicemix-into-eclipse.data/Classpath%20-%20Advanced%20Options%20-%20external%20folder.png"
 align="absmiddle" border="0"><BR clear="all">
  &nbsp;</LI>
                                <LI>Click &quot;OK&quot;.</LI>
                        </OL>
@@ -222,35 +221,52 @@
 </OL>
 
 
-<P><B>TODO</B></P>
+<H2><A 
name="ImportingServiceMixintoEclipse-Troubleshooting"></A>Troubleshooting</H2>
+
+
+<H3><A 
name="ImportingServiceMixintoEclipse-Oneortwolinesoferrormessages"></A>One or 
two lines of error messages</H3>
+
 
-<P>error message&nbsp;</P>
+<P>In case you see an error message like</P>
 <DIV class="preformatted"><DIV class="preformattedContent">
 <PRE>java.lang.NoClassDefFoundError: org/apache/servicemix/Main
 </PRE>
 </DIV></DIV>
-<P>class file not found. execute</P>
+<P>in the console window, the ServiceMix class (or xbean or whatever is 
stated) file is not found. Did you add the class files to the classpath like 
stated above (see &quot;Add Projects&quot;)? In case you did, there may not 
exist any class files as they were not yet built. You can do that by 
executing</P>
 <DIV class="preformatted"><DIV class="preformattedContent">
 <PRE>mvn install
 </PRE>
 </DIV></DIV>
-<P>to get a build&nbsp;</P>
+<P>in the source&apos;s root directory. This will take roughly 10 to 15 
minutes. Maybe you prefer to reference a binary distribution (see &quot;Add 
Classpath Variables&quot; above).</P>
+
+
+<H3><A 
name="ImportingServiceMixintoEclipse-Lengthyerrormessages%28stacktrace%29"></A>Lengthy
 error messages (stack trace)</H3>
+
+
+<P>Scan the messages in the console window from top to bottom until you find 
one stating a missing component, indicated by a package name&nbsp;&#45; in case 
it&apos;s a &quot;<EM>java.lang.NoClassDefFoundError</EM>&quot; or 
&quot;<EM>java.lang.ClassNotFoundException</EM>&quot;, the missing class is 
printed directly after that error string, whereas for instance &quot;<EM>Error 
creating bean with name</EM>&quot; is demanding slightly more search.</P>
+
+<P>Messages may look like one of the following</P>
+
 <DIV class="preformatted"><DIV class="preformattedContent">
 <PRE>Error &apos;Bean class [org.apache.servicemix.components.file.FileWriter] 
not found&apos;
 </PRE>
 </DIV></DIV>
-<P>Why this directory? Well, have a closer look at the error message presented 
above. The package <EM>org.apache.servicemix.components</EM> indicates the 
location of the missing bean <EM>FileWriter</EM> is 
<EM>servicemix-components</EM>, and as we need an executable file, the 
<EM>target\classes</EM> subdirectory is where to look. Of course we shall proof 
that <EM>FileWriter</EM> really is located here, so execute <EM>dir /s 
FileWriter.class</EM> in the given directory and watch the output.</P>
-
-<P>When you run the example, Eclipse will show in the Console window error 
messages like &quot;<EM>Error creating bean with name</EM>&quot;, 
&quot;<EM>java.lang.NoClassDefFoundError</EM>&quot; or similar. Scan the 
messages from top to bottom until you find the missing component, indicated by 
a package name&nbsp;&#45; in case it&apos;s a 
&quot;<EM>java.lang.NoClassDefFoundError</EM>&quot; or 
&quot;<EM>java.lang.ClassNotFoundException</EM>&quot;, the missing class is 
printed directly after that error string.</P>
+<P>or&nbsp;</P>
+<DIV class="preformatted"><DIV class="preformattedContent">
+<PRE>java.lang.ClassNotFoundException: org.quartz.SimpleTrigger
+</PRE>
+</DIV></DIV>
+<P>First extract the package name from the error message, so 
<EM>org.apache.servicemix.components</EM> respectivly <EM>org.quartz</EM> for 
the above examples.</P>
 
-<P>First extract the package name (eg: &quot;java.lang.ClassNotFoundException: 
org.quartz.SimpleTrigger&quot; tells you that the package <EM>org.quartz</EM> 
is missing). Add the required library to the classpath like stated above for 
&quot;Add Classpath Variables&quot;. Look for a folder matching the missing 
package (sometimes the TLD is omitted, so package <EM>org.quartz</EM> may be 
placed in folder <EM>quartz</EM>), and choose a JAR containing executable 
bytecode classes (so not the <EM>quartz-1.5.1-sources.jar</EM> but 
<EM>quartz-1.5.1.jar</EM>) within the folder. Redo this procedure until no JAR 
is missing any more.</P>
+<P>Now, you have to choose the appropriate procedure:</P>
+<UL>
+       <LI>Build the class / project. See &quot;One or two lines of error 
messages&quot; above.</LI>
+       <LI>Add the required library to the classpath like stated above for 
&quot;Add Classpath Variables&quot;. Look in the Maven repository for a folder 
matching the missing package. Sometimes the top level domain (org, com, de and 
the like) is omitted, so package <EM>org.quartz</EM> may be placed in folder 
<EM>quartz</EM>. Then choose a JAR containing executable bytecode classes, so 
not the <EM>quartz-1.5.1-sources.jar</EM> but <EM>quartz-1.5.1.jar</EM></LI>
+       <LI>Add the required library to the classpath like stated above for 
&quot;Add External Folder&quot;. The package indicates the location of the 
missing bean <EM>FileWriter</EM> is <EM>servicemix-components</EM>, and as we 
need an executable file, the <EM>target\classes</EM> subdirectory is where to 
look. Of course we shall proof that <EM>FileWriter</EM> really is located here, 
so execute <EM>dir /s FileWriter.class</EM> in the given directory and watch 
the output.</LI>
+</UL>
 
-<P><B>TODO</B><BR>
-&nbsp;</P>
-<OL>
-       <LI>&nbsp;</LI>
-</OL>
 
+<P>Redo this until no class/JAR is missing any more.</P>
 
 <H1><A 
name="ImportingServiceMixintoEclipse-ConfiguringEclipse"></A>Configuring 
Eclipse</H1>
 
@@ -283,12 +299,12 @@
     <DIV id="site-footer">
           Added by     <A 
href="http://goopen.org/confluence/users/viewuserprofile.action?username=georg_dembowski";>Georg
 Dembowski</A>,
     last edited by     <A 
href="http://goopen.org/confluence/users/viewuserprofile.action?username=georg_dembowski";>Georg
 Dembowski</A> on Sep 18, 2006
-                  &nbsp;(<A 
href="http://goopen.org/confluence/pages/diffpages.action?pageId=13740&originalId=13753";>view
 change</A>)
+                  &nbsp;(<A 
href="http://goopen.org/confluence/pages/diffpages.action?pageId=13740&originalId=13754";>view
 change</A>)
                       <SPAN id="show" class="inline-control-link"><A href="" 
onclick="showComment(); return false;">show comment</A></SPAN>
         <SPAN id="hide" class="inline-control-link" style="display:none;"><A 
href="" onclick="hideComment(); return false;">hide comment</A></SPAN>
           <DIV id="versionComment" class="noteMacro" style="display:none; 
padding: 5px;">
       <B>Comment:</B>
-      formatting shall be okay now (wiki markup edit)<BR>
+      INS: Troubleshooting<BR>
       <SPAN class="smalltext"><A 
href="http://goopen.org/confluence/pages/viewpreviouspageversions.action?pageId=13740";>View
 page history</A></SPAN>
   </DIV>
 


Reply via email to