Igor Soudakevitch

+ Follow
since Dec 23, 2015
Igor likes ...
Android Java Netbeans IDE
Majored (originally) in solid state physics & physical chemistry. Worked as a researcher at a couple of R&D labs in Moscow, then at Tokyo Institute of Technology. Switched jobs to become a full-time freelance translator (dealing mainly with hi-tech stuff like space development, atomic power generation, high-speed communications, supercomputers), also worked within the UN framework as an interpreter; majored in linguistics. Uses coding extensively for lexicographical programming (e-dictionaries incl. shells) and, recently, for small-scale Android apps development. Over 50 translated books in print + one self-published volume on the OCA Java 8 Certification. Hobbies: home DIY projects, Raspi + Arduino, scuba diving. Spends two hours on fitness daily. Has a petite Japanese wife and is thinking about getting a cat, too.
Moscow, Russian Federation
Cows and Likes
Total received
In last 30 days
Total given
Total received
Received in last 30 days
Total given
Given in last 30 days
Forums and Threads
Scavenger Hunt
expand Ranch Hand Scavenger Hunt
expand Greenhorn Scavenger Hunt

Recent posts by Igor Soudakevitch

It seems you are all alone in this – but you don't have to be. Here's a list of things you can start doing right away – literally within few seconds after reading this.

1) Paul is too modest (as always) so I'll do it for him: go to Enthuware's site, get their 1Z0-808 Mock Exam Bundle and start asking questions on their forum (after all, your post mentions that you "can't even understand the explanations in most cases"). I can personally vouch for the quality of Paul Anilprem's explanations.

2) Take a look at my old post here on CoreRanch (https://coderanch.com/t/668003/certification/Finally-passed-OCAJP) – and you'll see why your words stroke a chord with me. Hopefully, you'll find some inspiration from what I had to say more than two years ago.

3) Get a buddy to prep together for the exam – and make them promise never let go of your hair as soon as they notice you are slacking.

4) Start *teaching* what you already know to a twelve year old. Do it for free, and you'll find plenty of victims to choose from. I'm dead serious: just go and TEACH someone. The responsibility alone can rewire the way you look at things.

5) When you think you do understand something, write half a dozen code snippets on this particular topic as if it's you who creates exam questions, then give these questions to your pupils and see what happens.

6) After six weeks of this set the exam date. And let this date be final. As final as the proverbial nail into this coffin of perpetual self-doubt and indecisiveness. I used to be in your shoes, so I do know. This struggle of yours is purely psychological and "self-inflicted" so to speak. You need no more books. Just code. Force yourself to write code on the clock; produce a couple of code snippets every hour to demonstrate this or that rule.

