Skip to main content

Masking complexity

Posted by daniel on April 11, 2005 at 8:54 AM PDT

The problems with making things too simple.

I spent the weekend hacking up some C code. I'd forgotten so much it wasn't funny. Some of it was easily fixed by thumbing through K and R. (By the way, what's the Java equivalent of K and R?) I'm so used to coding in two steps: get it right and then make it pretty. Refactoring felt awkward in C. And who do these methods belong to? Wait - they aren't methods they are functions. This was a more vivid distinction wandering from the Java world back to the C world than it seemed to be when I came to Java from C. Whew - it's time to sharpen the saw and learn a new language.

Of course there were minor issues with explicitly working with pointers again. Sure I had to remember to declare methods to accept pointers like foo (bar *) and then call them using foo( & bas). That's natural - isn't it? We have pointers in Java we just pretend we don't until we get a NullPointerException. We pretend we don't read Strings in by locating the beginning of the String in memory until we have to read in a byte array from a Stream. Sure, we have ways of masking this complexity - but that brings me to a blog on our front page today.

In today's href=""> Weblogs , Ben Galbraith shares some observatiosn from Microsoft Technical Summit, Threads, and Swing. Ben raises a key issue about this masking of complexity: "While some advise Swing developers to avoid spawning threads as much as possible, developers wishing to create snappy, high-performance Swing GUIs will need to do the opposite: aggressively utilize an asynchronous multi-threaded architecture.

And there-in lies the rub. As if the Swing API weren't complex enough, it turns out that wrangling with highly asynchronous multi-threaded code bumps up against some of the toughest problems in modern software development. "

John Reynolds has been thinking a bit more about GNU licenses and small startups . He worries that "If you are a relative newcomer and you don't Open Source your code, customers will probably not take the chance of using your software. If you do Open Source your code, using an Apache style license, then an bigger company can tack on some proprietary extensions and provide a more compelling product."

Rich Unger has written two blogs on frameworks. In his first he explains the need for desktop frameworks such as Netbeans and Eclipse. In his second he looks at the server side in More Frameworks Than it Would Be Wise to Shake a Stick At. He looks at the richness of choices of frameworks and puzzles that you can mix and match and hook more than one together in your web site.

Jack Shirazi wants support and he's willing to pay for it. In Sun - don't you WANT to make money? His advice is simple: "Find out what your customers want. Then make it easy for them to get it from you."

The world of rich clients is growing. In Also in
Java Today
, How do you specify how much processor time a JVM should have? How do you speed up Application start-up time without compromising interapplication isolation? In Building a Scalable JVM Janice Heiss describes some of the techniques used by Grzegorz Czajkowski, to "allow for collocation of multiple applications in a single instance of the virtual machine. Applications are isolated from one another and each 'thinks' it has the whole virtual machine all to itself. Aggressive transparent sharing of metadata, such as bytecodes of methods, reduces application footprint and start-up time. Furthermore, through building on the foundation of an isolated Java computation (known as an 'isolate'), the team has developed a set of resource management techniques and APIs which allow developers to define new resource types, partition resources among computations, and control resource management overhead."

The authors of Head First Design Patterns think you won't necessarily get the most out of their book by just blasting through it in a few sittings and not really digging into it. "So we've got a suggestion for tackling patterns that's fun and social, and provides a great environment in which to learn patterns: form your own study group." In Form Your Own Design Pattern Study Group, Elisabeth and Eric Freeman offer recipes for starting a study group, a plan for working through the book as a group, and some questions for each chapter. They also hope you'll come up with questions of your own and post them as talkbacks to the article.

In Projects and
, as of Friday the early access of the JAXB RI 2.0 is out. As Kohsuke Kawaguchi blogs, "this early access basically implements the JAXB 2.0 specification early draft 2 with some differences." His entry outlines the changes to the JAXB spec.

The NetBeans Community's Brian Leonard follows up his presentation at the NY Java SIG with answers to the questions he received during the presentation. His blog entry NetBeans, NYC and Springtime answers many of the questions you might have.

There's a post on native libraries and applets in today's Forums. Stanleyh writes "The most likely way we will improve native library deployment is to support JNLP extension in Java Plug-in, and native libraries would be downloaded into the local cache (that user has write permission) and used by the applets during deployment."

JHannes writes "The main reason I focus on mixins is that I see how many of the introduction uses of AOP are better handled by mixins."

In today's
News Headlines

Registered users can submit news items for the href=""> News Page using our
news submission
. All submissions go through an editorial review before being
posted to the site. You can also subscribe to the href=""> News RSS

Current and upcoming Java

Registered users can submit event listings for the href=""> Events Page using our href=""> events submission form.
All submissions go through an editorial review before being posted to the

Archives and Subscriptions: This blog is delivered weekdays as
the Java
Today RSS feed
. Also, once this page is no longer featured as the
front page of it will be
archived along with other past issues in the href=""> Archive.

The problems with making things too simple