NetBeans IDE is free and open source, and has a big community of users. You can download the NetBeans IDE from https://netbeans.org/downloads/, its official website.
At the time of writing this book, version 8.0.2 was the latest available version. As shown in the following screenshot, please download all the supported NetBeans bundles, as we'll use Javascript also:
After downloading the the installation, execute the installer file. Accept the license agreement as shown in the following screenshot, and follow the rest of the steps to install the NetBeans IDE. Glassfish Server and Apache Tomcat are optional.
JDK 7 or a later version is required for installing and running the All NetBeans Bundles. You can download a standalone JDK 8 from http://www.oracle.com/technetwork/java/javase/downloads/index.html.
Once NetBeans the IDE is installed, start the NetBeans IDE. NetBeans IDE should look as follows:
Maven and Gradle are both Java build tools. They add dependent libraries to your project, compile your code, set properties, build archives, or do many more related activities. Spring Boot or the Spring Cloud support both Maven and Gradle build tools. However, in this book we'll use the Maven build tool. Please feel free to use Gradle if you prefer.
Maven is already available in NetBeans IDE. Now, we can start a new Maven project to build our first REST app.
Steps for creating a new empty Maven project:
restsample
. Also, enter the other properties as shown in the following screenshot. Click on Finish once all the mandatory fields are entered:Aggelos Karalias has developed a helpful plugin for NetBeans IDE offering autocomplete support for Spring Boot configuration properties available at https://github.com/keevosh/nb-springboot-configuration-support. You can download it from his project page at http://keevosh.github.io/nb-springboot-configuration-support/.
You could also use Spring Tool Suite IDE (https://spring.io/tools) from Pivotal instead of NetBeans IDE. It's a customized all-in-one Eclipse-based distribution that makes application development easy.
After finishing all the the preceding steps, NetBeans will display a newly created Maven project. You will use this project for creating the sample rest application using Spring Boot.
To use Java 8 as a source, set the Source/Binary Format to 1.8 as shown in the following screenshot: