Java, business and... NetBeans ! [[ Jonathan Lermitage ]]

Why I have planned to move to Apache TomEE, the next-generation Java EE server

TomEE first logo (it may change later)After having worked with GlassFish and Tomcat platforms for several years, I recently planned to quit them and learn the TomEE platform. I'll try to explain why and how.

This news is also available at

Continue reading...

How to build a dictionary for the NetBeans online spellchecker (updated)

I'll try to explain how I have developed the French, German and Spanish dictionaries for the NetBeans online spellchecker : we will (re)build a French dictionary for NetBeans 7.3.

Summary :

  1. expand GNU Aspell dictionaries files.
  2. checkout the NetBeans 7.3.0 FCS sources from Mercurial repository.
  3. open the English dictionary project and make a copy.
  4. modify the copied project.
  5. make the NBM file and test it.
  6. (optional) sign the NBM file and submit it to the community for validation.

Continue reading...

This is my NetBeans IDE, and how I work

NetBeans is a powerful and highly customizable IDE. Let me explain how I use it everyday :

  1. move the status bar to a friendly place : the top-right corner. I did it because our eyes naturally check the screen from top to down and left to right, so the bottom-right corner is tiring to watch and you lose the attention of the rest of the screen quickly. Web-designers know this fact and adjust their website layouts to make them pleasant to use. Then, move the NetBeans status bar by adding the following parameter to the netbeans_default_options key of the etc/netbeans.conf file :
  2. the NetBeans local history is a great feature, but it is limited. You may prefer a versioning system like Mercurial. Simply create a local repository for each project : it doesn't consume a lot of resources and you'll take advantage of all the features of a versioning system : labels, patchs, a complete historic, etc.
  3. don't spend too much time by invoking the NetBeans menus : the toolbar exists !
  4. don't wait to enable and place your favorite panels like the console, your versioning system(s), etc. Do it now and save time.
  5. on large projects, you'll probably spend time scrolling in the Projects and Navigator views. Simply separate them.
  6. I don't like the default editor font used by NetBeans. I customized it and change some colors to make it more comfortable for my eyes.
  7. a cool feature : go to View and enable the Synchronyze Editor with Views option. A simple click on the editor will select the corresponding file in the Project / Files panels.
  8. don't spend time searching for JARs to add to your (Ant based) Java projects : elaborate a list of libraries (Ant Libraries). In addition, this is an easy way to maintain dependencies versions of your projects : some projects use the Google Guava 12 outdated library ? Simply upgrade this library with Google Guava 13.0.1 and the job is done.
  9. last but never the least, two other useful tweaks for the netbeans_default_options key of the etc/netbeans.conf file : may fix connectivity problems if you're on an IPV4 network with an OS that supports IPV6; and -J-XX:+UseCompressedOops will make your IDE to consume less memory and run a little bit faster if you're running on a 64-bit JDK/JRE.

Continue reading...

How to build NetBeans from sources (updated)

I'll try to explain how to retrieve the NetBeans IDE sources from the official Mercurial repository, and build it in two different ways : via an existing IDE and the command line (and Ant).

Summary :

  1. checkout the NetBeans 7.3.0 FCS sources from Mercurial repository.
  2. build NetBeans with an existing IDE.
  3. alternative : build from the command line.
  4. how to use JDK7 instead of JDK6.

Continue reading...

Introduction to JAX-WS 2.0 Metro Web Services for beginners (updated)

I have recently published a short tutorial about JAX-WS 2.0 Web Services (with Metro) development for Java beginners. You can download PDF and Word 2010 versions of this document.
Hope it will help beginners to start with Web Services ;)

Update :

An updated version is available in French : PDF and Word 2010. I'll provide synchronized (ENU-FRA) and reworked documents asap.

Some news before the end of the world

  • I'm proud to announce I am now on the NetBeans DZone website. You can now follow my articles at I'd like to thank Geertjan Wielenga, who introduced me to DZone. My first tutorial is about NetBeans, Tomcat and the JRebel plugin. I'll try to give more details on this technology through future articles.

DZone logo

  • I have just released Portuguese and Brazilian dictionaries for the NetBeans spellchecker module. You can check it here. I thank Gustavo for giving me the idea.
  • Dammit, I've just received my first donation ! I'm talking about TikiOne Steam Cleaner, the software I've started to develop one year ago already. I don't develop this kind of programs for money (I still loose money, for my website hosting), but getting a gift is very motivating. I'd like to thank the giver : Alan Daniels.
  • Special thank to the TikiOne Steam Cleaner contributors : Ulli Kunz for the German translation file, Zsolt Brechler for the Hungarian translation file, and Petr Kudlička who helped me to improve redistributable packages installers detection.

