Running helloservice Example
Running helloservice Example
ant all
You can test the service by selecting it in the Admin Console and choosing Test. For more
information on how to do this, read
Building and Running the helloservice Client Application with Basic
Authentication Using NetBeans IDE
To build and run the client application, simpleclient-basicauth, using NetBeans IDE, follow
these steps. The helloservice-basicauth service must be deployed onto the Application
Server before compiling the client files. For information on deploying the service, read
1. In NetBeans IDE, select File
Open Project.
2. In the Open Project dialog, navigate to tut-install/javaeetutorial5/examples/jaxws/.
3. Select the simpleclient-basicauth folder.
4. Check the Open as Main Project and Open Required Projects check boxes.
5. Click Open Project Folder.
6. In the Projects tab, right-click the simpleclient-basicauth project and select Clean and
Build Project.
7. In the Projects tab, right-click the simpleclient-basicauth project and select Run Project.
You will be prompted for your user name and password.
8. Enter the user name and password of a user that has been entered into the database of users
for the file realm and has been assigned to the group of user.
If the username and password you enter are authorized, you will see the output of the
application client in the Output pane.
The client displays the following output:
[echo] running application client container.
[exec] Retrieving the port from the following service:
helloservice.basicauth.endpoint.HelloService@c8769b
[exec] Invoking the sayHello operation on the port.
[exec] Hello, No Name.
Examples: Securing Web Applications
Chapter 30 · Securing Web Applications
891