6th Annual Open Source Awards (2011) – Packt Publishing

Open Source has gained a lot of momentum over the past few years. I have seen it grown in popularity and the number of applications available and the growth of communities around it. Being a Sun Campus Ambassador which played a pivotal role in contributing to Open Source community, I was exposed to the Open source early on. And these days we have seen companies like Facebook, Twitter, SpringSource among others contributing to the open source community. Also there are lot of conferences (foss.in, 2011.osidays.com) being organized around these technologies. There are languages (Groovy, Scala, Ruby, JRuby), frameworks (Rails, Grails,Lift) which are growing in their feature set and popularity.

Another such initiative towards helping the open source communities grow and thrive is the Open Source Awards organized annually by Packt Publishing. The 2011 Open Source Awards was launched on the 1st week of August by Packt, inviting people to visit www.PacktPub.com and submit nominations for their favorite Open Source project.

The 2011 Awards will feature a prize fund of $24,000 with several new categories introduced and the vote of the public becoming more influential. This year all CMS projects will compete in an even tighter contest in the Open Source CMS Award category with the now defunct Hall of Fame CMS finalists re-entered into the CMS category. Projects such as Drupal and Joomla! will face off with CMS Made Simple and MODx for the first time since 2008.

While the Most Promising Open Source Project and the Open Source JavaScript Libraries categories will be back for a second year, Packt is introducing new categories for Open Source Business Applications, Open Source Multimedia Software and Open Source Mobile Toolkit and Libraries. These new categories will ensure that the Open Source Awards remain committed to providing the platform to recognise excellence within the community while supporting Open Source projects both new and old.

Packt has opened up nominations for people to submit their favorite Open Source projects for each category at www.PacktPub.com/open-source-awards-home . The top five in each category will go through to the final, which begins mid-September. For more information on the categories, read Packt’s recent announcement: www.packtpub.com/blog/2011-open-source-awards-announcement.

Voting beings from September 19th and goes on till October 31st 2011. So vote to see your favorite open source project winning. And what more you can get lucky to win a Kindle!

Execute external process from within JVM using Apache Commons Exec library

Executing external command from within JVM often causes problems- be it in terms of the code to write and manage or in the ease of implementation. I had similar requirement in my Major project for my Under Graduate Degree, where in I had to launch a C program from the Java code. I ran into different issues like- the Main thread getting blocked, the GUI freezing, or reading the output streams and so on. Finally I had to give up the idea and stick with launching the external command externally 😛 Had I found the Exec library from Apache Commons then, my work would have been lot easier. Anyways better late then never. I will quickly go through how one can use Exec library to launch external programs from JVM- Its a wrapper over Java’s ProcessBuilder, Runtime.getRuntime().exe().

Executing external command from within JVM often causes problems- be it in terms of the code to write and manage or in the ease of implementation. I had similar requirement in my Major project for my Under Graduate Degree, where in I had to launch a C program from the Java code. I ran into different issues like- the Main thread getting blocked, the GUI freezing, or reading the output streams and so on. Finally I had to give up the idea and stick with launching the external command externally 😛 Had I found the Exec library from Apache Commons then, my work would have been lot easier. Anyways better late then never. I will quickly go through how one can use  Exec library to launch external programs from JVM- Its a wrapper over Java’s ProcessBuilder, Runtime.getRuntime().exe(). Continue reading “Execute external process from within JVM using Apache Commons Exec library”

Installing Java (JDK) and Setting JAVA_HOME in Ubuntu (Linux)

I know lot of you starting out new as Linux users or Java learners on Linux platform find it an issue to install JDK or may be configure it to start using after installing. At time the version of java that comes with the package manager (apt-get for Ubuntu) would be an older version and you would require you to download the compressed binaries. In any case I have outlined how to configure in both the cases.

Case: 1– You would have to download the required JDK binary package from here. And follow the Steps for Case-1 below. This would involve extracting the compressed binary and then setting up the $PATH.

Case: 2– You have installed the JDK package using the apt-get and it installs JDK to some location (I haven’t used this approach because when ever I tried I ended up with an older version of JDK, so I have not explained it in detail).

Also note that usually the Linux installation might come with the OpenJDK but I have never used that before.

Steps for Case-1

Suppose you happen to download the JDK from the Oracle Downloads site here, then you can follow the below procedure:

1. Download the required Java SE package from the Oracle Download site here.  [Download the compressed Binary and Preferably Java SE 7]

2. Extract it in to a location of you choice- I used the /home/jdk<version>

3. Update the $PATH variable to locate the jdk/bin directory so that the shell can recognize the java and javac commands. This can be done by appending the PATH variable with the location to the jdk bin. In bash you can either use a seperate alias file- .bash_aliases and refer it in the .bashrc file or directly add in the .bashrc file. Here I am using a seperate alias file: .bash_aliases – In this file u can specify the variable values- for PATH, CLASSPATH and others required ones and also aliases for you various commands.

