Gotta Love OS X

April 12th, 2002

OK, once again, I have to say that Mac OS X is a great step up from it's OPENSTEP roots, and I love doing development on this platform.

I have been working on a simple GUI query tool for PostgreSQL - with an eye towards making it as databse independent as possible. Lots of abstraction in the base classes, and then PostgreSQL-specific classes for the models. It's a good design, if I do say so myself. And the speed with which is goes together is incredible. You can leave all the basic initialization to the nib loading and instantiation and the just focus on the behavior in your model and controller classes.

Don't get me wrong, if you don't like Model-View-Controller (MVC) style coding or you don't understand how to create MVC designs, then I can really see that this design paradigm could be a pain in the neck. However, having said that, there aren't a lot of apps that need a GUI that aren't MVC, or couldn't be made in MVC easily.

While I've written a ton of Visual Basic code in my lifetime, I have to honestly say that their merging of the Controller and View objects just isn't what makes for really good, reusable code. Sure, you can hammer something out fast - drop a few buttons on a window - double click on the buttons, write code, and run it. But in the end, the View holds too much business information and that's never good as you try to scale things up.

Sure, you can use the COM objects to get the Models out of the code, and that's good. But you can't get the Controller out of the View in VB. And there's lots of reasons to have the Controller be the only disposable code you have. That's what I like about Mac OS X.

I guess that VB gets around this by the wealth of OCX controls that are reusable, but specific enough that they contain quite a bit of useful behavior. This is OK, and I used a ton of them in my day, but the idea of having a real Controller is just so nice and clean. It makes things so much easier to design.

I guess that's why the little database app went together so nicely. It's got all the functionality that I need and putting things together was the most demanding part and IB did the vast majority of that. Great tools for cool programming. Can't ask for anything more.

People really are funny

April 12th, 2002

I was sitting here thinking about the status of a project I'm working on and I had to giggle to myself a little. Now I've written in the past about the company that provides the basic framework/infrastructure and how it's not the most incredible piece of engineering I've ever seen, but today's got to be a new high (or low) point in the saga of this project.

We have been facing a real problem with stability that, in my opinion,
has been brought on by the lack of careful development design that Java seems to breed. Not that I've got anything against Java as a language, but whenever you have a language that tries to do so much for you, you run into folks that this this is some sort of magic Genie that will take care of a lot of other things as well.

But I suppose Garbage Collection is a good thing - if you understand the limits of technology. It's not perfect after all. Let's take the example of an event-driven system. A good design might be to have each event source capable of sending one event through the system, and buffering up the others in some sort of compressed queue, until the handlers of the event are done with the one you've already sent. Then there's the magic Genie model that says "Hey, let's generate a new Event Object for each event and pass them on as they are generated." This is the incredibly bad design that Java so easily allows that I'm talking about.

On the surface, both seem the same. Both handle all events - one buffers them at the source, the other somewhere in the event processing loop. But the enormous difference is that the first one allows for such ideas as "too busy" while the other simply allows for excessive memory usage that will lead to crashes.

If you don't exercise some level of common sense in the insertion of events into the stream, you can't be upset when the stream can't keep up with the flow of events - and the Garbase Collector can't keep up with disposing of all these created objects. Yes, it should in a perfect world, but this isn't, so it can't. With one Keyboard Event Object (say) that you reuse again and again for the different events, you don't have a problem with excessive memory usage. Also, in the Keyboard Event Filler you can say "OK, I've got 50 keyboard events in my buffer - that's enough, throw the rest out." or something similar. In any case, you can easily control the number of events since you're controlling them at the source. It's this kind of systems thinking that I'm seeing so completly absent in so many Java development projects these days.

C, Obj-C, C++ - they all made it hard to allocate and free memory and objects so you were pretty darn careful about what you created, where you passed it around and who freed it. Yes, this lead to memory leaks and this, in turn, lead to memory profilers. But the problem of
over-generation of objects seems to lie clearly at the feet of Java as it makes it too easy to create without any knowledge or care about the consequences, and lifetimes of these created objects.

In some ways, in the hands of good developers, Java's Garbage Collection is a good thing. But it doesn't absolve you from thinking that it's not magic. And that's where you get into all the trouble. In this regard, it'd be better to write in a little more complex a language just to force all the developers to think before writing.

Life with sherman

April 4th, 2002

Life has been very, very busy for me these days - as evidenced by the time since my last journal entry. Lots of things have been happening and I have to say that most of them have been good, while still keeping things interesting with a curve here and there.

I'll try to hit the high points and not be too wordy along the way...

Work at The BANK is going well. Lots of work to do, which is nice. Keeping my skills sharp and putting more things in from of the traders. All this is good, and I can't complain about work at all.

