This getting started guide will attempt to walk through a real-world (okay, mock-real-world) example of Web service development, without trying to hide the complexities of deployment descriptors, dependencies, configuration, and packaging. Of course, some attempt to be concise needs to be made, but at least you'll get the idea of the full development effort. And you'll see more than just "Hello, World".
We'll be writing a mock social networking app. For this tutorial, the name of our social networking app is IfYouWannaBeCool.com.
- Step 1: Write the Code
- Step 2: Invoke Enunciate
- Step 3: Take a Look
- Step 4 (Optional): Iterate
- Step 5 (Optional): Behold the Glory
The source code for this application can be obtained in one of two ways:
Option 1: enunciate-simple-archetype
Enunciate provides a Maven archetype to seed a simple web service project. The project uses the basic modules and includes working sample service and model code. Here's how to invoke it:
mvn archetype:generate \ -DarchetypeGroupId=org.codehaus.enunciate.archetypes \ -DarchetypeArtifactId=enunciate-simple-archetype \ -DarchetypeVersion=1.26.2 \ -DgroupId=org.codehaus.enunciate \ -DartifactId=wannabecool
Option 2: Distribution Bundle
The wannabecool sample is bundled with the distribution bundle that can be downloaded from the downloads page.