Loading...

Thursday, April 9, 2009

Our first official book review in on its way...

by Eduardo Rodrigues

Great news!

We have been contacted (surprisingly) by Packt Publishing a few days ago and asked if we would be interested in read one of their new books and then publish an independent review here in the blog. We were very honored and flattered with the offer, so we obviously accepted it.

The book is "Processing XML documents with Oracle JDeveloper 11g" by Deepak Vohra.

One good thing that immediately caught my attention as soon as the book arrived today was seeing the name "Frank Nimphius" in the list of reviewers. This is certainly a good sign :)

Anyway, Fabio and I already have the book and we'll both read it and then compile our comments in a 4-hand post to come. We hope it wont take too long (and also hope this will be just the first of many other book reviews to come).

Cheers and keep reading!

Tuesday, March 24, 2009

Java and the Timezones

by Fábio Souza

Timezone, when using Java, can be something tricky. You can get surprised when you change your OS timezone (something common to countries with DST) and it doesn't take any effect on your Java programs. What does Sun have to say about that? It can be found at their FAQ:

Do my operating system's timezone patches fix the Java platform's timezone data?

No. The Java SE platform's timezone data is not read from the local or host operating system. The Java SE platform maintains a private repository of timezone data in locally installed files (.../jre/lib/zi) as part of the Java Runtime Environment (JRE) software. Applying whatever operating system timezone patches (for example Solaris OS, Linux, Windows) will have no effect on the accuracy of the Java SE platform's timezone data.

Sun recommends you to maintain all JVM up to date to avoid Timezone problems. To specific cases where a Timezone update is needed, they provide a tool called TZUpdater. TZUpdater is a JAR that contains timezone informations provided by Olson Timezone Database. To update the JVM's timezone you need to execute TZUpdater's most recent version like this:

java -jar tzupdater.jar -u (don't forget to check if you have read/write access to Java's directory structure)

We are ok about Sun's JVM... But the solution is the same to all JVMs? Not really =), but it is very similar to IBM JVM and Oracle JRockit. In all cases we either have to download a program and execute it to update the installed JVM or wait for the next JVM update release.

Here are some useful links:

Sun:

IBM (thanks to my friend and co-worker Frederico Hakamine):

Oracle:

Tuesday, February 10, 2009

Web Component Developer Exam (SCWCD) for JEE 5

by Wellington Carvalho

I hope my feedback can help those who want to prepare for The Web Component Developer exam (SCWCD) for JEE 5. I will use the same structure of an older post that Fabio Souza wrote to pass his own experience with SCJP 5 exams.

Main reading resource

Head First Servlets and JSP: Passing the Sun Certified Web Component Developer Exam

The first edition of the book deals with J2EE 1.4 spec, but the changes in JEE 5 were
most related to EJB 3, so I think you won’t have troubles with the exam! But if you want, the second edition of the Head First Servlets and JSP is prepared for JEE 5 and you can find it here: http://oreilly.com/catalog/9780596516680/?CMP=AFC-ak_book&ATT=Head+First+Servlets+and+JSP

Main resources for exercises

I used an application similar to Whizlabz named Enthuware. Enthuware is an exercise tool with many tests that covers all the objectives mentioned by Sun. The exercises of Enthuware are very similar to the exam, and you have good explanations, no matter the answer is right or wrong.

In order to get a better performance in your study you should take the standard tests of Enthuware sequentially and exclusively when you have read the entire SCWCD book.
To evaluate your chapter’s knowledgement you should take the objective-wise tests only after reading the chapter. To get the full version of Enthuware you will spend around US$29,00 which is cheaper than the other: Whizlabz (US$74,95). If you fail the SCWCD exam the company guarantee your money back (must get at least 70% in the tests).

My study schedule

It took me 35 days to read all the 14 chapters and to do all the tests
and exercises of Enthuware. I spent 2 hours and a half per day to read the chapter and 1 hour to do the exercises. In the week before the exam I just took the standard tests and reviewed the material.

I think this schedule is reasonable to people that is working with JEE, however if you aren’t using JEE in your daily work you should reserve a longer study time.

The exam