The word amongst the consultants is that rates are being lowered which is interesting in that I got a non-trivial raise. I guess they are seeing that developers, in general, are getting less, but good ones are still worth paying more for. But of course that'd be my interpretation of it. 🙂

At home the machines are running well, but a few weeks ago I lost the 9GB boot drive on sparky which took a few days to get a replacement for. In the end, it was cheaper to get an 18GB replacement than to try and get an exact replacement. Funny how technology drives prices down then up again as the parts get more scarce.

I've also got my first Mac in a very long time - a 14" iBook. And by a long time I mean a decade. I did this because of Mac OS X and the Developer Tools that used to be thousands of dollars under NeXTSTEP and OPENSTEP - both of which I love and continue to have in my office. So I was quite taken with the new iBooks and got one. Excellent move. With my 802.11b wireless LAN in the house, the AirPort card works wonderfully, and it uses the wired 10/100-baseT when I'm sitting at my desk. Very nice. The tools are as nice as I could have imagined though I have to say that they could have made the administration a little easier with the startup scripts if they had gone with Irix's or RedHat's chkconfig system, but that's a minor point and they have a feature, just not as easy to configure and use.

While it has taken a little getting used to, specifically in terms of getting the tools I got used to on Linux/Solaris/NT to Mac OS X, I think I'm over the hump on getting up to speed on the Mac world again. Oh sure, there are a lot of little details I'm unsure of, but I'm productive and have about 90% of the things I need up on the iBook and that's more than good enough to do all I need to do.

I'm impressed with the improvements in Project Builder since OPENSTEP, and am glad that they didn't mess too much with Interface Builder. Setting up the user preferences on this guy could have been a lot easier, but it's all a certain mind-set. Where to change the size of the icons on the Desktop? Don't look for it under the Desktop Preferences, you need to select an item and then select the view preferences for that item and it'll change it for all Desktop items. Not obvious, but there's a certain logic to it I'll agree. It's just getting into that logic that's hard.

The DVD/CD-RW on the iBook is very interesting, but I'm a little surprised that while the DVD is paused the iBook can't go to sleep. If you stop the DVD playback then it'll sleep and the play will resume where you left off. Hmmm... still a few bugs in the system, but they'll work them out or I'll work around them. Either way, it's still a nice little box.

My next box will be a new step up - gotta get a dual-Athlon XP with gobs of memory and a very nice video card with OpenGL acceleration. This will be my preferred desktop workstation in the office and I figure that I'll get it nearer to the Fall.

For now, I have to say that working with sherman is a whole lotta fun!

Will they never learn?

December 27th, 2001

OK... I'm not trying to be unreasonable here, but I have to get at least a little of this off my chest. I'm working at UBS O'Connor, and these guys are a reasonably good lot - certainly the group I'm working in right now. But they have selected a vendor package that is maintained by the worst people I can imagine. Really... the worst.

If they were even slightly worse, it'd be OK, because then the management would see that their stuff is only marginally better than in-house works, and the cost and pains associated with it are far outweighing the benefits of the vendor's package. It's really incredible.

Without getting myself into a slander lawsuit, I'll just say this group is a vendor... a very bad one, but just a vendor. Their software is marginally better than nothing, but not much better than nothing. It's got a few nice features, but it's got a ton of problems, so in the end, I wish I didn't have to deal with it, or with them. But I do.

So... today I received a license file from my contact at the vendor. I was told to put it in place of the existing one, as it will expire at the beginning of the new year. What they didn't tell me was that it was keyed to a specific version of the software - the version that we now have in Q/A, but haven't yet put into production. This means that when I put the license file into production things started crashing. Luckily, I keep excellent notes and version control everything so that we got it back up and running within minutes. But the point remains that I don't have a license file for the new year, and I wish after all these months of dealings with these folks, they'd spend the extra 30 sec. to include in their email that this version only works with the newest version of their software and that there's another version coming for the older one still in production.

I treat bug reports this way... I make sure there is a repeatable problem and narrow it down for them. Even including code snips that reproduce the problem in their libraries as cleanly as possible. Yet I've still never seen page one of documentation on their system, I have to look at the compiled classes in the jars for any indication of the capabilities of the system... and in general, I'm getting absolutely crummy customer service.

Man that makes me mad... for all that O'Connor is spending on these guys and their software, you'd think that the least they could do is to give a little documentation... a little description of this and that... limitations in license files... But I guess they don't think that's important where these guys come from.

Worry and Estimations

September 17th, 2001

The World Trade Center was hit. The Pentagon was hit. As a nation, there is excessive pain, cost, and grief. Things aren't going to be better in the next couple of days, weeks, or even months. Yet there's every reason not to be fatalistic about these events. That is, I suppose, only a single point of view.

