Mahesha999
Mahesha999

Reputation: 24871

Unable to create HelloWorld webservice

I am trying to create a simple HelloWorld webservice using Tomcat, Eclipse, JAX-WS using this tutorial.

I created a Dynamic Web Project whose folder hierarchy looks like this. enter image description here

I copy pasted the code from the tutorial and ensured that I have put my workspace name appropriately in those Java and XML files

Now I created an Ant builder in eclipse as follows: enter image description here

The content of the build.xml is as given in the tutorial.

However when I build the project I get the following error: enter image description here

Though in the first image you can see I have explicitly created the dist folder under the project directory directly.

Edit

Target tab of Ant builder enter image description here

Upvotes: 1

Views: 319

Answers (2)

luiso1979
luiso1979

Reputation: 918

In your ant file replace this:

<project name="HelloWorldWS" default="dist" basedir=".">

with this

<project name="HelloWorldWS" default="war" basedir=".">

Note that the last screenshot you posted that it says in Manua Build: <default target selected>. So it goes to the build.xml and takes the default defined in the tag project and dist is not declared inside of it instead war is (that at the end does the distribution generation). So use war as default.

Upvotes: 1

Qben
Qben

Reputation: 2623

Your ant file build.xml are missing the dist target, try running the war target instead.

Upvotes: 1

Related Questions