In my opinion the exam is relatively easy to people that have work experience in JEE development, however you need to pay attention to every detail because the exam has good tricks hidden in the code. But don’t get scared. Most of them are covered by Enthuware.

To take this exam you must know about all the objectives listed by Sun, but with a special care on these below:

Servlet Technology Model
Expression Language (EL)
Custom Tag Library - Classic Model
JSP Standard Actions

It is important to remember that you need at least 70% to pass, but trust me (and Enthuware), if you start scoring more than 70% in the standard tests, you will pass easily.

Monday, November 24, 2008

SCJP 6 Upgrade Exam (310-056)

by Fábio Souza

Guys and girls,

I guess the best way to start this post is with my appologies. I really wanted to post it earlier, but you all know how things are =P.

It has been almost three months from when I took the SCJP 6 upgrade exam (310-056). The exam follows the same SCJP 5's (310-055) difficulty level where it's needed to pay attention to every detail. There is time enough to do everything calmly but the tricks are there like they were in SCJP 5. The "secret" is still the same: MAKE LOTS OF EXERCISES. In my case, my knowledge on 310-055 was pretty sharp and I just had to work out the new features of Java 6. Lets talk about the exam and how to go for it.

PS: To get your knowledge on 310-055 "pretty sharp", I recommend my previous post: SCJP5 and 6


Technical information:
  • Number of Questions: 48
  • Score needed: 66% (32 of 48 questions)
  • Time limit: 150 minutes

Resource material:

For those who don't have (or want to have) specific SCJP 6 material (the same of the previous post):

For those who want to buy new material:
* I've never read this book but if the quality is the same of the previous version, there is no doubt it should work.

I made an abstract to help me with the SCJP 6 content by comparing the requisites for both exams (310-055 and 310-065), and studying the Java 6 new features. Here it is:

- Ordered and Sorted comparison:

Click me

- NavigableSet and NavigableMap methods comparison:

Click me

- Other things:
  • Deque: in this interface's javadoc there is a full explanation about the different methods that can be used to add/remover an object of this queue. Be sure that you know the ones that returns an special value (generally null) or that throws an exception instead, when something goes wrong.

  • ArrayDeque: the best (fastest) way to make FIFO and LIFO queues. This is also the recommended implementation when we need a Stack.

  • LinkedList: choose this implementation when objects should be added/removed between the first and the last element.

  • java.util.Collections: there are two new methods in this class, newSetFromMap and asLifoQueue, learn them.

  • java.util.Arrays: avoid System.arraycopy, use the new methods Arrays.copyOf or Arrays.copyOfRange instead.

  • java.io.File: getFreeSpace, getTotalSpace, setExecutable, setWritable, setReadable. These are new methods to learn.

  • java.io.IOException: there are new constructors that enable exception chaining IOException(String,
    Throwable)
    and IOException(Throwable).

  • java.io.Console: this is a new class and its instance should be got using System.console. I think all of its methods are importants, take a look at the javadoc. Pay attention to the Console.readPassword, it will fill an array with the provided password, it is a good think to know how to clean this array. This is a good way: java.util.Arrays.fill(src, '\0') and this is a valid and bizarre way: java.util.Arrays.fill(src, 0, src.length, (char)0).
SCJP 6 - To do or not to do

Because the difference between Java 5 and Java 6 is very little, in my opinion, people who already have the SCJP 5 don't need to worry about SCJP 6. For those who don't have SCJP 5 or any SCJP certificate at all: DON'T DO the Java 5 exam; GO STRAIGHT to Java 6.
In my exam (just to freeze: 310-056), the Java 6 content was kind of ridiculous. Only THREE specific questions. It means (this is not an advice) I could take the SCJP 6 exam without any knowledge about its specific content. I'll tell you how it was like:
  • java.io.Console: A question about its usage. It was necessary to know how to get the Console instance and how to get typed lines.

  • java.util.NavigableSet and the implementation java.util.TreeSet: The question was about how to use them focusing the method subset.

  • Chosing the best Collection implementation: I don't remember exactly what was asked, but keep this in mind:

    • Stack or queue needed: use ArrayDeque.

    • Removing/Adding elements that might not be at the top or at the bottom: LinkedList.

    • Sorted Collection (unique elements): TreeSet.
