Sticking With PostgreSQL and PHP from Marc – For Now

November 12th, 2008

php.jpg

I was doing a lot of thinking about the Marc Liyanage builds of PHP and PostgreSQL and looking for alternatives - specifically MySQL as it's supported by Apple. Seems like a reasonable alternative if that's what I want to do, but I'm convinced now, more than before, that I can wait on Marc and see if he bows out or decides to keep things rolling, and here's the reason: Building PostgreSQL is easy. In fact, I can get it from another site with an OS X Installer package. That's not the problem. PHP is.

Marc packages a lot of third-party libraries with his PHP, and those are a lot more valuable to me than the most current database support. The version of PostgreSQL I have is fine. It works great. I don't need more. PHP is fine. If I find that I need a new database, then I'll look at MySQL as well and see how things shape up. But until I need a new database, I'm going to leave it as-is for now.

The trick will be building PHP from scratch with all the add-ins he's got. There is a build script on his support forum, and I could certainly start with that, and will, if I have to, but for now, I'm one minor release point behind Apple, and that's not a big enough reason to do it all myself.

I know I can get another PostgreSQL. I can get MySQL for sure. I can get and build PHP based on his script. That's a plan, if I need it. There's no reason to build a database from scratch, and there's no great need to have a different one now. We'll just sit tight and see how things play out in the months to come.

Pixelmator Moves Forward with 1.3

November 12th, 2008

A while back, there was a flourish of new image editing apps based on CoreImage - I picked Acorn from FlyingMeat but another was Pixelmator. I didn't get it as Acorn did all I needed, but it was interesting to see all the apps come out about the same time (there were a few others of lesser note), with basically the same capabilities just a different spin on the UI.

Well, I have to say, Pixelmator is making me think twice about that. It's more like a Photoshop app with the toolbars, but it's based on the same capabilities as Acorn... it's just a matter of which you prefer.

I'll probably still stick with Acorn, but I'm going to keep an eye on Pixelmator as it's moving in the right direction and may have to give it a good once-over to see if it's a better fit for me.

The Panic Crew Surprises Me with Coda 1.6!

November 12th, 2008

Coda.jpg

I was blown away this morning to see that Coda 1.6 was released with a new plug-in system as well as a smart spell checker (it checks the code, not your words), and a few other new things, as well as a ton of bug fixes. It's all in the release notes.

Again, they stun me. I've always liked Coda, but it's the fact that they are really moving forward with it so consistently that impresses me. It'll take me a few days to get out from under what I'm doing and give it a good spin, but I'm really impressed. Nice job!

iChm 1.4 is Out!

November 12th, 2008

iChm.jpg

There are a few times that there's no way around it... you are given a Windows Help file and you have to read it. I've had to do this several times, and while I like keeping documentation on my Mac, it's a pain to try and read these files on a Mac without something like iChm.

It's clean, it works, and it's not a nasty hack. Other than that, it has the limitations of the Windows Help file, which aren't as useful as the help system on the Mac, but that's just a fact of life.

If you have Windows Help files, get this and thank the authors for making you life less miserable.

Getting a Little Concerned About PHP and PostgreSQL Support

November 11th, 2008

PostgreSQL.jpg

I've been using PHP and PostgreSQL for a long time. I'm talking like in excess of 7 years. I love the database and the language, I like the fact that they work well together, and apart. I've been using them for a very long time and very happy about it. Lately, however, I've gotten a little concerned about the continuation of PHP and PostgreSQL on Mac OS X. Specifically, Marc Liyanage has been providing wonderful packages for PHP and PostgreSQL that work wonderfully well together. But it seems he hasn't released an update in a very long time.

In fact, Apple's PHP version is more up to date, and that's saying something.

Apple's PHP has support for MySQL, but nothing for PostgreSQL, so I can't really use that. If I switch to MySQL I can use Apple's stuff and the packages from MySQL which reportedly are pretty decent, but again, I'm learning a new database and that's not a horrible thing, but it's not something I really want to do, either.

If I wanted to build these myself, then I'd have to build PostgreSQL... use that and the Apache2 on Mac OS X to build PHP, and then I'd be OK. But that puts me in the middle of the build process, and honestly, I'd rather have something that I can update and not have to mess with. Sure, it may sound like I'm lazy, but if I go to the hassle of doing this, I might as well put Marc out of business and start updating the builds myself.

Maintaining a build of PHP and another of PostgreSQL might be OK, but there's a lot of people already doing one of these - it's the combination that I'm looking for. With linux, I get it all for free, but that's because they expect you to want that as an option. It'd be nice to see Apple just throw in the PostgreSQL support into PHP and then point to an installer like they do with MySQL.