7) Finally, for the second time: start asking questions. It's amazing how often an attempt to formulate your problem more clearly suddenly gives you the answer you are looking for (google "the rubber duck debugging").
What's interesting, serialization per se has never been one of the official OCP topics; rather, it was sort of implied because the "Java I/O Fundamentals" group of questions mentions the ObjectOutput/InputStream classes.
I'll try my best to ask around but those folks at Oracle's Cert Team are tight-lipped and virtually unapproachable. A letter to Java Magazine might help, though. Another possibility is Oracle Uni, they may have connections...
My guess is you're having trouble with the last 'p'. If so, here's the answer: Whenever we deserialize an object, the constructor of the serialized class isn't called. In fact, Java calls the first no-arg ctor for the first non-serializable superclass, skipping the ctors of any serialized class in between. That's why we get 'pcp' rather than 'pcc'.
Please be aware though that serialization is not on the OCA exam, it is featured on the OCP.
Wiil tell you all about it --- but not right now. Too tired.
Got a job offer five minutes after the exam.
Guys, get certified. Don't listen to anyone who says the certification doesn't count. Just do it.
2 years ago
Yes Dave, you are completely right. Seeing that I couldn't set up Derby in a snap I decided to play with a MySQL DB instead deploying it via cPanel. Everything is working as it should now so I'm going to have all the practice I'd ever need for the exam.  
It's just practice for my exam, nothing more. Playing with that DB on my harddisk was too boring, I needed more action, like setting up a DB on the server without using cPanel and so on. Simply put, I just love to get my hands dirty and see how things work
Fifty minutes later, and it looks like I found the answer to my own question.
This is what the Apache Derby official documentation says ( https://db.apache.org/derby/docs/10.0/manuals/develop/develop14.html ):

You can specify only databases that are local to the machine on which the JVM is running. NFS file systems on UNIX and remote shared files on Windows (//machine/directory) are not guaranteed to work.

Didn't see it coming...   My OCP exam is in two weeks; what a disappointment...
I am trying to set up a remote Derby DB just for practice, and I keep getting the 'Database not found' error.
This is what I did:
- created a DB (named 'derbyDB') on my system and checked its operability; the DB proved to be fully accessible, traversable and updatable;
- uploaded the entire DB folder to the /html_public/ dir on my Hostgator-hosted website www.igor.host;
- tried to access it --- and stuck with this error: "Database 'http://igor.host/derbyDB' not found".

Here's the code I am using to access the DB:

The first try-catch checks if this particular JVM instance is able to communicate with the server at all; the result is encouraging: the specified file is accessible and readable (Line 7).
The second try-catch, however, fails miserably as if the JVM can't see the DB at all. I also tried to use my IP address (the commented out Line 14); same error...

What am I missing?

Small typos I've noticed in Chapter 2 (ebook version)

page 60, in the middle:
"The following is a rewrite of our program to use the Predicate class" -> interface

page 91, in the middle of the last paragraph:
"...as long as it implements the Food interface" -> extends the Food class

//*** Some other points of interest ***

pages 28 & 35, various places
This one is about certain static features allowed in member and local inner classes. The expression 'static final fields' seems too broad as anything instantiated, computed or evaluated at run time still would flag a compiler error:

Probably should change the wording to "compile-time constants and constant expressions" although it may present another problem as not every reader will recall at once that while String literals are compile-time constants, primitive wrappers are not, so the whole point of this change is likely to go unnoticed…

page 49, last paragraph before the code example:
"An interface may extend another interface, and in doing so it inherits all of the abstract methods" -> replacing 'abstract' with 'non-static' would account for default methods, as well, to remind the reader that unlike classes, static methods in interfaces are uninheritable and a non-static interface method is permitted to overrride a superinterface's static method. Then again, who would remember such subtleties…

pages 52 & 53
I wonder just how pedantic can be the exam when asking us what makes an interface functional. "A single abstract method per functional interface" is a good practical rule but, unfortunately, there are edge cases when it isn't true. For example, a sole abstract method that has its public twin in java.lang.Object won't make the interface functional; consequently, an interface with such a method can declare another abstract method (just like java.util.Comparator does with compareTo() and equals()) and still be functional:

page 64, number 3 at the bottom of the page:
"The compiler will not allow casts to unrelated types." -> except when the LHS is an interface type

page 77: in the middle of the last paragraph
"Furthermore, the first line of any constructor is a call to a parent constructor with the super() command" -> unless the constructor itself calls its overloaded namesake or includes a call to super().

I'm using an ebook; here's the metadata:

the string of numbers at the bottom: 10 9 8 7 6 5 4 3 2 1
ISBN: 978-1-119-06790-0
ISBN: 978-1-119-06788-7 (ebk.)
ISBN: 978-1-119-06789-4 (ebk.)

Another batch of small typos or just some points of interest (mostly in Chapter 1):

page 12, smack in the middle:
"Java ignores whitespace, which means that lines 5 and 6 could be merged into one":
Line 6 didn't specify args so boolean b should probably be removed at this point as we are not discussing unintentional overloading yet.

page 25, the second-to-last bullet point:
"Cannot declare static fields or methods" -> + static initializers + member interfaces (and classes, too?); compile-time constants are allowed, though.

page 28, the second bullet point:
Same static-related clarifications apply to the local inner classes, as well.

page 35, the "Identify and use nested classes" block:
Saying just 'static members' without further qualification again leaves out constants not to mention static initializers. What's more, this restriction is mentioned for local inner classes only; the wording should probably be extended somehow to cover member inner classes as well…

page 665, Index:
scheduleAtFixedDelay -> scheduleWithFixedDelay

Would like to report a handful of small typos and some other points.

page 3:
1) missing close paren after System.out.println(cat.id);
2) imports; Lynx and Mouse can't see BigCat right now...

