uCosminexus Application Server, Web Service Development Guide

[Contents][Glossary][Index][Back][Next]

2.3 Development flow of RESTful Web Services

The following figure shows the development flow of RESTful Web Services (Web Services).

Figure 2-7 Development flow of RESTful Web Services

[Figure]

  1. Creating a root resource class
    Create a root resource class and implement at least one from among the resource method, sub-resource method, or the sub-resource locator. Also create a sub-resource class or an exception mapping provider as and when required.
  2. Executing the javac command
    Execute the javac command to compile the created Java source.
  3. Creating a DD
    Create web.xml and application.xml. Code the information specific to Web Services in web.xml. For details on creating web.xml, see 11.2 Creating web.xml.
  4. Creating EAR files
    Create an EAR file that includes the created file. For creating EAR files, see 11.3.2 Creating EAR files.
  5. Deploying and starting EAR files
    Deploy the created EAR file and start the file as a J2EE application (Web Service). For details on the import and start commands of J2EE applications, see cjimportapp (Importing J2EE applications) and cjstartapp (Starting J2EE applications) in the uCosminexus Application Server Command Reference Guide.
    For the method to deploy (import) J2EE applications by using the management portal, see 12.3.3 Importing J2EE applications in the uCosminexus Application Server Management Portal User Guide.
    For the method to start J2EE applications by using the management portal, see 12.3.1 Starting J2EE applications in the uCosminexus Application Server Management Portal User Guide.

For examples of developing RESTful Web Services, see 12.3 Examples of developing Web resources.