Tuesday, February 18, 2014

SUCODE Java Development Environment

SUCODE has released a Java development environment, to simplify and increase productivity of Java (web and library) projects. 

  • Why do we need another development environment for Java?

There are many good IDEs for Java development (Eclipse, STS, Netbeans...), and there are also lots of plugins to support multiple tools on them (Git, SVN, Ant, Maven, Gradle...).

One of the main purpose of this Java development environment is providing a cross-platform and cross-IDE Java development environment. This means that you could use it on Windows, Linux, Mac... and then you could develop with Eclipse, STS, Netbeans, Notepad... You can freely choose your favourite OS and IDE, because the development lifecycle is managed by standard tools that you could use also from command line: Ant, Maven and Gradle.

The key concept here is giving the standard (and open source) build management tools (Ant, Maven, Gradle) a main role within the development environment.

  • Why do we need 3 different tools for the same purpose?

It's true that most of development environments use only one of the build lifecycle management tools (Ant, Maven or Gradle), but it's also true that each of them has strengths and weaknesses:

  • Ant is great for creating customized tasks (copy directories, filter files, package contents, etc) but it is not so great for dependency management (despite the Ivy support).
  • Maven is great for dependency management (with public library repositories) but it is not so great if you want to modify the directory layout or tune some goals to perform some kind of pre / post goal task.
  • Gradle provides a great domain specific language (DSL), defined with Groovy, that easies and simplifies tasks definition (enhancing Ant's tasks). It can bypass calls to Ant tasks and provides a plug-in for Maven (despite it can't call Maven goals directly, it can create the pom.xml file with the Gradle dependencies configuration).

The development environment takes advantage from Ant, Maven and Gradle strengths and orchestrates collaboration between them in order to provide an easy to use, portable and productive development environment for Java standalone and web applications.

Here is a brief summary of the development environment functionalities:
  • Cross operating system Java development environment.
    • You can use your favourite operating system (Windows, Mac, Linux, etc).
    • The SJDE is built on Java tools, so you can use it wherever you can have a JDK.
  • Cross IDE Java development environment.
    • You can use your favourite IDE (Eclipse, STS, Netbeans.... or even cloud editors!).
    • Tools used for software development support have a main role versus the old plug-in role orientation.
    • Code edition and automatic tasks for building and testing are clearly separated.
  • Manage the software development lifecycle with your favourite tool (Ant, Maven or Gradle):
    • Clean generated stuff.
    • Compile project sources.
    • Execute tests to check your project functional correctness.
    • Pack the project to deploy it to an execution environment.
    • Generate Javadocs to obtain some automatic documentation of your code, available for other developers, API users, etc.
  • Enhance the software development experience with additional tasks:
    • Static code analysis with PMD, Checkstyle and Findbugs.
    • Execute scripts to a local or remote database (define schemas, load config or test data, apply patches, ... )
    • Manage project dependencies:
      • Generate the Maven pom.xml file from project dependencies and obtain libraries from public repositories.
      • Obtain the project dependencies list from the Maven effective pom.xml file.
      • Import dependencies to a local directory (simplifying the Maven repository directory structure in our workspace).
    • Deploy the generated package to a local server for testing.