⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 ch10.html

📁 详细介绍了jboss3.0的配置等
💻 HTML
📖 第 1 页 / 共 2 页
字号:
<html><head>
      <meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
   <title>Chapter 10. Development Tools and IDE Integration</title><link rel="stylesheet" href="styles.css" tppabs="http://www.huihoo.org/jboss/online_manual/3.0/styles.css" type="text/css"><meta name="generator" content="DocBook XSL Stylesheets Vimages/callouts/"><link rel="home" href="index.html" tppabs="http://www.huihoo.org/jboss/online_manual/3.0/index.html" title="JBoss 3.0 Documentation"><link rel="up" href="index.html" tppabs="http://www.huihoo.org/jboss/online_manual/3.0/index.html" title="JBoss 3.0 Documentation"><link rel="previous" href="ch09.html#d0e6667" tppabs="http://www.huihoo.org/jboss/online_manual/3.0/ch09.html#d0e6667" title="Bibliography"><link rel="next" href="ch10s10.html" tppabs="http://www.huihoo.org/jboss/online_manual/3.0/ch10s10.html" title="&#xA;        How to Run and Debug EJBs using jBoss 2.2.2 inside of &#xA;        Visual Age for Java version 3.5 (patch 2)&#xA;"></head><body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF"><table border="0" cellpadding="0" cellspacing="0" height="65"><tr height="65"><td rowspan="2"><img src="jboss.gif" tppabs="http://www.huihoo.org/jboss/online_manual/3.0/jboss.gif" border="0"></td><td rowspan="2" background="gbar.gif" tppabs="http://www.huihoo.org/jboss/online_manual/3.0/gbar.gif" width="100%" align="right" valign="top"><a href="index.html" tppabs="http://www.huihoo.org/jboss/online_manual/3.0/index.html"><img src="doc.gif" tppabs="http://www.huihoo.org/jboss/online_manual/3.0/doc.gif" border="0"></a><a href="index.html" tppabs="http://www.huihoo.org/jboss/online_manual/3.0/index.html"><img src="toc.gif" tppabs="http://www.huihoo.org/jboss/online_manual/3.0/toc.gif" border="0"></a><a href="ch09.html#d0e6667" tppabs="http://www.huihoo.org/jboss/online_manual/3.0/ch09.html#d0e6667"><img src="prev.gif" tppabs="http://www.huihoo.org/jboss/online_manual/3.0/prev.gif" border="0"></a><a href="ch10s10.html" tppabs="http://www.huihoo.org/jboss/online_manual/3.0/ch10s10.html"><img src="next.gif" tppabs="http://www.huihoo.org/jboss/online_manual/3.0/next.gif" border="0"></a></td></tr><tr></tr></table><div class="chapter"><div class="titlepage"><div><h2 class="title"><a name="d0e6730"></a>Chapter 10. Development Tools and IDE Integration</h2></div></div><div class="toc"><p><b>Table of Contents</b></p><dl><dt><a href="ch10.html#d0e6733" tppabs="http://www.huihoo.org/jboss/online_manual/3.0/ch10.html#d0e6733">Integrating JBuilder 4.0 Foundation with JBoss 
for source level debugging</a></dt><dt><a href="ch10s10.html" tppabs="http://www.huihoo.org/jboss/online_manual/3.0/ch10s10.html">
        How to Run and Debug EJBs using jBoss 2.2.2 inside of 
        Visual Age for Java version 3.5 (patch 2)
</a></dt><dt><a href="ch10s14.html" tppabs="http://www.huihoo.org/jboss/online_manual/3.0/ch10s14.html">Integrating NetBeans/Forte for Java Community Edition with JBoss 
for source level debugging</a></dt><dt><a href="ch10s25.html" tppabs="http://www.huihoo.org/jboss/online_manual/3.0/ch10s25.html">Using Verifier in Ant</a></dt><dt><a href="ch10s29.html" tppabs="http://www.huihoo.org/jboss/online_manual/3.0/ch10s29.html">How to generate Enterprise Java Beans with EJBDoclet (XDoclet)</a></dt></dl></div><div class="section"><a name="d0e6733"></a><div class="titlepage"><div><h2 class="title" style="clear: both"><a name="d0e6733"></a>Integrating JBuilder 4.0 Foundation with JBoss 
for source level debugging</h2></div></div><p>Author:<span class="author">John P. Coffey</span>
		<tt>&lt;<a href="mailto:jcoffey@pingtel.com">jcoffey@pingtel.com</a>&gt;</tt>
	</p><div class="section"><a name="d0e6747"></a><div class="titlepage"><div><h3 class="title"><a name="d0e6747"></a>Install the JBoss Server</h3></div></div><p>
For the purpose of this howto, I installed the JBossTomcat release version
2.2.1 into d:\JBoss-2.2.1_Tomcat-3.2.1.  Download it from
http://www.jboss.org and select the binary link from the page.  Don't worry 
about downloading a binary package, when all you want is the source code;
the binary package also contains the source code used for building.
</p></div><div class="section"><a name="d0e6752"></a><div class="titlepage"><div><h3 class="title"><a name="d0e6752"></a>Create a JBuilder 4.0 Project</h3></div></div><p>While setting up an EJB project the typical entry level screen
Project/Properties should look like:
</p><div class="mediaobject"><img src="jbuilder-prop-path.png" tppabs="http://www.huihoo.org/jboss/online_manual/3.0/jbuilder-prop-path.png"></div></div><div class="section"><a name="d0e6760"></a><div class="titlepage"><div><h3 class="title"><a name="d0e6760"></a>Create a JBoss-Server library</h3></div></div><p>
This is the most difficult aspect of the setup to get correct, however once
completed it does not need to be changed so you can setup multiple ejb
projects and reuse this library thanks to the folks at Borland.
</p><p>
To do this launch the Project/ProjectProperties/RequiredLibraries/Add...
dialog
</p><p>
Add the following library entries to the JBoss-Server classpath (the order
is crucual here).  Pay specific attention to the log and tmp folders,
faulure to put these in the Library class path will cause the classloader to
spit out error messages, the most confusing of which is that /log.properties
or /tmp.properties files could not be located.  This is because the folders
containing these files need to be in the classpath and the class loader
complains.
</p><p>
<pre class="programlisting">
/$JBOSS_TOMCAT_HOME/jboss/lib/crimson.jar
/$JBOSS_TOMCAT_HOME/jboss/bin/run.jar
/$JBOSS_TOMCAT_HOME/jboss/bin
/$JBOSS_TOMCAT_HOME/jboss/conf
/$JBOSS_TOMCAT_HOME/jboss/lib/jaas.jar
/$JBOSS_TOMCAT_HOME/jboss/lib/jboss-jaas.jar
/$JBOSS_TOMCAT_HOME/jboss/lib/jdbc2_0-stdext.jar
/$JBOSS_TOMCAT_HOME/jboss/lib/jmxri.jar
/$JBOSS_TOMCAT_HOME/tomcat/lib/parser.jar
/$JBOSS_TOMCAT_HOME/tomcat/lib/servlet.jar
/$JBOSS_TOMCAT_HOME/tomcat/lib/jaxp.jar
/$JBOSS_TOMCAT_HOME/tomcat/lib/webserver.jar
/$JBOSS_TOMCAT_HOME/tomcat/lib/jasper.jar
/$JBOSS_TOMCAT_HOME/jboss/lib/ext/activation.jar
/$JBOSS_TOMCAT_HOME/jboss/lib/ext/awt.jar
/$JBOSS_TOMCAT_HOME/jboss/lib/ext/dynaserver.jar
/$JBOSS_TOMCAT_HOME/jboss/lib/ext/ejb.jar
/$JBOSS_TOMCAT_HOME/jboss/lib/ext/ejxeditor.jar
/$JBOSS_TOMCAT_HOME/jboss/lib/ext/ejxejb.jar
/$JBOSS_TOMCAT_HOME/jboss/lib/ext/ejxjaws.jar
/$JBOSS_TOMCAT_HOME/jboss/lib/ext/ejxjboss.jar
/$JBOSS_TOMCAT_HOME/jboss/lib/ext/hsql.jar
/$JBOSS_TOMCAT_HOME/jboss/lib/ext/idb.jar
/$JBOSS_TOMCAT_HOME/jboss/lib/ext/jboss.jar
/$JBOSS_TOMCAT_HOME/jboss/lib/ext/jetty-service.jar
/$JBOSS_TOMCAT_HOME/jboss/lib/ext/jms.jar
/$JBOSS_TOMCAT_HOME/jboss/lib/ext/jmxtools.jar
/$JBOSS_TOMCAT_HOME/jboss/lib/ext/jndi.jar
/$JBOSS_TOMCAT_HOME/jboss/lib/ext/jnpserver.jar
/$JBOSS_TOMCAT_HOME/jboss/lib/ext/jpl-util-0_5b.jar
/$JBOSS_TOMCAT_HOME/jboss/lib/ext/jta-spec1_0_1.jar
/$JBOSS_TOMCAT_HOME/jboss/lib/ext/mail.jar
/$JBOSS_TOMCAT_HOME/jboss/lib/ext/tomcat-service.jar
/$JBOSS_TOMCAT_HOME/jboss/lib/ext/jbossmq.jar
/$JBOSS_TOMCAT_HOME/jboss/db
/$JBOSS_TOMCAT_HOME/jboss/conf/default
/$JBOSS_TOMCAT_HOME/jboss/lib/ext/log4j.jar
/$JBOSS_TOMCAT_HOME/jboss/log
/$JBOSS_TOMCAT_HOME/jboss/tmp
/$JBOSS_TOMCAT_HOME/jboss/lib/ext/jbosssx.jar
/$JBOSS_TOMCAT_HOME/jboss/lib/ext/jbosscx-0.2.jar
/$JBOSS_TOMCAT_HOME/jboss/lib/ext/connector.jar
/$JBOSS_TOMCAT_HOME/jboss/lib/ext/minerva-1_0b3.jar
</pre>
</p><p>
In the source tab for the JBoss-Server library point to
/$JBOSS_TOMCAT_HOME/jboss/src.  This is how JBuilder resolves where to find
the source for stepping through the code.  Without this step typically you
will be able to step through the code but the Main.java  will appear as
Main.class.
</p><p>
As per the diagram figure below, set the main class entry point to
'org.jboss.Main'.  This is where the JBoss server code starts up.  Make sure
that you set the working directory is set to $JBOSS_TOMCAT_HOME/jboss/bin in
the paths tab.
</p><div class="mediaobject"><img src="jbuilder-prop-run.png" tppabs="http://www.huihoo.org/jboss/online_manual/3.0/jbuilder-prop-run.png"></div><p>
Cut and paste the following line and place it into the 'vm parameters' entry
field (Project/Properties/Run)
</p><p><pre class="programlisting">
-classic -Dtomcat.home=D:\$JBOSS_TOMCAT_HOME\tomcat -Duser.dir=D:\$JBOSS_TOMCAT_HOME\jboss\bin
-Djavax.xml.parsers.SAXParserFactory=org.apache.crimson.jaxp.SAXParserFactoryImpl
-Djavax.xml.parsers.DocumentBuilderFactory=org.apache.crimson.jaxp.DocumentBuilderFactoryImpl
</pre></p><p>
The starup argument should be left blank with the above setting.  If you
want to run with the integrated tomcat you can put tomcat as the argument,
however beware that you MAY need to replace the
/$JBOSS_TOMCAT_HOME/jboss/conf/default with
/$JBOSS_TOMCAT_HOME/jboss/conf/tomcat
</p><p>
If the above steps have been done correctly, open up JBoss-Server.library,
this is located in the folder you specified when creating the library.
Typically this is C:\Documents and Settings\&lt;nt_username&gt;\.jbuilder4 or home
directory on Linux.  Do NOT edit this file, I found several problems
manually editing this file and I am unsure why but I got several instances
of resource not found exceptions afterwards.  If in doubt don't touch it!
</p><p>
<pre class="programlisting">
&lt;?xml version="1.0" encoding="UTF-8"?&gt;
&lt;library&gt;
  &lt;!--JBuilder Library Definition File--&gt;
  &lt;fullname&gt;JBoss-Server&lt;/fullname&gt;
  &lt;class&gt;
    &lt;path&gt;[/$JBOSS_TOMCAT_HOME/jboss/lib/crimson.jar]&lt;/path&gt;
    &lt;path&gt;[/$JBOSS_TOMCAT_HOME/jboss/bin/run.jar]&lt;/path&gt;
    &lt;path&gt;/$JBOSS_TOMCAT_HOME/jboss/bin&lt;/path&gt;

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -