Ken Kousen
Ken Kousen
@kousenit@kousenit.org

I am a Java Champion and the author of the books “Mockito Made Clear” and “Help Your Boss Help You”, (Pragmatic Bookshelf), “Kotlin Cookbook”, (O’Reilly Media), “Modern Java Recipes” (O’Reilly Media), “Gradle Recipes for Android” (O’Reilly Media), and “Making Java Groovy” (Manning), as well as over a dozen video courses at Safari Books Online. I’m a regular member of the No Fluff, Just Stuff conference tour and have given talks all over the world. Through my company, Kousen IT, Inc, I’ve taught training courses to and worked with thousands of developers.

240 posts
8 followers
  • Processing XML using Java

    Someday, and that day may never come, I’ll remember that in a DOM tree the text value of a node is stored in its first child, not in the node itself. It’s one of the things I always emphasize to my students, but manage to forget when I have to do the actual processing. Last…

  • Sometimes it all works out

    I’ve had a couple of airline adventures this week.  My class in Philadelphia ended early last Friday, so I went to the airport expecting to spend hours in the US Airways club.  Not a bad thing, incidentally, since I had a lot of work to do.  As it turned out, though, I was able to…

  • Hibernate clues

    I get it now.  In order to use Hibernate with Derby/Cloudscape, I need to use the “identity” generator: <class name=”Location” table=”LOCATIONS” schema=”EARTHLINGS”>     <id name=”id” type=”integer”>         <generator class=”identity”>     </id>     <property name=”address” column=”STREET_ADDRESS” />     … other properties … </class> This makes sense, of course, since in the db build script I have…

  • RAD, WAS, and profiles

    This week and last I’ve been teaching an EJBs with RAD6 class.  Now, the installation of RAD in the training centers was done the usual way.  That means they installed it on one machine and then distributed the image to all the others. Normally that’s fine.  The problem with doing that with RAD is that…

  • I blame the turbulence model

    When I was a research scientist at United Technologies Research Center, I worked on unsteady aerodynamics in axial turbomachinery.  That’s a complicated way of saying I worked on math and computer models of noise in jet engines. A friend of mine there was our resident mathematician.  He knew everything about everything, or at least had…

  • What a twist!

    Okay, I’ll admit it. When I first saw the commercial for the new M. Night Shyamalan movie Lady in the Water, I, too, felt compelled to say, “What a twist!”  Robot Chicken rules, and not just because it was created by Oz from Buffy, aka Scott Evil, aka Chris Griffin. On a more serious note,…

  • What a way to enter the All Star break…

    19 innings and an L.  Papelbon blows the save by giving up a homer with two outs in the 9th.  They score two runs in the 11th, only to give them back in the bottom half of the inning, missing a major baserunning error in the process.  They almost made that double play to get…

  • EJB’s in RAD6

    This week I’m back in Westborough, MA, teaching EJB’s in RAD6.  EJB’s have a rather nasty learning curve.  Here that’s made worse by the fact that the students only have the previous two training classes as experience. (This is the same group I taught Intro Java in May and Servlets and JSP’s in June.  The…

  • At least one Hibernate resolution

    Okay, one of the issues I identified is my fault. I can use JavaBeans that don’t have id fields as long as I leave the “name” attribute out of the <id> element in the mapping document. The reason I was throwing an exception is that I was still using the same test cases from before,…

  • Hibernate Challenges

    Hibernate is proving to be a bit more challenging than I originally anticipated. The toy problems seem to work just fine, but I have a real (if very small) database schema and a real (if very small) set of Java classes mapped to them already. Trying to insert Hibernate in between is providing a lot…