An old new beginning

30 08 2011

After three years of wandering I’m returning to my roots. Next Tuesday is my first day at Oracle, where I’ll be the technical lead on the Mac OS X port of OpenJDK for Oracle. This may sound like I’m staging a coup, but I’m not going to be taking anything away from Mike Swingler, Bino George, and everyone else who has been hard at work on the core of the Mac port. I will be starting on the non-open parts of the JDK, which means the Java Plugin and Web Start, and then looking into bundled application support.

I don’t expect to be working by myself on this for long — we still need engineers who know Objective-C and Cocoa and have a good background in Java. Search Oracle’s recruitment site for more details; I’ll add links in the next day or so. We are actively recruiting for these positions, so please don’t hesitate to ask for more information. Candidates who can work in the Santa Clara, CA, office are preferred.

For those of you who have known me over the years, this may not sound like a new challenge, but it is. I’d like to think of it as picking up where I left off rather than returning to an old job. And, hopefully, I will have cool things to write about again as time goes on.





Comment cleanup

20 02 2011

I did some comment pruning today. All were of the ‘I’m trying to reach you…” variety. The easiest way to contact me is to follow/DM me on Twitter, and there’s a link on the right side of the page to let you do just that.





Secret smoke screens

3 01 2011

Chris Adamson wrote today about private APIs in the Mac OS X Java AWT. He also links back to James Gosling’s post about Java on the Mac. First, I’ll answer Chris’ main question:

But… is it true? How big a deal are secret APIs in OSX and iOS anyways?

Yes, it’s true that there were (are?) non-public SPIs in the Java AWT. I assume that’s still the case; I’ve been away from that code for close to 3 years now. I’d be really surprised if it wasn’t.

When we switched over to the Cocoa-based AWT for Java 1.4 and later, there were some things that just couldn’t be done without it. Dr. Gosling is correct: supporting Java2D drawing from any thread, while also drawing fast and within the constraints of Cocoa’s main-thread requirements needs some help from CoreGraphics. The other big area I’m most familiar with is support for AWT applications run from a command line. Without getting into too much detail, typing ‘java MyAWTCode’ from a Terminal window violates a whole lot of assumptions about what an application is on Mac OS X, and needs a lot of cooperation between the AWT and the Process Manager to sort it out.

In any event, here’s the thing to remember: at the time we wrote all of that code, the concept of OpenJDK or contributing code back to Sun didn’t even exist. We never thought we were writing code that the public might see some day, and we were part of the OS, anyway, so it should come as no surprise that an internal API was used here and there. This is also why it’s no small task to just hand over the AWT implementation to Oracle and walk away.

Chris also mentions the Cocoa SWT. As he correctly points out, the SWT does not use any private calls, but there are two main differences in the Cocoa SWT and Cocoa AWT: First, everything in the SWT must happen on the main thread. Some graphics code can operate on another thread, but not all of it. Second, the Cocoa SWT was developed in 2008 on Leopard. It’s a different Cocoa/CoreGraphics API now than what we had in 2003-2004. I think that there are some areas where the SWT could use a private API or two to implement features that were lost in the Carbon to Cocoa transition, but generally speaking, no, private APIs aren’t necessary. Experience and hindsight also help, too.

And, with that, you have the answer to the second question: It’s just not that big of a deal today, but in terms of the AWT that’s not the stumbling block. I’m pretty sure that Apple could go back and reimplement those parts that used private APIs, but doing so at this point entails a lot of work for not a lot of benefit.

As for Dr. Gosling’s talk, I think there is a fair amount of revisionist history there that I really don’t want to bother trying to correct, because I’m sure I’ll miss some of the details, too, and in the end, it really doesn’t matter at this point. Apple and Oracle working together on OpenJDK is a good thing for Java, and I wish them well.

I think I will leave it at this, however: ‘secret APIs’ were not the problem. The issues that needed resolving were not going to be settled by a group of engineers from two companies working together. And that, I believe, is the real story of Java on Mac OS X that won’t be told for a very long time.





I was wrong…

13 05 2009

I admit it; I was wrong. There will be a Java session at WWDC this year.





No Java at WWDC this year?

8 04 2009

Well, it’s finally happened. As of April 8, there are no Java sessions at Apple’s WWDC this year. I deliberately put in the weasel phrase ‘as of…’ because the list doesn’t include the “State of the Union” sessions. It also says “View the first set of sessions”, which means there’s still a chance.

I hope there is at least a Java Overview – it would be great to be able to show off the Cocoa SWT work. If you aren’t using it already, now would be a good time to start! Grab a nightly or integration build and, as always, find bugs and file them.

Update: Yes, there will be an overview session (at the very least), and I’m working on a demo of the newness that is Cocoa Eclipse 3.5.





A breath of fresh air

8 04 2009

Hmmm.. I haven’t been writing much lately. Not that I was all that prolific to begin with, but three months is a while. I guess it took me longer to recover from that surgery than I thought.

Well, I can happily say that it was worth the agony, because I’m now breathing better than ever and the spring allergy season was the mildest I think I’ve had in ages. If you have been thinking you need this surgery I highly recommend you get it done.

Having said that, it not like the recovery wasn’t without excitement, however. I stupidly got on a plane for Europe about 3 weeks after the operation and got a bad nosebleed that required an emergency room visit. I really should have waited until after the new year to have it done, but it’s all over now.





Rabid porcupines? No, drowning in a slime pit is more like it.

5 12 2008

It’s not a well-documented rule of blogging, but there does seem to be an unwritten rule that when you have a quality-of-life-improving medical procedure, you need to write about it. So, that’s what I’m going to do this evening.

Almost every year for the past 15 years or so, I’ve had a sinus infection at some point during the winter months. Usually in February I catch a cold that seems to linger on for a week and a half, and then I go to the doctor and get two weeks of antibiotics. When I moved to California, I thought ‘hey, there’s no winter here to speak of, so maybe it won’t happen this year.’ Wrong. Last February I had my worst bout of sinusitis ever, which turned into a nasty case of acute bronchitis on top of it all. I think I missed a good week of work and ever since then I have felt like I have been breathing through two cocktail straws glued to my nostrils.

So after regular, daily blasts of Flonase into my nose and getting no relief I finally went to an otolaryngologist. He looked into my nose and 30 seconds later said “Is one side of your nose consistently more blocked than the other?” Well, yes, come to think of it… “Did you ever have any accidents when you were younger? A broken nose or fist fight?”

Shortly after he said that, the TiVo that is my mind rewound to 29 years ago.

My brother and I are nine years apart. That means I was right around 11 years old when he was learning to walk. One summer afternoon I was lying on the floor in our living room, and he was on the couch. Somehow we decided it would be fun for him to roll off the couch, and then I would catch him as he rolled off, and gently land him on the floor like an airplane. He then climbed back up on the couch and we did this over and over for about an hour.

To this day I don’t know exactly what happened next. The TV may have been on and he got distracted. Maybe his legs gave out and he lost his balance. But the next thing I knew, all 28 pounds of him had sat squarely on my nose, and I ran to the bathroom to see what happened. It didn’t really hurt at the time. In fact, I think I wound up giving him a hug because I saw that one side of my nose was completely clear and I was breathing so well for the first time in a long time. Little did I know…

“You have a badly deviated septum,” the doctor continued, “and your turbinates have swollen to compensate for the change in volume. That’s why you get an infection – you can’t clear out the mucus that collects in your sinuses.”

So, on Wednesday I had a septoplasty and turbinate reduction at Eden Hospital in Castro Valley. I’ve had a number of surgical procedures done over the years, and this one went better than any I’ve ever had. Everyone was a pleasure to work with, I didn’t get sick from the anesthesia, and the anesthesiologist actually put in the IV without (significant) pain on the first try.

That’s not to say I feel great, however. At the moment I feel like I’ve been punched in the nose and teeth. I still need to flush out my nose with saline every hour, which helps a little bit, but what I really want to do is blow my nose, but I can’t do that because if I do so much as graze my nose with anything I’m about ready to jump through the roof, let alone blow out the splints. I have to breathe through my mouth, which after about 2 minutes feels like you’re eating wads of cotton.

The doctor sure makes it sound easy. “You’ll feel awful when you go home, and will be pretty much out of it on Thursday, but by Friday you’ll feel like reading email or even doing some work. On Monday you’ll be back to work.” To this I say HA!! I’m now at Day 3, post-surgery, and I don’t feel dramatically better than I did my first night at home. I’m hoping it’s a case of needing to get worse before it gets better, but right now I’m nowhere near better than before. I’ll see how I feel again on Thursday when the splints come out.





Oh right, _that_ election….

19 11 2008

The election came and went and I never wrote about it. I guess that’s because there wasn’t much to write about. The precinct I managed has about 1000 registered voters and during one of the many lulls we estimated that about 55% of them were vote-by-mail voters. Of those remaining, about 380 actually came in to vote or drop off their ballots, so if all of those VBM voters returned their ballot we did pretty well.

On the whole, the day was pretty uneventful. We were led to believe that there would be an onslaught of voters all day, so there were seven of us staffing the polls. But, except for the line that formed when the polls opened, we outnumbered the voters almost all day. Some other highlights:

  • About 15 people were waiting to vote at 7 a.m. From that point on we never had more than 5 people waiting to vote.
  • It’s amazing how many people don’t look at their sample ballot. It says very clearly that your polling place may have changed but we had to send at least a dozen people down the road to vote in their assigned location. It doesn’t matter where you voted in the last election — you have to look at the information you were sent.
  • I had to deal with my first case of ‘electioneering’ this election. A woman, her child, her husband and his father arrived, and she was wearing an Obama t-shirt and stickers all over her face and their baby stroller. This, of course, is a no-no, so I had to patiently explain they couldn’t come into the polling place with the t-shirt. Interestingly enough, her father-in-law, who was visiting from overseas, was more up on the law than she was, and loaned her his blazer so she could go in and vote. It all worked out in the end, but much like the last example, it’s not like this should have been a surprise.

Probably the biggest reason that the day went so smoothly was that I had a great group of folks working at the polls with me. Half of them had worked at a poll before, and the other half were motivated to learn and took the job seriously, which meant we had no glitches and were done with the cleanup in 45 minutes. I’m looking forward to the next election — except of course, for the campaigning and ads.





Resist the urge…

11 10 2008

When we lived in Ohio, I envied homes with a built-in sprinkler system. The little heads that popped up and delivered a perfect circle of water to your piece of the Western Reserve. The ‘pfft, pfft, pfft’ of an impact sprinkler doing its job on a Saturday morning. And, to top it all off, a timer. Not just any mechanical timer, either, but a mini computer that turns on each carefully designed zone of the system, because you don’t have enough water pressure to water the whole yard and your flowers all at once.

Granted, you could only use it about 8 months out of the year, and even then I can’t recall a summer where it was dry enough to warrant regular, automated watering. Sure, come July or early August the grass would start to look a bit straw-like, and Dick Goddard would remind you at the end of the forecast that it’s probably a good time to get out the sprinkler, but if you had one of those in-ground systems, well, you, my friend, would be all set. Heck, Cleveland Heights even gave us a rebate on our water bill if we promised that we were watering our lawns in the summer, which drove up the usage. “Go ahead and water” seemed to be the message, “because we’ve got a whole Great Lake next us, so there’s plenty more where that came from.”