page 11:
"Since only the Animal superclass has a careFor method, it executes." -> why 'only'? Lion has it, too.

page 13:
"All classes in Java inherit from java.lang.Object, either directly or indirectly, which means that all classes inherit any methods defined in Object." -> Javadoc uses 'the' rather than 'any'; after all, Object does declare a single uninheritable method, namely private static native void registerNatives().

page 29:
"four is not effectively final. Even though the assignment happens after the inner class, it is not allowed." -> In this particular example the Inner class doesn't reference the var four so the code compiles as written…

page 35:
1) "Local inner classes are … not allowed to have static members" -> 'except for static final fields' (just like on page 28 as already reported in Errata)
2) "must not declare any new or broader exceptions" -> 'checked'

Mark, you are asking a whole bunch of double-bareled questions; rather hard to answer

Whatever Oracle cert team does is well beyond anybody's control so there can be no guarantee. However, the list both Roel and Jeanne point to is most definetely your *best* bet – but only when viewed as a general guideline. Which isn't that helpful in practice. What you really should do is get a decent book such as Jeanny Boyarsky's OCA Study Guide. I did it myself and consider it one of the finest investments in terms of both my time and money. Please also keep in mind that *all* OCA-related study guides cover just a liitle bit broader spectrum of questions than the exam actually asks. It is done to account for Oracle's seemingly erratic behavior. Just a couple of examples off the top of my head: I don't seem to recall meeting a question that tested me on the fact that private methods are non-virtual; Arrays.binarySearch() also wasn't present although all books (and Enthuware Question Bank, for instance) cover this method. On the other hand, such questions might well pop up again, this time on your exam...

As for running into pitfalls... I did. Failed my first sitting epically. But it wasn't because I was prepping myself for a wrong / incomplete / overblown list of exam objectives. No, the root cause was my mental attitude during the actual exam; please don't take it as a shameless plug but entire first part of my book is all about that dazzling experience. You can download the whole story for free from my site; a much shorter version can be found right here, on CodeRanch: https://coderanch.com/t/668003/certification/Finally-passed-OCAJP.

Without thinking and purely automatically I would say none of the available options work... simply because Joshua Bloch told us "Always override hashCode when you override equals."
Mark, it appears your list was taken verbatim from the topics covered in the Java SE8 Fundamentals course at Oracle University. As such, this is *not* the list of the 1Z0-808 exam objectives. Roel was absolutely correct suggesting you look up the official Oracle certification exam page. It contains 42 subjects grouped into 9 main categories. Also, please notice that Oracle recently changed the number of the exam questions from 77 to 80; the allotted time remains the same, 150 mins.

EDIT: A little illustration of the difference between these two lists: the topics covered at Oracle Univ. course mention "Working with Dates" (group 10) and "Introducing Lambda expressions" (group 12) while the exam specificly requires us to know the LocalDate, LocalDateTime and some other date-and-time-related classes introduced in Java 8; as for lambdas, the exam will specifically ask for the lambdas that consume Predicate expressions.
I can offer the following short answer:
To be serializable, a class should implement the interface Serializable, and those two classes don't do that. Besides, System cannot be instantiated so there's no object...
2 years ago