Categories
mongoDB Netbeans

How-To Open 10genEducation – M101J Homework 1.3 & 1.4 with Netbeans IDE 7.3

This is a quick how-to, that will help you open, build and run homework 1.3 of 10gen’s Education M101J (mongodb using Java) course, using Netbeans IDE 7.3 which supports Maven 3.0.

1. Extract hw1.zip into a folder of your choice. For this example I will use “c:\tmp\hw1\

2. Download and install Netbeans IDE 7.3 from http://www.netbeans.org. I suggest you get the bundle with all supported technologies included, although just the Java EE bundle is good for this.  I will not go into details for this, there are plenty guides on netbeans site. Anyway, its a pretty straightforward installation.

3. In the Netbeans IDE go to “File > New Project  and from Categories choose Maven and select “Project with Existing POM” as shown in the picture bellow and click Next >

10geneducation-m101j-netbeans-maven-01 

4. Click “Finish

10geneducation-m101j-netbeans-maven-02  

5. The “Open Project” dialog should pop. Browse to the folder where you have extracted the homework files (e.g. c:\tmp\hw1\),  Netbeans IDE will automatically spot the pop.xml and fill in the project details for you. Select hw1 and click the “Open Project” button.

10geneducation-m101j-netbeans-maven-03

6. Right click on the project name and select “build” in the content menu. The IDE will automatically download all dependencies and build the project.

10geneducation-m101j-netbeans-maven-04

7. Run the project. It will ask you for the main class.

10geneducation-m101j-netbeans-maven-05

That’s all, pretty cool eh?

 

5 replies on “How-To Open 10genEducation – M101J Homework 1.3 & 1.4 with Netbeans IDE 7.3”

Dear Friend,

I just joined this course today. Could you please let me how to import the db dump to Mongo db? This article ahs really helped me to import the project. Thanks a ton 🙂

Regards,
Ashish mishra

When I test using netbeans and the spark framework there is no way to stop the spark framework after a test cycle except to find its PID and kill it. Is there an easier, more graceful way to close the spark framework.

Thanks,

John Henry

@John Henry have you tried clicking on “Stop the currently executing build” in the output window or from the “Window” menu click on “proccesses” and cancel the proccess you want? Unless you mean something else.

Regards.

Hi,
I followed instructions up to step 6 (Project Build) where it crashed because it cannot find the import packages. Can you please show to resolve this ?

hw31.java:[8,0] package com.mongodb does not exist
hw31.java:[11,25] package javax.servlet.http does not exist
hw31.java:[25,14] cannot find symbol
symbol : class MongoClient
location: class hw31
hw31.java:[25,44] cannot find symbol
symbol : class MongoClient
location: class hw31
hw31.java:[26,14] cannot find symbol
symbol : class DB
location: class hw31
hw31.java:[27,8] cannot find symbol
symbol : class DBCollection
location: class hw31
hw31.java:[29,26] cannot find symbol

Leave a Reply

Your email address will not be published. Required fields are marked *

Time limit is exhausted. Please reload CAPTCHA.

This site uses Akismet to reduce spam. Learn how your comment data is processed.