Well, I got my wish. If you have read this far, though, you know that the rest of this post is going to be one of those ‘be careful what you wish for’ tales, so if you live in one of those hip, transit-oriented developments or think lawn is a four-letter word, you might want to just go read Daily Kos or, if you want something useful out of your blog perusal, try Unclutterer.

We do not have a big yard here in Pleasanton. The entire lot is 7400 sf, and about half of that is grass. As California developments go, however, it’s fairly large. That’s because we live at the end of a cul-de-sac, and have a wide, wedge-shaped lot. We have a decent amount of privacy, and enough room for our daughter to play and for the dog to run around.

The yard came with an in-ground sprinkler system. Two zones in the front cover the grass and shrubs, and four in the back cover two halves of the grass plus two sets of shrub zones. When we moved in the geek part of me thought this was the greatest thing in the world. The previous owners put in a new controller that lets you water any hour of the day or night, for however long you want, and then every 2 or more days, if that’s what you need. And, one trip down the irrigation aisle at Lowe’s with its wide variety of sprayers, shrub heads, valves, and other assorted accessories is all it takes to get your creative homeowner juices flowing.

Well, what turned out to be the coolest thing when we moved in is slowly becoming the bane of my existence. To date I have replaced 4 of the pop-up sprinklers that were broken in some way, dug up and re-piped one of the 3/4″ supply lines to one of the impulse sprinklers I snapped off in a fit of frustration, and tomorrow I need to replace a diaphragm on one of the valves, which has started leaking all the time as opposed to the small pinhole squirt it had a few weeks ago. It does this even when I shut off the valve to the entire system, which is really starting to concern me. Two of the remaining impulse heads are somewhat broken because the don’t retract all the way into the ground, and due to overgrown shrubs, don’t water all of the parts of the grass they were designed to cover. I suspect they are filled with tree roots, like the one I accidentally ripped out of the ground a few weeks ago because it was installed in a physically impossible orientation next to a birch tree that decided it would tap into the free water with its root system. (just how do you screw in/out an 18-inch tall sprinkler in a space surrounded by 1/2″ thick tree roots?)

Maintaining the system isn’t too tough as the sprinklers just screw into the holes in the ground and PVC pipe is pretty easy to cut and connect with cement, but I keep thinking that there’s got to be a better system. Any repair involves careful digging so you don’t break any of the surrounding lines, and new sprinklers seem to have a high failure rate. I’ve had to return at least half of the new ones I bought because they don’t pop up or otherwise leak out the top.

When all is said and done, it’s probably a good thing we have it because given how dry it’s been this year everything would be dead by now. I’m also not interested in dragging out a hose every couple of days, so the convenience factor can’t be ignored, but the hassle doesn’t seem to justify the results. Of course, I haven’t yet found a way to run the controller from the computer yet, but once I do, I may forget all of the hassles I’ve had up to this point.





Called to duty

11 10 2008

Well, that didn’t take long. I’m now going to be an inspector at Pleasanton Middle School. I’m really looking forward to doing this. Yes, getting up at 5 a.m. is going to be a pain, but once you get going it’s not that bad. Plus, it’s a general election, so there’s only one ballot to worry about. I took a great picture of the array of 28 different ballots we had to track for the June primaries — four languages for seven political parties, most of which went straight to the recycling bin.

I had training today, and there weren’t any big surprises. The main changes I noticed were that Alameda County scans the ballots at the polling location, so you have to keep track of a machine about the size of a portable dishwasher in addition to the touch screen machine that’s apparently pretty common around the SF bay area. Each precinct has a judge whose sole job is the setup, teardown, and maintenance of the voting equipment. And, there’s only one printer to keep track of instead of Santa Clara County’s three. But, other than that everything was pretty much the same. There’s something to be said for consistency.

We were also a much smaller group than in the training sessions I had in Santa Clara. That made it easier to ensure that everyone got to work with the equipment, which I find to be the best way to learn how to perform all of the steps.

Now I just need the ROV to send out my official letter.








Follow

Get every new post delivered to your Inbox.