But I'm worried this is not going to happen. Maybe I need to just email him and ask him straight away if he's stopped doing the builds. At least then I can make a decision to go to MySQL or try to go the route of the builds. Certainly, if I do the latter, and Marc is out of the game, then I'll have his build scripts to work off of, which isn't horrible.

Lots to think about... unfortunately, nothing really looks all that appealing. Probably the path of least resistance is to get MySQL on my Macs and then use the Apple PHP and be done with it. This way, I don't have to worry about continued support - they seem to have made a choice, and will most likely stick with it.

UPDATE: while I was finishing this up I decided to see if PostgreSQL had a pre-built package for Mac OS X like MySQL does. Turns out, they do. With this, I can be up to date on PostgreSQL without having to depend on Marc. I only need to find a way to get PHP support based on this build. Nice to know.

I ended up sending him messages on his support BB... one for PostgreSQL and another for PHP. We'll see if he replies, or if someone else replies. I can see building PHP like Marc does, but how difficult that might be I do not know.

Updated to gfortran from Mac HPC Site (August 2008)

November 11th, 2008

fortran.jpg

I noticed that there was a new version of gfortran available from the Mac HPC site, though it has probably been available for a while now. I was looking at the Intel FORTRAN compilers and at $600 each, you have to have something significant to use it on in my book. There's nothing wrong with the gfortran compiler, and while I'm not solving weather problems or simulating nuclear explosions, it's still cranking out answers for me that took machines a few years ago a long time to answer. That's not bad.

I still remember very fondly the days in grad school writing FORTRAN code for the Cyber 205, Gould NP1, and the Sun 3/60... fun days indeed.

Figured Out a Work-Around for the VantagePoint Second Y Axis Bug

November 10th, 2008

comboGraph.png

I've been wrestling with a VantagePoint bug concerning the placement of Variables on the secondary Y axis, and this morning I got another email from Gordon with an example application that showed the secondary Y axis working perfectly. It took me a little bit to figure out that Gordon had put in the setLicense() call into the code, as I put mine in at another place and his trumped mine and so nothing worked, but that was a "Duh!" moment that was easy enough to figure out.

No, the problem was that on a simple graph, like Gordon's example, where the graph was all set up and ready to go before the first call to unlock() on the graph, didn't show the problem. When I looked at my code, there's all kinds of lock() and unlock() calls, and in general, the construction is far more dynamic - by design.

I was playing around with a lot of things and then came across this little nugget that was the beginning of the end for the problem. When I did the initial setting of the Variables on to the secondary Y axis, the code looked pretty familiar:

  for (int i = 0; i < cols.length; ++i) {
    getGraph().getVariableAttributes(cols[i])
        .setOption(VariableAttributes.voiSecondary, true);
  }

As you'd expect, this runs through the array of int values for the column numbers and sets those that need to be set. Pretty simple. Or so I thought.

When I did this I found that setting cols[2] actually also set cols[0] and if I cleared out cols[0] it also cleared out cols[2]. It's like they were linked somehow. I verified this by logging the status of each getOption() call for each of the columns on the graph after each call to setOption(). I was stunned.

I also was unable to reproduce this in the example Gordon gave me. I wanted to be able to send him back something but it wasn't looking good. Then I got the idea that maybe this was an order of operation issue, like some of the others have been with VantagePoint. Basically, for showing points and labels, it seems there's a necessary order to respect. This isn't required when you build the graph atomically, like Gordon's example, but it is in my code.

So I started messing with the order.

The first thing I did was to move the setting of the secondary Y axis to after the visibility of the points and labels. Immediately, it worked. Wow. That was fast. There wasn't much else to do but to document the heck out of the placement of the code, and then write it up to Gordon. In the end, I'm not sure if he's going to write back with requests for more data. If he does, I'll certainly try to supply it, but it's going to be tough. Simple is not where this guy shows up.

But it's nice to have it working as it's supposed to:

Fixed Second Y Axis

In a Good Organization, Communication is the Key

November 10th, 2008

cubeLifeView.gif

This morning I walked in to find that over the weekend about a dozen of my machines around the globe had been rebooted. Normally, this is OK because the Unix Engineers tell me this and I get online on Sunday evening and fix things up so that everything is ready to go in the morning. But because they didn't tell me, I had no idea, and was playing catch-up for a few hours this morning to get things up and going.

Now I realize that this isn't the end of the world. It impacted a few users for an hour tops, but the idea is that the preventative medicine here was a 10-sec email. That's it. When the effort to make things "good" is that little, I'd think it's worth doing. Keep the lines of communication open. Make sure people understand what's happening. That's all I'm asking for.