There’s a catch here: If you just initialize the $PATH variable with the jdk bin location then you will loose out the access to other bin dirs like- /usr/bin, /bin, /usr/local/bin and so on. Instead you would have to update/append the $PATH variable.

Lets assume you extracted the JDK compressed binary to- /home/jdk1.6.0_16

(Note: the dir- jdk1.6.0_16 naming would differ based on the version of JDK you have downloaded)

So the .bash_aliases file would look something like this

[bash gutter=”false”]
JAVA_HOME=/home/usr/jdk1.6.0_16
export JAVA_HOME
PATH=$PATH:$JAVA_HOME/bin:
export PATH
CLASSPATH=$JAVA_HOME/lib/:.
export CLASSPATH
[/bash]

The ‘:‘ is the separator, for windows it would be “;“. Its optional to update the CLASSPATH as one can provide it during the execution of Java program or if you are using an IDE it will manage the CLASSPATH or for that matter if you are using an tools like Ant, Maven. So just in case you are used to providing the CLASSPATH and may be use command line at times for you demo programs here’s a small tip:

Note that in the CLASSPATH- there’s an addition value “.“. This points to the current directory and will be helpful when the class files are in the current directory. Otherwise java will search for the classes in the directories mentioned in the CLASSPATH and will return ClassNotFoundException if the current directory is not part of the CLASSPATH and the required class files are in the current directory. Other option is to use –cp and specify the classpath. In that case the value of the CLASSPATH variable is overridden with the value specified by -cp.

Steps for Case-2

Suppose you have use the apt-get command to install the JDK, the you can follow the below procedure and this has to be done every time you enter the terminal or best is to put it in a .bashrc or .bash_aliases file as mentioned above:

[bash gutter=”false”]
JAVA_HOME=/usr/lib/jvm/java
export JAVA_HOME
PATH=$PATH:$JAVA_HOME/bin
export PATH
[/bash]

Restart/Shutdown problem in Ubuntu 8.10

I spent lots of time configuring my Ubuntu 8.10 installation, installing all the required softwares. The best thing i could do was to install Prozilla- the download manager which is really awesome. Also i installed all the IDEs, RDBMS that i use. But when i tried to shutdown my system it used to hang. This used to annoy me like hell. I then googled for this problem and came across the following solution which worked for me:

Continue reading “Restart/Shutdown problem in Ubuntu 8.10”

Ubuntu 8.10 Desktop Edition Available Now!!!!

UbuntuCanonical Ltd. announced the upcoming availability of Ubuntu® 8.10 Desktop Edition for free download on 30 October. In related news, Canonical also announced the simultaneous release of Ubuntu 8.10 Server Edition.

Ubuntu 8.10 Desktop Edition is designed for the pervasively connected digital lifestyle. With new 3G network support, users can move smoothly from wired and WiFi networks onto 3G cellphone networks while traveling. Ubuntu 8.10 is also built to be shared – users can start a quick “guest session” on the fly and let someone use their computer to surf the web or check email, while maintaining the security and integrity of their own data. And if that person really enjoys their brief session as an Ubuntu guest, they can put Ubuntu on any USB key and take it home to install on their own computer rather than having to burn a CD.

Continue reading “Ubuntu 8.10 Desktop Edition Available Now!!!!”

MySQL: World’s Most popular Open Source database

What is MySQL?

MySQL is an Open Source database management system(DBMS) that one can download for free from MySQL Website (www.mysql.com). MySQL is one of the world’s most popular systems for Java web applications because of its consistent fast performance, high reliability and ease of use. MySQL runs on more than 20 platforms including Linux, Windows, OS/X, HP-UX, AIX, Netware, giving the developers right kind of flexibility. 

MySQL is owned and sponsored by a single for-profit firm, the Swedish company MySQL AB, now a subsidiary of Sun Microsystems, which holds the copyright to most of the codebase. The project’s source code is available under terms of the GNU General Public License, as well as under a variety of proprietary agreements.

Continue reading “MySQL: World’s Most popular Open Source database”

MySQL: World's Most popular Open Source database

What is MySQL?

MySQL is an Open Source database management system(DBMS) that one can download for free from MySQL Website (www.mysql.com). MySQL is one of the world’s most popular systems for Java web applications because of its consistent fast performance, high reliability and ease of use. MySQL runs on more than 20 platforms including Linux, Windows, OS/X, HP-UX, AIX, Netware, giving the developers right kind of flexibility. 

MySQL is owned and sponsored by a single for-profit firm, the Swedish company MySQL AB, now a subsidiary of Sun Microsystems, which holds the copyright to most of the codebase. The project’s source code is available under terms of the GNU General Public License, as well as under a variety of proprietary agreements.

Continue reading “MySQL: World's Most popular Open Source database”