Showing posts with label Java. Show all posts
Showing posts with label Java. Show all posts

Thursday, January 21, 2010

Build your ecplise distribution

You can build your eclipse distribution, you can choose from many plug-ins.
http://ondemand.yoxos.com/geteclipse/start

enjoy !

Sunday, January 18, 2009

Adblock Plus Bug Fixed: No more Java Applets Crashes

Adblock plus was causing a very annoying crash whenever you run ANY website with a Java applet embedded!

Starting from the V1.0.1, this bug is finally fixed and for those who removed the adblock plus plugin from Firefox or the Java plugin for Firefox can now get both back safely, Hakuna Matata :-)

Tuesday, March 4, 2008

Open-source Java Projects

I found this great portal for open-source Java projects; java-source.net

Tapestry 4 Tutorial

During the last few weeks, I've been searching for tutorials for Tapestry; the Java front-end web framework I use in my main project right now in IBM (A very nice and mature framework, you have to check it out). Frankly speaking, the resources for Tapestry (either books or articles) are not much and not easy to find, also, most of the tutorials I found are not comprehensive and contain many missing information. At last, I found the BEST TAPESTRY TUTORIAL on Devshed starting from absolute beginner's level to advanced developers, here is its URL, I use it a lot and I consider it among my main resources for developing with Tapestry, Enjoy!

Wednesday, February 20, 2008

Disable Caching in Tapestry

Tapestry strives to be as efficient as possible, so it caches page templates and specifications in order not to reload them every time when they are needed. This is a very useful behavior in a production application; however, during development it can become annoying, as we might not immediately see the changes we have just made to the page.

Thankfully, there is a way to ask Tapestry not to cache any pages in our development environment.

In Eclipse, double click on your server (Tomcat in my example) in the Servers tab, click "Open launch configuration", click the "Arguments" tab and append the line below into the VM arguments text box:

-Dorg.apache.tapestry.disable-caching=true

Restart Tomcat, Enjoy! You no longer need to restart your server during development in order to see your changes in action, this used to bug me a lot!

Source

Sunday, November 11, 2007

Setting up Java Development Environment on Ubuntu Gutsy, Part 2: Configuring Java Environment Variables on Ubuntu Gutsy

The default command line interface for Ubuntu Linux is called bash (Bourne Again Shell), and in order to add Java environment variables, we will edit a file named ".bashrc" and add our commands inside, here we go:

  1. Edit the ".bashrc" file by typing "sudo gedit .bashrc" which will open gedit; the famous Linux text editor in Read/Write mode (Note: If you don't use the keyword sudo to get administrative privileges, then the file will be opened in Read Only mode)
  2. Scroll to the end of the file and add your env. variables as in the following example which I used to define the JAVA_HOME env. variable:
    1. Append this line to the end of the .bashrc file: "export JAVA_HOME=/usr/lib/jvm/java-6-sun" where I point this variable to the location of my default JDK
    2. Save the file and exit and close the terminal
    3. Reopen the terminal and to check that everything went fine, type the following command: "echo $JAVA_HOME" which should result in displaying "/usr/lib/jvm/java-6-sun", otherwise, repeat the process again, you must have done something wrong.

Setting up Java Development Environment on Ubuntu Gutsy, Part 1

Setting the Java Development Environment on Ubuntu Linux is quite a straightforward process, you just need a little knowledge with working with the Terminal (as I prefer it, much faster), here we go:
  1. Open the terminal, update your local software list by typing "sudo apt-get update", I use the keyword sudo here to have administrative privileges of the "root" user which is needed to run many commands among which is "apt-get" (Note: pressing tab once in the terminal will auto-complete your command and double tabbing lists all available names starting with the letters you already typed)
  2. Type "sudo apt-get install sun-java6-jdk", and by the way, if you need the Java plugin for firefox as well, you can type "sudo apt-get install sun-java6-jdk sun-java6-plugin" which is unfortunately not yet available for the 64-bit Linux platforms :(
  3. Dependencies between packages will be automatically resolved by the apt-get command and installation will start after your confirmation (Note: you can accept the license agreement in the terminal by simply pressing the right arrow button and then pressing Enter, took me a lot of time to figure that out :D)
  4. After installation is complete, check you have the correct Java version by typing "java -version" in case you have multiple JDKs.
  5. If you still haven't got the right JDK as your default, simply use the "update-java-alternatives -l" command to list the available JDKs on your system and then choose the one you need by typing "update-java-alternatives -s JDKname", we're done! Simple, isn't it?