Well... this time it was more than they did. I was very disappointed, but things got going. It's just that I don't feel the need to keep them up to date of my changes, if they aren't going to keep up their end. It's degenerating into an every man for himself environment and that never works out well.

Apple’s Amazing Customer Service Blows Me Away

November 10th, 2008

iMac-G5-20.jpg

I've been cleaning up my office - OK, more than 'cleaning', I've been gutting it and dropping about five computers (Sun, SGI, NeXT, HP, and Canon) and reorganizing the entire office to simplify the office and clean all the wiring and power distribution I have. It's taken me several weekends, and it's required me to throw away computers that I've had longer than I've had kids. It's been an emotional journey.

Several months ago, my iMac G5 died and the cats at the Genius Bar in OakBrook said that it would be $900 to replace the mainboard. Yikes! That's nearly the cost of a new Intel iMac. So I got the Intel iMac and put it into service. I didn't get rid of the iMac G5 because I really wanted to get it working, I just didn't know what it'd take to get it going.

Well, in the cleanup, it was one machine that I just could not part with. I think it's the emotional attachment to the first iMac I bought myself. It was a G5, after all! That was a smoking processor! So I kept it. Well... this weekend, I decided to try and see if I could get to the bottom of the problem. All my Google searches said "Mainboard replacement", and my tests showed that I had to do the same. No way around it.

So I realized that it was worth $900 to me, and I went back to the OakBrook Genius Bar and said the story of my iMac. It boots, but then locks up. The gal took it and looked at it behind the bar (it was very crowded) and after a little bit came back to me and said "Yeah, it looks like the mainboard, and it's out of warranty." This, I knew. But I was ready. "But we're going to fix it for you for free."

What!?

Free?!

Yes, free. She took down a little more information from me and went to write up the ticket. It was going to take about 5 days to get the board and replace it. I told Liza about the news and she was blown away for about half a second. "Bob", she said, "You bought a MacBook Pro for your Mom here, my MacBook Air, the three Kids' MacBooks, your iMac... they're going to throw you a bone because it's good advertising."

OK, I had to agree, she's right. After all I've spent in that store, the cost of the mainboard is really nothing to them, but to me, it's incredible customer service. I'll be telling this story for a long time to come - and buying Apple computers for even longer.

So in about a week I'll be able to go back and get my new iMac G5 and put it in my new office and have it back up and running. That's just the most incredible news I've had in weeks. I'm so very glad I didn't ditch it in the clean-up. This is going to be great.

The Problem With Agreeing to Help Another Project

November 7th, 2008

Detective.jpg

I've been suckered into helping a non-developer pretend to be a developer and write this critical piece of code for trade processing. It's a bad idea from the start, but I knew the probability of him getting it right from the start, without any help, was so near to zero as to be indistinguishable from zero. Some may think me cruel, I think of it as honest assessment. This guy is a good natured, decent guy, but has no formal training in developing at all. Everything he's learned is from hacking around on the job. While that's nice, it's no basis for making a critical component. It just isn't.

So I agreed to help. And help I have. I've been sucked into cleaning up the code many times - each one because he's gone off where we left off and started to add in a new batch of functionality. Lots of copy-n-paste, but not even getting a clear and concise set of requirements from the functional stand-point. What's supposed to happen on these inputs? What about these? Some he knows, and some he doesn't. So I have to help there too.

But today it was a new dimension in this as I got called into his manager's office who clearly didn't know I'd helped this guy to the level that I have. To be honest, the code it 80% mine, and 10% the guy before me, and 10% his. He really doesn't know what's going on, and it's not because he's dumb, it's because he didn't code it and didn't spend any time figuring out what the code is doing.

So we're in his manager's office and he's saying things like "We developed this." Hold on there, Professor... Let's be careful about the use of the pronoun "we" here... I wrote a bunch of it, based on his somewhat dodgey specs. If there's an issue about what it should be doing talk to him - if it's about how it's getting done, then that's me. But this manager is not known for his precise language. He's considered somewhat of a micromanaging developer-wannabe, and as such he's throwing around "we" way too much for my taste.

But he gets mad at me when I say "Watch the 'we', I wasn't in it at this point" to which he gets angry and says "It's our code - that means we built it." Yikes! That's a leap I'm not willing to take at this point in time. So we go back and forth. Finally, we get to the point where he's telling me the specs that I didn't get from the guy I was helping. I put them into the code in all of 15 mins and the tests work wonderfully. Surprise.

It's this getting suckered into this project and then yelled at for not making it perfectly without any specs that makes me a little leery of helping these clowns ever again. After all, it's not my job if this guy can't deliver anything that works. It's his. At some point, if this place doesn't start to turn around, it'll be every man for himself, and at that point I'll be fine, but he's going to be looking at the door.