I work in the financial industry, and there are a lot of people that are really wrapped up in the theory of the market. To them, this is all a reason to sell... into an economic depression. But they are depressed about this. I find that more than a little funny.

A Trader sees what he thinks he must do and then is depressed about it. He doesn't even see that he has options - choices that are open to him. And that those choices would allow him to feel better about himself, and the work that he does. All he sees is that the theory - which he places so much faith in, tells him how to act. I feel really sorry for folks that don't realize that they are prisoners of their own choices. We are all free creatures... free to do what we want, when we want, accepting the consequences of those actions - good or bad.

Maybe the depression is focused at the faith in the market theory... if they didn't place as much faith in the theory, then they wouldn't be forced to do what they thought they were being told to do. It's interesting that people who may not think of themselves as faith-based tie themselves to their beliefs as much as fanatical religious types.

People are funny...

People are Funny

September 10th, 2001

I have worked with all kids of people... I've even been all kinds of people over my 39 yrs. of life, so I think I'm pretty well exposed to my middle-class group of humanoids. Yet once and a while you meet someone that represents such a skew in your data, that you have to stop and study this person more.

I have worked with a person we'll call Steve (that's not his real name) for about two months now. He has shown himself to be a pretty reasonable developer. He seems to know the code he's delivering, and while his vision very rarely extends outside the box, he seems to be adequate for the job. Then came today.

Today, Steve came to my office to see that his code was running terribly slow. First off, he didn't believe me that it was, and in the all-too-often stance taken by some developers "it works fine for me", he had to see it. So I showed him. As it turned out, they weren't using very similar data for their tests, so that there was every reason why the results would be significantly different. That wasn't enough, oh no...

Steve then proceeded to sit in my office for the next several hours learning absolutely nothing because the tools he was using weren't going to tell him what his problem was. I tried to, but had he listened to me, he wouldn't have been here in the first place, so it wasn't likely that he was going to take my advice at this juncture.

Oh... and did I say that Steve has a serious personal grooming problem? Yup... probably hasn't brushed his teeth in... Oh... let's call it six months and be safely conservative.

So I'm trying to work with a guy that doesn't really listen to me - though I've been right every time, doesn't realize when he's got to go back and fix something, and carries with him an odor that almost makes my eyes water.

So today hasn't been a great day of personal highlights...

What I want out of this is at least a glimmer of a sense that he takes back the realization that there is a problem... that it's not us... and that they have the wrong data model. With that, and enough time, I'm guessing that they will figure it out. But that's my hopes... life rarely lives up to our hopes for it.

Hardware, Costs and Companies

August 24th, 2001

Here's an interesting thing I've run into again at work. No matter where I come across it I'm amazed. Here's the story:

We have a Java process that is large - both in memory usage and in the processor speed that's required to get the job done on time. It's a real-time datafeed system so if it's not fast enough, they simply won't use it and will dub the project a failure. So we need speed and we need a good bit of memory.

The benchmark is that if this process is run on a good WinNT machine (900MHz+ and 512MB+) then the machine is fully loaded, but it runs the app and things are reasonably good. Yet they don't want to load each of the user's machines, so they want a thinner client.

So I try to run the middle tier of this application on a Sun Ultra 2 with a 300MHz UltraSPARC and 256MB RAM. This is a good test and it yields bad results. The report that loaded in about 10 sec. now takes in excess of an hour and the trashing on the Ultra 2 shows that the 256MB is too small and the 300MHz too slow. So now the question is What to try next?

Here comes the problem...

You can buy a Sun Blade 1000 with a 750MHz UltraSPARC processor and 2GB of RAM for about $14,000.00. You can get a dual Athlon 1.2GHz with 1GB RAM for $2,200.00 and run Linux/Java 1.3.1 on it. There's no comparison in the price/performance - Intel hardware wins by a wide margin. Yet you don't want to run NT on it - you need something like Linux/OpenBSD or even Solaris x86. Yet none of those combinations are allowed. Only Windows NT on Intel hardware or Sun hardware and Solaris.

So the problem becomes how do you justify the cost within these arbitrary rules? Well... it's hard. Most of the time you just give up and the users have to suffer. For no good reason other than ignorance. Linux can be made just as secure as Solaris... it can be just as reliable - given solid, reliable hardware... and yet it's banned more than it's used. I'm constantly amazed.


Other than the hardware issue, things are going well at work. We're making progress on the app, and if this middle tier proves itself, it'll be a very nice tool indeed. I enjoy the server-side processes because that means that I don't have to deal with the GUI stuff, but that also means that my ability to interact with the user is only within the context of what the existing infrastructure will allow. Good and bad...

Anniversary!

August 10th, 2001

Well... another year rolls around and it's my wedding anniversary. Nice.

