MongoDB for Java Developers
I spent yesterday completing the course and homework for the first week of the ‘MongoDB for Java Developers’ course from the MongoDB University. It’s only a 7 week course, but one of my goals for this year is to get a lot more hands on with technology, as that it something I really miss.
I already had a good high level understanding of MongoDB as its used a lot at my current client. The first week of the course was fairly straightforward. I have a worry that some aspects are like coding at 10,000 feet. I wrote my first piece of Java code in a commercial environment 15 years ago for an investment bank in London. At the time, we didn’t have a chance to evaluate lots of software, so I had to write the code in Notepad and compile it in MS-DOS. I’d often work in environments which had no internet connectivity and the world of open source had yet to really take off. This meant all setting of class paths, environments etc where done manually.
The course had the following prerequisites:
- MongoDB
- Java 6 or Java 7
- Maven as a build tool
- Spark as a Web framework
- Freemarker as a templating engine
I use my Macbook for work, so there is a specific profile installed on it. I used Homebrew to install a number of the tools. When I type
java -version
I see I am running Java 7.
When I type
mvn -version
I see it is picking up Java 6
I couldn’t find any .profile or .bash_profile, but I figured it was all working so easiest not to consume hours trying to figure out what is going on. I only know that this could be something that comes back to bite me. You could also see how quickly things move on. The suggested way to install Freemarker has now changed using Maven to include it as a dependency in the pom.xml. However, the ‘Getting Started’ examples from their website all used lambdas, which were only introduced in Java 8, and this course only goes up to Java 7. Still, it all seemed to work easily enough, and I guess that’s the main thing. Now waiting for the second week to be made available.