Simple Log4J Example Tutorial

Logging is very important in our project, it will record all activity include of info, error, debug, etc . With a good logging, we can trace when we get problem and fix it immediately. Now, I use Log4J as my logging framework, I will show you a simple Log4j example in this article . When you want to use Log4J, you have to make a file (whatever between .properties or .xml) that will be format your logging message. You can customize your logging properties, this is what I have :

#log4j.properties
log4j.rootLogger=DEBUG,stdout

log4j.appender.stdout=org.apache.log4j.ConsoleAppender
log4j.appender.stdout.layout=org.apache.log4j.PatternLayout
log4j.appender.stdout.layout.ConversionPattern=%d [%c{1}] %-5p %c:%L - %m%n</pre>

Continue reading Simple Log4J Example Tutorial

Using SuperCSV to parsing CSV file

I have wrote a tutorial about reading or/and parsing CSV manually in java here, but we have to think about simplicity. Now, I am using SuperCSV to parsing CSV file, I think it is more simple then we have to write a code manually. Let’s start coding.

We have to make CSV File, for an example, i make CSV with 4 row(3 content+1 header) and 4 column :


nim,name,department,dob
0811503721,Kus Andriadi,Teknik informatika,27/11/1989
0811502712,Rudi Gunawan,Sistem Informasi,28/03/1990
0711920192,Sherly,Sistem Komputer,03/05/1990

Continue reading Using SuperCSV to parsing CSV file

RESTful Web Service pada Java menggunakan Jersey (JAX-RS 1.1)

Tutorial ini menjelaskan bagaimana caranya mengembangkan aplikasi RESTful web services pada Java menggunakan Jersey yang mengimplementasi JAX-RS, Saya menggunakan Jersey 1.11 yang menggunakan implementasi dari JAX-RS 1.1. Kamu bisa download Jersey di sini. Pada tutorial ini saya menggunakan Eclipse Indigo, Tomcat 7 dan Jersey 1.11

Continue reading RESTful Web Service pada Java menggunakan Jersey (JAX-RS 1.1)

Netbeans menu bar issue in GNOME 3

I have upgrade my OS to Linux Mint 12 (Code name Lisa) that use GNOME 3 as her desktop environment, there is a little problem when you run netbeans in GNOME 3, when you click menu in netbeans, it will be dissapear as soon as you release mouse button, the menu does not dissapear if you drag it. You can see complete report about this bugs in here and you can see the discussion about it here.

Continue reading Netbeans menu bar issue in GNOME 3

Remote Desktop Linux Mint dari Windows 7

Ada banyak pilihan jika ingin meremote desktop linux dari windows, salah satunya menggunakan XRDP, saya menggunakan cara ini, karena menurut saya sangat simple dan mudah untuk diimplementasikan newbie seperti saya ini :p langsung saja langkah-langkahnya yaitu :

Continue reading Remote Desktop Linux Mint dari Windows 7