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 Building and Deploying helloservice with Basic Authentication Using NetBeans IDE.
In NetBeans IDE, select File->Open Project.
In the Open Project dialog, navigate to tut-install/javaeetutorial5/examples/jaxws/.
Select the simpleclient-basicauth folder.
Check the Open as Main Project and Open Required Projects check boxes.
Click Open Project.
In the Projects tab, right-click the simpleclient-basicauth project and select Clean and Build.
In the Projects tab, right-click the simpleclient-basicauth project and select Run.
You will be prompted for your user name and password.
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.