That is all folks! Please send your comments, corrections and share your own experiences.

Friday, August 8, 2008

SCJP 5 and 6

by Fábio Souza

OK, I know that is a little late to talk about SCJP 5 but I will give my feedback about the exam. This will help people that feels unprepared to take SCJP 6 (that was my case) and the ones that are going to take this new version, what I know is that both exams (5 and 6) are very similar.

Resources:
  • Main resource material: SCJP Sun Certified Programmer for Java 5 Study Guide (Exam 310-055), by Katherine Sierra (Author), Bert Bates (Author). This book is just great! The authors are very careful with the explanations and they also made very good illustrations. Each chapter ends with the "Two-minute Drill" section and the exercises. The "Two-minute Drill" has an abstract about the chapter that makes very easy to review forgotten items. The exercises are very well written, and every answer is explained (both wrong and right).
  • Main resource material for exercises: MasterExam. My SCJP Sun Certified Programmer for Java 5 Study Guide (Exam 310-055) book came with a CD containing the MasterExam software. This software gives two ways to do its questions, like the real exam or "ad-hoc". The MasterExam's questions are like the book. A "permission" to get a bonus exam also come with the CD, you just need to register on their site and then download the program.
  • Other resources for exercises that I found:
    • Whizlabs: There is a software like MasterExam made by Whizlabs. It seems to be a very good software. Its interface is great and you have the possibility to do "adaptive" tests. I downloaded a trial version from their website and I liked it pretty much.
    • EPractize: Their software is like the MasterExam too but it doesn't have any strength point. I didn't like the software's interface. I also downloaded a trial version from their website.
    • "TestKiller": This one is an exercise's book and seems to be made by Troytec. It's a very weird book, with a lot of writing mistakes on it. The strength point is that it promises to cover only questions from the real exam. When I took the exam I had the feeling of recognizing one or two questions (I took a look on 60 from 224 questions of this book).
My study schedule: That was the way I worked out to pass the exam.
  • 8 months to read the SCJP Sun Certified Programmer for Java 5 Study Guide (Exam 310-055) and to do all exercises. It took me something like one hour per day (only workdays). It's a good way to start because you can understand how Java works without pushing yourself.
  • 1 month to read again all "Two-minute Drill" sections and the most complicated chapters (chapters 7, 9, 8, 6, in descending difficulty order, in my opinion).
  • 4 days (eight hours per day) to do A LOT of exercises. This is the main point. The exercises are full of tricks and the only way to become familiar with those tricks is doing a lot of exercises.
The exam: In my opinion, the exam is difficult. You have to be really confident before taking it. A good thing that I noticed was that the time is enough to do everything with attention and patience. In my opinion to take this exam you must know about everything, but with a special care with these points below:
  • Threads.
  • Generics.
  • Methods Override/Overload (and covariant return).
  • Box/Unbox.
  • Method calling with widening and autoboxing.
  • Access Control.
  • java and javac commands.
  • Differences between collections (Ordered, Sorted, Hash).
  • How equals and hashCode works with collections.
  • Inner Classes.
Differences between SCJP 310-055 and 310-065 (you can find it here):
  • Questions concerning System.gc() have been removed.
  • Coverage of the java.io.Console class has been added.
  • Coverage of navigable collections has been added.
  • Several of the previous objectives have been strengthened (so you can expect more questions and more detailed questions on them). These strengthened objectives include: exception handling, collection classes and collection interfaces, assertions, threads, and flow control.
  • Number of questions: 310-055 = 72; 310-065 = 72
  • Pass score: 310-055 = 59%; 310-065 = 65%
  • Time limit: 310-055 = 175 minutes; 310-065 = 210 minutes
Advice: If you aren't feeling confident to take the SCJP 6 exam just because you don't know what is new in this version, don't take the SCJP 5. I did it and I am a little regretful. There is no "SCJP 5 to 6" exam, there is only one "upgrade" exam to version 6 called "Exam 310-056". In this exam you have to prove your Java 5 knowledge again. Well, soon I will take the 310-056 and then I will post about it.

Please comment and share your experiences with SCJP (any version is welcome :)).

Links: