|By Ken Fogel||
|August 24, 2014 01:53 PM EDT||
This tutorial is primarily for the students in my 420-517 Software Development Project course at Dawson College. It explains how to set up a workspace in Eclipse for this course. These instructions are important because Eclipse stores workspace specific settings in the workspace itself. This means that should you create a new workspace you will need to redo these settings. When you start Eclipse you are asked for the name of the workspace you want to use. If this is the first time you are using Eclipse the workspace launcher will appear as:
Eclipse wants to create a workspace called workspace in your home directory. On Linux and Mac systems you have a Home volume. In Windows the matching space is the folder with your name in the Users folder. If you have used Eclipse on the computer previously then it will show you the last workspace that you used. Pull down the combo box and you will get a list of all the workspaces that you have used. I prefer to have my workspace name indicate what I am doing. Therefore I never accept the default name and instead use a more meaningful name. Dawson Note: On the lab computers the default workspace is in C:\Users\Administrator\workspace. Here is my workspace choice for this tutorial:
After pressing OK Eclipse will start up. I configure Eclipse with the Subclipse plugin for Subversion. For that reason I get the following modal dialog (a dialog that demandsattention).
I usually un-check this simply to reduce the traffic over the network. In the school lab this is a good idea. Now we can see the Eclipse program as it appears when a new workspace is selected. Depending on the plugin that you have installed this screen may look slightly different. If you use an existing workspace then this will not appear and you will go directly to the workbench. The workbench is what we call the screen with all the windows we can use in Eclipse.
Click on the X on the Welcome tab or click on the toilet paper roll to get to the workbench.
It’s not really a toilet roll but it sure looks like one to me. The version of Eclipse that we use at Dawson is configured for Java EE. As we are going to create a desktop application we should change the perspective. A perspective is the arrangements and choices of windows on the workbench. Here is the Java EE perspective:
Go to Window -> Open Perspective and chose Java.
The workbench will now look like:
We are now ready to create our first project. We will only create Maven managed projects that use my Super Pom File (see http://netbeans.dzone.com/nb-class-maven-4-kf). From the File menu select New -> Other
The New dialog will appear for you to select a wizard. Scroll down to Maven and select Maven Project and click on Next.
On the New Maven Project you must check Create a simple project (skip archetype selection).
If you forget to do this you will see:
Click on the Back button, check Create a simple project and when all is well you should see:
Fill in the form as follows but replace my name with yours and chose appropriate names and description for your project.
Click on Finish and the project should appear in the Package Explorer. Open up the project tree by clicking on the small triangle and you should see:
There are two last tasks we must complete before we can start coding. The first thing is to change the JRE System Library. We will be using Java 1.8 and the pom.xml file will indicate Java 1.8. The Maven plugin in Eclipse is configured to default to Java 1.5. Right mouse click on JRE System Library (J2SE-1.5) and select Build Path -> Configure Build Path.
You should see:
Click on Remove and Java will disappear. We need to put in Java 1.8.
Select Add Library and you will see:
Select JRE System Library and click on Next. You should now see:
This is the dialog for a computer that only has Java 1.8 on it. It declares that the default JRE is a jre (jre1.8.0_20) which is wrong. It must be a JDK. Click on Installed JREs and you will get:
Click on the row and select Edit. This will let you point at the JDK instead of the JRE.
Now click on Directory and browse to the JDK. Here is what it looks like on my system:
Click OK and back on the Edit JRE dialog change the JRE name to jdk.
Once this is resolved click on Finish and the Preferences should look like:
Click on Ok and the Add Library should look like:
The Java Build Path will now be:
Click on OK and the Package Explorer should look like:
** Note: An error in the first posting is now corrected. In the subsequent images the JRE System Library will show jre1.8.0_20 but if you are following these instructions it will be the correct jdk1.8.0_20.
The last step is to update the pom.xml file. Double click on it and you will the Overview tab of the Maven pom file editor.
Switch to the pom.xml tab and you will see the raw file. If you close the Task List and Outline tabs on the right side of the workbench you will have a larger editor window.
You will now need the Super Pom xml file. You can retrieve it at the end of the article at http://netbeans.dzone.com/nb-class-maven-4-kf. Copy it from the article and paste it in a file that you can use each time you create a new project. I keep mine in a file called super_pom.xml. In Eclipse open this file from File -> Open File. It will appear in the Eclipse XML Editor looking like:
Switch to the Source tab and you will see:
Copy the contents of the file starting at the <developers> tag till the end of the file. Go to the pom.xml file of the project and paste what you copied over the </project> tag. It should look like:
Go to the Source menu and select Format to clean up the indenting. If you have any errors in the pom.xml they are likely due to having a second </project> tag or that you pasted the entire super_pom.xml file into you own pom.xml. These can be easily fixed by deleting the duplicated information. Correct the values in the <developer> section. Go to the <properties> section and correct the <mainClass> tag to show the name of your class that will contain the main method including the full path.
You are now ready to write code.
SYS-CON Events announced today that Vicom Computer Services, Inc., a provider of technology and service solutions, will exhibit at SYS-CON's 16th International Cloud Expo®, which will take place on June 9-11, 2015, at the Javits Center in New York City, NY. They are located at booth #427. Vicom Computer Services, Inc. is a progressive leader in the technology industry for over 30 years. Headquartered in the NY Metropolitan area. Vicom provides products and services based on today’s requirements...
Apr. 18, 2015 02:00 PM EDT Reads: 1,345
SYS-CON Events announced today that Tufin, the market-leading provider of Security Policy Orchestration Solutions, will exhibit at SYS-CON's 16th International Cloud Expo®, which will take place on June 9-11, 2015, at the Javits Center in New York City, NY. As the market leader of Security Policy Orchestration, Tufin automates and accelerates network configuration changes while maintaining security and compliance. Tufin's award-winning Orchestration Suite™ gives IT organizations the power and a...
Apr. 18, 2015 01:45 PM EDT Reads: 3,230
SYS-CON Events announced today that Optimal Design, an Internet of Things solution provider, will exhibit at SYS-CON's Internet of @ThingsExpo, which will take place on June 9-11, 2015, at the Javits Center in New York City, NY. Optimal Design is an award winning product development firm offering industrial design and engineering services to the consumer, medical, and defense markets.
Apr. 18, 2015 01:45 PM EDT Reads: 1,577
SYS-CON Events announced today that MangoApps will exhibit at SYS-CON's 16th International Cloud Expo®, which will take place on June 9-11, 2015, at the Javits Center in New York City, NY., and the 17th International Cloud Expo®, which will take place on November 3–5, 2015, at the Santa Clara Convention Center in Santa Clara, CA. MangoApps provides private all-in-one social intranets allowing workers to securely collaborate from anywhere in the world and from any device. Social, mobile, and eas...
Apr. 18, 2015 01:15 PM EDT Reads: 3,521
SYS-CON Events announced today that Stratoscale, the new data center operating system, will exhibit at SYS-CON's 16th International Cloud Expo®, which will take place on June 9-11, 2015, at the Javits Center in New York City, NY. Based in Herzeliya, Israel, Stratoscale is redefining the data center, developing a hardware-agnostic, software platform hyper-converging compute, storage and networking across the rack or data center. The self-optimizing platform automatically distributes all physical...
Apr. 18, 2015 01:00 PM EDT Reads: 1,556
SOASTA, the leader in performance analytics, today reported record growth of the CloudTest community, exceeding 30,000 registered users of the CloudTest platform in Q1 2015. SOASTA also announced widespread adoption of its Web and mobile testing solutions, with more than 1,600 customers completing more than 285,000 tests using CloudTest during the quarter. This rapid growth shows that DevOps-driven digital businesses are embracing a more continuous approach to testing, and CloudTest is meeting t...
Apr. 18, 2015 01:00 PM EDT Reads: 1,010
ProfitBricks has launched its new DevOps Central and REST API, along with support for three multi-cloud libraries and a Python SDK. This, combined with its already existing SOAP API and its new RESTful API, moves ProfitBricks into a position to better serve the DevOps community and provide the ability to automate cloud infrastructure in a multi-cloud world. Following this momentum, ProfitBricks has also introduced several libraries that enable developers to use their favorite language to code ...
Apr. 18, 2015 01:00 PM EDT Reads: 1,302
SYS-CON Events announced today that Cloudian, Inc., the leading provider of hybrid cloud storage solutions, will exhibit at SYS-CON's 16th International Cloud Expo®, which will take place on June 9-11, 2015, at the Javits Center in New York City, NY. Cloudian, Inc., is a Foster City, California - based software company specializing in cloud storage software. The main product is Cloudian, an Amazon S3-compliant cloud object storage platform, the bedrock of cloud computing systems, that enables c...
Apr. 18, 2015 01:00 PM EDT Reads: 2,290
SYS-CON Events announced today that Gridstore™, the leader in hyper-converged infrastructure purpose-built to optimize Microsoft workloads, will exhibit at SYS-CON's 16th International Cloud Expo®, which will take place on June 9-11, 2015, at the Javits Center in New York City, NY. Gridstore™ is the leader in hyper-converged infrastructure purpose-built for Microsoft workloads and designed to accelerate applications in virtualized environments. Gridstore’s hyper-converged infrastructure is the ...
Apr. 18, 2015 12:45 PM EDT Reads: 4,173
SYS-CON Events announced today that Creative Business Solutions will exhibit at SYS-CON's 16th International Cloud Expo®, which will take place on June 9-11, 2015, at the Javits Center in New York City, NY. Creative Business Solutions is the top stocking authorized HP Renew Distributor in the U.S. Based out of Long Island, NY, Creative Business Solutions offers a one-stop shop for a diverse range of products including Proliant, Blade and Industry Standard Servers, Networking, Server Options and...
Apr. 18, 2015 12:30 PM EDT Reads: 4,226
How is unified communications transforming the way businesses operate? In his session at WebRTC Summit, Arvind Rangarajan, Director of Product Marketing at BroadSoft, will discuss how to extend unified communications experience outside the enterprise through WebRTC. He will also review use cases across different industry verticals. Arvind Rangarajan is Director, Product Marketing at BroadSoft. He has over 19 years of experience in the telecommunications industry in various roles such as Softw...
Apr. 18, 2015 12:30 PM EDT Reads: 1,568
SYS-CON Events announced today that kintone has been named “Bronze Sponsor” of SYS-CON's 16th International Cloud Expo®, which will take place on June 9-11, 2015, at the Javits Center in New York City, NY, and the 17th International Cloud Expo®, which will take place on November 3–5, 2015, at the Santa Clara Convention Center in Santa Clara, CA. kintone promotes cloud-based workgroup productivity, transparency and profitability with a seamless collaboration space, build your own business applic...
Apr. 18, 2015 12:00 PM EDT Reads: 1,463
The IoT Bootcamp is coming to Cloud Expo | @ThingsExpo on June 9-10 at the Javits Center in New York. Instructor. Registration is now available at http://iotbootcamp.sys-con.com/ Instructor Janakiram MSV previously taught the famously successful Multi-Cloud Bootcamp at Cloud Expo | @ThingsExpo in November in Santa Clara. Now he is expanding the focus to Janakiram is the founder and CTO of Get Cloud Ready Consulting, a niche Cloud Migration and Cloud Operations firm that recently got acquir...
Apr. 18, 2015 12:00 PM EDT Reads: 928
The 17th International Cloud Expo has announced that its Call for Papers is open. 17th International Cloud Expo, to be held November 3-5, 2015, at the Santa Clara Convention Center in Santa Clara, CA, brings together Cloud Computing, APM, APIs, Microservices, Security, Big Data, Internet of Things, DevOps and WebRTC to one location. With cloud computing driving a higher percentage of enterprise IT budgets every year, it becomes increasingly important to plant your flag in this fast-expanding bu...
Apr. 18, 2015 12:00 PM EDT Reads: 2,051
SYS-CON Events announced today that IDenticard will exhibit at SYS-CON's 16th International Cloud Expo®, which will take place on June 9-11, 2015, at the Javits Center in New York City, NY. IDenticard™ is the security division of Brady Corp (NYSE: BRC), a $1.5 billion manufacturer of identification products. We have small-company values with the strength and stability of a major corporation. IDenticard offers local sales, support and service to our customers across the United States and Canada...
Apr. 18, 2015 12:00 PM EDT Reads: 4,873