集成新版本Tomcat到JBuilder

Overview

<!-- Enter Appropriate Article Summary Here -->

Step-by-step procedure for integrating Tomcat 5 with JBuilder X

Details

<!-- Enter Appropriate Article Details Here -->

Note:

This is not a supported or tested configuration. This is just a workaround to get the server running in JBuilder X. JSP debugging will not work with this solution.

Steps:

1. Tools | Configure Servers, select the Tomcat 4.1 server and click the Copy button. Change the name to Tomcat 5.0. Next, set the home directory to the root of the Tomcat 5.0 installation, and remove the entry in the Class list and add <TOMCAT_5.0_HOME>/bin/bootstrap.jar.

 

2. File | New Project. Set server to Tomcat 5.0 and create a web module. This will trigger generation of the Tomcat 5.0 Servlet library.

 

3. Tools | Configure Libraries. Edit the Tomcat 5.0 Servlet library and add the following jars :

<TOMCAT_5.0_HOME>/common/lib/jsp-api.jar
<TOMCAT_5.0_HOME>/common/lib/servlet-api.jar
<TOMCAT_5.0_HOME>/bin/commons-logging-api.jar
<TOMCAT_5.0_HOME>/common/lib/commons-el.jar

Make a backup of this library (in your user home directory) as it gets regenerated when you create a new web module/JSP/servlet. Please make sure that you replace the library when you use any of the web gallery wizards.

 

4. Set server for the project to Tomcat 5.0.

 

5. If a "Tomcat" folder is not present under the project's root directory, create one (e.g. ../jbproject/untitled1/Tomcat). Next, create a directory named "conf" under this directory (e.g. ../jbproject/untitled1/Tomcat/conf). and create an XML file named server8080.xml. Sample server8080.xml is below. Please modify the appBase, docBase, and workDir, etc. according to your web module properties:

 

<?xml version="1.0" encoding="UTF-8"?>
<!--This comment marks this file as generated, so it may be deleted and regenerated at any time. To preserve manual changes to this file, delete this comment.-->
<Server debug="0" port="8081" shutdown="SHUTDOWN">
<Service name="Catalina">
<Connector acceptCount="10" connectionTimeout="60000" debug="0" maxThreads="75" minSpareThreads="5" port="8080"/>
<Engine debug="0" defaultHost="localhost" name="Catalina">
<Host appBase="C:Documents and Settings<user name>jbprojectuntitled1Tomcatwebapps" debug="0" name="localhost" unpackWARs="true">
<Context debug="0" docBase="C:Documents and Settings<user name>jbprojectuntitled1WebModule1" path="/WebModule1" reloadable="true" workDir="C:Documents and Settings<user name>jbprojectuntitled1TomcatworkWebModule1"/>
</Host>
</Engine>
</Service>
</Server>

 

6. Start the server in JBuilder. This should use the modified server8080.xml

 

You should be able to compile JSPs using this workaround but not debug. You should be able to debug any java code. You will see a number of exceptions for the admin, manager, balancer services which do not get started when you normally run the server in JBuilder. Please ignore these exceptions. The server should function normally without these services.

评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值