leader

Java Stuff

View markdown

Java Stuff to Learn

Here is a quick overview of Java Tools that may be worth knowing.

Install Java JDK on VMWare + CentOS 6

This assumes you're in VMPlayer with a CentOS 6.3 guest (if not: Install VMPlayer and CentOS 6.3)

Install Java JDK on Centos 6

su yum search jdk yum install java-1.7.0-openjdk.i686 yum install java-1.7.0-openjdk-devel.i686 which javac exit

First Java Program with Vim

vi Hecko.java ctrl+i public class Hecko { public static void main(String[] args) { System.out.println("Hecko!"); } } ESC :wq
Compile and Run Java from Linux Command Line
    javac Hecko.java java Hecko

    IDEs for Java

    Even though our first example used Vim, I recommend using an IDE for Java coding. Note, this recommendation is just for Java. For other languages I usually just use a decent text editor.

    Debuggers for Java

    JDB is a command line debugger. But, most likely, you'll debug wih your IDE. Here is a good Java Debugging Tutorial to start with.

    Style Guide for Java

    Some styles be good. Some... not so much. Here are some style guides worth paying attention to.

    Documenting Java Programs

    If you format your code and comments in a specific, not too excessively restrictive format, there are software tools that will generate some pretty nice looking documentation.

    Javadoc is part of the standard JDK distribution.

    Doxygen is a popular open source project that supports multiple languages, including Java. It supports most/all Javadoc constructs, adds a few, and simplifies a few more.

    Web Application Servers

    These are popular Java web servers, similar to how the Apache httpd Web Server can serve PHP.

    Full Java EE Application Servers

    Lighter Java Web Servers

    These lighter servers do most, if not all, of what you want, and are commonly used by companies that use a variety of techs such as Java, PHP, Perl, Python, Ruby. Companies that focus on Java tend to use the Full Java App Servers.

    Build Tools for Java

    These tools help build large programs and manage dependancies.

    Test Frameworks for Java

    Being able to automate tests has always been key to developing quality software/hardware. The main test frameworks for Java are:

    Continous Integration Tools

    The golden rule of version control: Merge early, merge often. When working with other programmers/engineers, the longer you go without merging your work back into the mainline, the harder it is to perform the merge. The Continous Integration (CI) tools help the merge/integration process. Some of the tasks are:

    Jenkinsis the most popular CI tool. Jenkins is a fork of Oracle's Hudson. Here is a partial list of other open source projects that Oracle tried to kill: LibreOffice fork of OpenOffice MariaDB fork of MySQL Son of Grid Engine fork of Sun Grid Engine (SGE) Illumos fork of Solaris

    Code Coverage for Java

    Here are some open source Java Code Coverage Tools.

    Static Code Quality Analysis Tools for Java

    There are some careless bugs that are difficult to can with testing, but are easily caught with a code checking program. I almost always wish I had run these before debugging.

    Google CodePro Analytix is a free, but not open source, professional-quality plugin for Eclipse. It looks amazingly powerful, but it is not a google supported project. I hope it doesn't die before it gets open-sourced.