This week's book giveaway is in the OCPJP forum.
We're giving away four copies of OCA/OCP Java SE 7 Programmer I & II Study Guide and have Kathy Sierra & Bert Bates on-line!
See this thread for details.
The moose likes Developer Certification (SCJD/OCMJD) and the fly likes Passed 337/400 Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of OCA/OCP Java SE 7 Programmer I & II Study Guide this week in the OCPJP forum!
JavaRanch » Java Forums » Certification » Developer Certification (SCJD/OCMJD)
Bookmark "Passed 337/400" Watch "Passed 337/400" New topic
Author

Passed 337/400

John Stone
Ranch Hand

Joined: May 04, 2007
Posts: 332
Assignment: B&S
General Considerations (maximum = 100): 90
Documentation (maximum = 70): 69
O-O Design (maximum = 30): 30
GUI (maximum = 40): 24
Locking (maximum = 80): 44
Data store (maximum = 40): 40
Network server (maximum = 40): 40

Studying (books, tutorials): 3 months
Coding: 3 weeks
Waiting for results: 4 weeks (this long waiting is nightmare)
Source files: about 40files, around 300kb of source code
Used tools: eclipse, ant, checkstyle, locmetrics


General considerations:
I have no idea. Perhaps the project was big?, too many classes?, hard stuff for junior programmers? Coding standards?

Documentation:
I wrote many javadocs, and also some inline comments to explain 'hard parts'. Comments took about 2/5 of all source code.

O-O design:
I would give myself 25/30, because this was where I made most of mistakes. I broke sometimes "program to interface".

GUI:
I made a TabPane with 2 tabs. Search and book panel. Both had tables. One for specifying search criteria, one for search results. I saw a GUI from guy, who got 40/40 and I can't tell why is mine worse.

Locking:
I'm disappointed about Locking, because I made multiple tests, considered multiple situations (even the ones where 'classic' locking fails, see my thread on "3rd level of locking"). You can even spawn multiple threads with same cookie and can't get to inconsitent state. As I wrote in that thread, I didn't enforce locking prior to delete and I justified that in choices, perhaps that is the reason of point loss. Should thread calling lock(); lock(); be blocked forever?

I had a special lock object for every record. LockManager returned this object and methods in Data class synchronized on it.

Here is the simplified pseudo code:


lock, unlock, isLocked, delete, update always synchronized on object associated with that record, so only one thread could work with particular record at a time - and for whole duration of some operation.
I can't see how this can't be thread-safe.

I think, that it was thread-safe, and the reason of point loss is that, they expected to see some behavior, which I didn't provide, and even I had good reason for that, testing application couldn't know it. There are numerous foggy areas: e.g. "lock(); delete(); unlock(); bang!", "lock(); lock();",..

Data store:
It reads/writes file according to spec, I used hex editor to verify, that I have correct structure. I used spaces for tabbing data. My create method just inserted empty spaces, and then I called update :-).

Network server:
I registered one object to RMI registry: Contractor service - running as singleton and having only 3 methods: book, clearBooking and search. All locking took part on server side: lock(); operation(); unlock();.


All in all, I'm happy I made it.
(now focusing on SCWCD)
[ October 25, 2007: Message edited by: John Stone ]
Anne Crace
Ranch Hand

Joined: Aug 29, 2005
Posts: 223
This is great! You did that fast! I'm going on 2 years on mine.


SCJP, SCJD
John Stone
Ranch Hand

Joined: May 04, 2007
Posts: 332
Originally posted by Anne Crace:
This is great! You did that fast! I'm going on 2 years on mine.

There is a saying in my country, something like: "You can get further by walking slower." - I'm just not patient and I sacrified most of my free time.
Gabriel Vargas
Ranch Hand

Joined: May 16, 2007
Posts: 145
Hi John, i'm also wondered how you made the certification so fast. I took 1 year and 4 months (but seriously working harder 6 months), yes it's true, waiting for results is a nigthmare. I'm also focused in the SCWCD. Congratulations John.


Gabriel Vargas
SCJP, SCJD, now studying for SCWCD and working to be a better person
John Stone
Ranch Hand

Joined: May 04, 2007
Posts: 332
Originally posted by Gabriel Vargas:
Hi John, i'm also wondered how you made the certification so fast. I took 1 year and 4 months (but seriously working harder 6 months), yes it's true, waiting for results is a nigthmare. I'm also focused in the SCWCD. Congratulations John.

Thanks, as time goes I worry about the 44/80 curse less and less (but I'll be more carefull in real-life projects), and I'm focusing now more on hapiness.
Naveen Narayanan
Ranch Hand

Joined: Sep 11, 2007
Posts: 114

Congratz
You have done it in express time


SCJP 5.0, SCJD, SCWCD
Ken Boyd
Ranch Hand

Joined: Dec 10, 2003
Posts: 329
you pass that counts...

Congratulations!!!


SCJP, SCWCD, SCBCD, SCJD, BB Java2 and JSP1.1
Harish Yerneni
Ranch Hand

Joined: Sep 15, 2004
Posts: 94
Congrats, John.


SCJP 1.4 | SCWCD 1.4 | SCJD (WIP)
 
It is sorta covered in the JavaRanch Style Guide.
 
subject: Passed 337/400