Eclipse + Tomcat + WTP Installation notes

Source: Internet
Author: User

WTP is a good stuff and has a very strong function. It is actually the same as IBM WebSphere Dev studio. The most important thing is that it also supports WebService debugging !!!
The installation process is as follows:

1. Download JDK 1.5 from Sun. I use update 7.
Install to c: \ Program Files \ Java \ jdk1.5.0 _ 07

2. Download WebTools/eclipse all in one package, version r-1.0.2-200604280245, because 1.5 is always unavailable to me
Eclipse version 3.1.2
Decompress all files to D: \ eclipse.
Important: Before installation, you must clear the previous eclipse environment !!!
Because the workspace directory still follows the previous one
1. Tomcat always goes to the/tomecat/lib directory when it is started.
2. axis error when publishing WebService

3. Download tomcat. Note that it is best to use 5.5.x, and wtp1.0.2 only supports up to 5.5.9. I use 5.5.9 and 5.5.12 may cause errors.
Install to D: \ Tomcat

Remember to select webapps

You 'd better modify the default port.

Specify the JDK/JRE installation directory

4. Configure Tomcat
Run start \ AllProgram\ Apache Tomcat 5.5 \ configure tomcat or D: \ Tomcat \ bin \ tomcat5w.exe
Specifies the Java Virtual Machine path. If only JDK/JRE 5.0 is installed, you do not need to modify it.

5. Configure WTP/eclipse
Start eclipse and open window/preferences

Switch to server/installed runtime and add a Web application server.

Switch to WebServices/server and runtime, and specify the server as Tomcat 5.5.

6. Add Server
Open new.../project and select server/Server

Select the Tomcat server we specified in the configuration server/installed Runtime

We can see that our tomecat is displayed on the servers page.

7. Test
Let's write a demo.
First, a new dynamic web project is called webdemo.

Create a class webdemoclass
The Code is as follows:

Public   Class Webdemoclass {
Public String exec (string info)
{
System. Out. println (Info );

Return "Printed:" +Info;
}
}

Now we want to publish this JavaBean to WebService.
New/WebService

Step by step in the Wizard, specify the bean as webdemoclass

Click Finish to wait for the release to complete!

In the browser, enter http: // localhost: 9090/webdemo/services/webdemoclass? WSDL
If the result is displayed, the publishing is successful.

Open Web Service Explorer

Select Exec

Enter the parameters and click go. The result is displayed.

Test in BCBCodeDownload (mssoap SDK supported)

Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.