NetBeans 7.3 cool feature n°1 : GlassFish credentials memorization

NetBeans 7.3 is still under development (you can download and test the Beta2 build) but it already offers many interesting improvements. I'll talk about one of them :

The NetBeans IDE allows you to register application servers like Apache Tomcat and Oracle GlassFish. Once registered, you can deploy application, start and stop the servers, etc.
Usually, the first thing to do on a fresh install of a server is to update the administrator password.

NetBeans 7.2 (and previous versions) is able to memorize the administrator of Tomcat servers but - this is annoying, it is not able to memorize the administrator's password of GlassFish servers. Actually, it is designed to use the default account and password of a fresh GlassFish installation only (something like "admin"/"admin"). If you modify the password and/or the administrator's account name, NetBeans will ask you for GlassFish credentials every time you start the IDE; you can't memorize credentials :

NB72 ask for GlassFish credentials

Continue reading...

Good Deal : (one of) the best VPN and a permanent discount

Vypr VPN logoIf you are looking for a VPN offering :

  • servers around the world.
  • no limit or quota on flows ant duration (I'm testing for 12 months on a 100Mb/s connection : no clamping).
  • an excellent ping (less than 15ms slower your ping : I used to play various FPS and Racing video-games via a VPN).
  • PPTP, OpenVPN, L2TP.

Most of the people seeking a serious VPN will advise Golden Frog VyprVPN (

The cheapest offer costs €12.49 per month (all you need, by renouncing OpenVPN and L2TP to use PPTP only). The complete offer costs €16.49 per month.
This is already an excellent price, but you can use a trick to reduce the subscription of about €4 per month. Once subscribed, ask to terminate your contract : Golden Frog will offer you to continue your subscription with a preferential rate. The good news is that this reduction is not limited in time: it's been more than 6 months that I benefit from this discount.

You can have the very best in terms of VPN for less than €9 per month. So, what to remember :

  • subscribe to the offer that suits you.
  • initiate a termination.
  • accept the new subscription offer.
  • enjoy !

Attention : VyprVPN is also offered at Giganews, but it is decked out various additional services (online storage...) that will increase the invoice.

NetBeans : some useful tips and links

Here is a list of some tips and links for NetBeans. This page will be updated as often as possible :)

Tips : NetBeans start-up parameters

It is about parameters you can add to the etc/netbeans.conf properties file (located in the NetBeans installation directory), in the netbeans_default_options property. Additional parameters can be found at the NetBeans : Tuning JVM switches for performance web-page.

Warning : you've probably heard people advising to set the same value to the Xms and Xmx parameters, in order to avoid the JVM to manage the heap size (typical explanation : each time the JVM increases the heap size it must ask the OS for additional memory, which takes time). This is a bad idea ! JVMs are designed to perform optimizations according to the Xmx/Xms ratio (and some other parameters). Assign the same value to these switches is unnecessary (the only gain would be pointless for the JVM to allocate more memory, but it must be recognized that this task consumes only very limited resources and occurs infrequently). In addition, you will notice an interesting thing: since Java7 and the G1 garbage collector, the JVM will detect if you set the same value to the Xms and Xmx switches, and will replace your values by its own. The Xms = Xmx tip is definitely unnecessary when G1 is enabled ;)
Please note that it concerns Sun/Oracle HotSpot JVM only. I have not checked the behavior of Oracle JRockit JVM, nor IBM J9 JVM.

Internet connection problems ? (if you cannot download plugins, check for updates, etc)

If your Operating System uses IPv6, you can try to ask NetBeans to use IPv4 only. Add the following switch :

How to place the status line in the menu bar

Add the following switch :

Continue reading...

TikiOne-Steam-Cleaner 1.2.1 : localized, faster, better

Update (Wednesday 16 May 2012) :

Version 1.3.0 it out ! It introduces many changes (the changelog file is shipped with the program package). Click here to download (322KB).
As usual, it is a Java program. If you don't have installed Java on your system, you can use a version which already includes it : click here to download (27MB).

PS : I can now devote more time to complete the tutorial on creating dictionaries for the NetBeans online spellchecker ;)
See you soon.

Continue reading...

- page 1 of 2