IntelliJ IDEA provides facilities for easy and effective creation, debugging, and testing of RESTful Web Services. Development of RESTful Web Services is supported via the WebServices bundled plugin, which is by default enabled. If not, activate it in the Plugins page of the Settings dialog box.
Because RESTful Web services can be of various types, there is no definite workflow to develop them. In this section we will outline some specific tasks that can be performed when developing an application with REST support in IntelliJ IDEA.
- Start creating a Java module and enable REST support in it.
- Populate the RESTful Web service module with the necessary classes and methods, possibly using the generated sample class.
- Configure the artifacts to deploy.
- Create a run configuration. On the Deployment tab, specify the artifacts to deploy.
Deploy the Web service on an HTTP server and start the server.
If you are using the sample service created with the module, choose Shift+F10Shift+F10Shift+F10Shift+F10Shift+F10F9Ctrl+F5F6Shift+Alt+X or Shift+F10Control RShift F10Shift Command F11. IntelliJ IDEA creates a local HTTP server, starts it, whereupon deploys and runs the Web service.or press
- Run the application locally or on a remote host.
- Test the RESTful Web service.