Last evening I looked for the Solaris 7 disks on eBay and again this morning. It seems as though I'm never going to get my wonderful set of disks back and rather then get the set I originally got for $18.00 that included both the SPARC and Intel versions of Solaris 7, I'm going to have to pay on the order of $25.00 plus shipping to get a SPARC-only set of the disks.

Let this be a lesson to you, Bob... never, never, never trust someone else with things that are near and dear to you. I feel like a fool for having left the disks there. I should have kept them with me as he was never going to be doing an install anyway.

Oh well... I supposed I've had more expensive mistakes in my life... this one will only set me back the cost of a good dinner with the family. I've had worse, I suppose.


Work is thankfully quiet and that's good. In these quiet times I'm going through the code and cleaning it up, adding accessor methods and such to just clean up the code and make it just a little more robust.

One of the problems with doing this is that you really can't change anything and that means you need to be very careful about what you change and be sure to make sure all references are checked. The upside is that after you've done this it's a cleaner design and you've probably caught a few mistakes in the process.

The big downside is that you end up burned out after a few hours. Since you aren't really doing anything new it's not like there's something to look forward to. It's a do no wrong mode and that's hard to keep up after a few hours. So I have to take breaks and pace myself. It's important work to do, but it's not the kind of thing you can keep at for eight hours straight...


FLASH! - Joel called and the Solaris 7 disks have been found and he'll be bringing them to the City Monday. Yes! Good news.

Maybe Going Palomino?

August 8th, 2001

Well... I've found a place that will basically build my system from the individual components that I want. It's not going to be as sexy as the Blackbird, but it will be as nice on the inside... For about $2500 I can get a dual Palomino 1.2GHz machine with all the memory and drive space I can ever need. Also it'd have dual NICs to make it easier to bridge my two networks, and a CD-RW for those times when I want to burn CDs.

Now I'm back to wondering when...


I'm supposed to be getting a Sun box for work soon. I think it turns out that a guy left, and it was his box, but now that he's gone, it's free to be re-used. So I put my name in and why I need it and we'll see. I think it'll help a lot in developing/debugging the middle-tier that's coming from the InfoReach guys this fall. I just hope things work out - both with the box and with the code.


I have been searching and fiddling around on the net today because we're just so darn good! Really, the app is running well, we have to wait on others to do things for our next steps, and so all's quiet. Nice, but it can get to be a little too quite as well...

So I've done a little bit of looking, first at the system that I was looking at. I read up some more on the motherboard, and it looks very nice. This might actually be a really good system to get! I'm more impressed with the box and my ability to configure it the more I think about it. The other thing I was thinking about was the Sun box that I'm hopefully going to get in the near future. It seems as though someone else has put in a request for it, but I thought it was tagged for me... Oh well... we'll have to see how things work out.

Speaking of Sun boxes, I've tried to track down my Solaris 7 disks with Joel... I'm almost certain that I left them at his house. Let this be a lesson to me... never leave disks lying around. You never know when you're going to need them.

Anyway... when I get the Sun box the conventional wisdom is to get the machine name, any configuration information off it, and then rebuild it from scratch. Then, install what I need and properly put it back into the NIS network. Nothing that hard, but it's something that needs to be done. What I'm thinking about is GNOME 1.4 and Sawfish window manager. It'd be really nice to be able to put GNOME 1.4 on this new box and let Ximian's Red Carpet take care of keeping things up to date. The Ximian folks say that it's coming, but have no date as to when it'll be ready. The alternative is to get the sources and build them with the tools from SunFreeware and go that route.

If I go the manual build route then I'm going to have to get Sawfish as well... Also, if I want to build anything with KDE, I'll need to get that. There are a lot of details that need to be thought of, and Ximian's installer was nice in that it took care of the GNOME and Sawfish part. All you had to do from there was deal with KDE and any other tools you wanted - gEdit, etc. that weren't included in Ximian GNOME.

So... I'll first have to get the Solaris 7 CDs from Joel, then see if I actually get the Sun box, then worry about rebuilding it from the disks, then getting the essentials from SunFreeware, and then getting GNOME from either Ximian or the sources. There's a lot of work there, and it's going to take time to work through it all. No rush on the GNOME issue today.

Shopping Once Again

August 7th, 2001

Now that my believed Blackbird is no longer available from the folks at SpindleTop, I have to find another machine that's right up there for my next acquisition. I'm really interested in getting a new Linux box, but there's all that pesky hardware compatibility to worry about and the cost of getting a
Penguin Computing workstation is just too much for what you get. I'm not happy about the Blackbird, but I really don't have a lot of places to turn. I could try to go it along and essentially build my own box from the components of the Blackbird, but then I'm dealing with a lot of issues there that I haven't had to deal with in a long time and I'm not sure I want to get into motherboards once again.

So I'll probably scan eBay and see if anything interesting comes up.