The
Ultimate
Business Machine

Technology, business
and innovation.

And, not least, about
the Mac.

Weblog Archive Cutedge

by: Bernard Teo






Latest Joy of Tech!

Joy of Tech ... from Geek Culture



Creative Commons License

Copyright © 2003-2012
Bernard Teo
Some Rights Reserved.

The Ultimate Business Machine - Archives

List of Categories : Commentary * Database * Singapore * Technology * Travel *

Wed 06 Dec 2006

Frameworks

Category : Technology/Maven0dot3dot1.txt

This is embarrassing. I just realised when, I was loading up my gleaming new white MacBook, that Maven wouldn't run on any Mac other the one I had developed it on.

I screwed up the path settings for the database connectivity frameworks that I embed into Maven, so the application couldn't find them when it's loaded on another Mac. That's why Maven wouldn't run. But I've fixed it now in version 0.3.1 beta.

In this version, I've fixed some more bugs, and you can enter, modify, add or delete database records on any of the three currently supported databases - SQLite3, PostgreSQL 8.1 and MySQL5. I've made sure to test all three databases by now.

I'm now working on the ability to alter any of the table structures on any of these databases, e.g., to add or delete fields, indices, and constraints. To make all three databases work like they're the same to a Mac user, even though they're all quite different from each other in myriad ways - that's going to be the challenge.

A word about frameworks. They're like DLLs on the PC. They add functionality to an application and they can be shared by applications, e.g., Luca and Maven share the use of the same database connectivity frameworks, in which case they're normally stored in a common location, like/Library/Frameworks. But what if you want to delete Luca and Maven from your system and don't know enough to go find the associated frameworks in /Library and delete them, too? Then they live on as junk in our systems - our very own form of DLL Hell.

There's an alternate approach - embed the frameworks inside the application so they come in as one package and they die together when you later drag the application to the trash.

The picture below shows where I've embedded the connectivity frameworks - you can see them when you Control-click on Maven or Luca and do a "Show Package Contents" :

I love the thoughtfulness of this particular design - it hides the complexities from the end user so everything comes in and out as one convenient whole.

But the thoughtfulness didn't just end there, otherwise the PC geeks would have just another example of how Mac users are such wimps. The problem for a developer is, it's a pain to move each of these frameworks into the each of the applications that use them, each and every time you need to make a change to any of the pieces, just so you can test them together.

So, while developing applications, you would prefer a shared model whereby once you've made a bug fix to a framework, all the applications that use it will automatically be able to access its latest state without your having to manually move it into each application. And that's what Xcode allows the developer to do. We get the best of both world - a convenient shared library approach while in development, and it smoothly dovetails to build an integrated package out of all these little pieces that a Mac user can then conveniently use.

Maybe it's a little hard to explain this, but when I discovered how to do this, I thought, this is so neat, because I don't have to keep so many things in my head. I don't have time for the Microsoft measure of intelligence, like how many manholes are there in New York or how to move Mount Fuji, because I find, first of all, that that intelligence is without context. But I love these ideas, like frameworks on the Mac, because these are ideas that have been put together by people who understood the context in which the tools had been used and who then went on and really made them work better. That's why we can fall in love with these things.

Posted at 6:44PM UTC | permalink


Mac@Work
Put your Mac to Work

Sivasothi.com? Now how would you do something like that?

Weblogs. Download and start a weblog of your own.

A Mac Business Toolbox
A survey of the possibilities

A Business Scenario
How we could use Macs in businesses

VPN Enabler for Mavericks

MailServe for Mavericks

DNS Enabler for Mavericks

DNS Agent for Mavericks

WebMon for Mavericks

Luca for Mavericks

Liya for Mountain Lion & Mavericks

Postfix Enabler for Tiger and Panther

Sendmail Enabler for Jaguar

Services running on this server, a Mac Mini running Mac OS X 10.9.2 Mavericks:

  • Apache 2 Web Server
  • Postfix Mail Server
  • Dovecot IMAP Server
  • Fetchmail
  • SpamBayes Spam Filter
  • Procmail
  • BIND DNS Server
  • DNS Agent
  • WebDAV Server
  • VPN Server
  • PHP-based weblog
  • MySQL database
  • PostgreSQL database

all set up using MailServe, WebMon, DNS Enabler, DNS Agent, VPN Enabler, Liya and our SQL installers, all on Mavericks.