Friday, August 17, 2007

Tips for migrating a MySQL database to Derby/Java DB

A more and more commonly asked question on the Derby user list is "how do I best migrate my database from MySQL to Derby".

A very useful way to do this is through DDLUtils, a very nice utility that lets you export a database schema from one database and create it in another. Here is the MySQL page from DDLUtils.

But I also thought I'd share what looked like a very useful email from one person who did it. Note the interesting tips about non-standard JDBC that worked in MySQL but which Derby did not accept.




>If you don't mind - what were your top three pains when moving from
>MySQL to Derby?

Glad to, if it will be of any interest, although the problems were
probably a result of our* own inexperience and naivity.

1. We used DdlUtils to do the migration, did the conversion form
MySQL to xml ok, but then encountered errors on conversion to Derby.
These threw us initially because they related to primary keys not
being unique, but eventually we realized that this was because
MediumInt is only supported in MySQL and the conversion changed it to
a Small integer. I guess we should have inspected the xml schema more
carefully. I had consulted the page:

http://db.apache.org/ddlutils/databases/mysql.html

And my one suggestion here is that the conversion table on that page
should include the recasting of mediumint - presumably an oversight.

2. The other problems arose at runtime after apparent successful
conversion, and also arose from the non-standard nature of MySQL.
There were three aspects of the java code of my app that Derby took
exception to. One was a JDBC ResultSet method (first()) I had used in
a hack to check for empty tables. It turned out Derby didn't like
this and made me use some JDBC2 method for scrolling the table. It
also wouldn't allow a finally{} clause for closing a connection that
it already handled itself (easy enough to remove) and wouldn't allow
a faulty SQL query that MySQL had ignored (typo of GROUP instead of
ORDER - for the correction of which I thank it).

So the moral is perhaps that Derby is to MySQL as Java is to Perl -
it won't tolerate the sloppy habits you had become accustomed to. :-)
(Apologies to the Perl community)

An old neighbor ends up in Arbil, Iraq

A neighbor of mine (well, he recently moved to Virginia) has ended up doing microfinance consulting with a bank in Arbil, Iraq. He's been sending us amazing missives about his life in the compound. They're in MS Word format, and I'm trying to convince him to turn it into a blog (maybe he doesn't have good enough Internet access for that).

Anyway, I thought I'd share his latest note.


Friday 1 PM

Hi everyone,

We work Sunday through Thursday so today is my day off and I slept in. It is approximately 112 degrees outside. I wanted to address the security issue. I’m getting some inquiries and people are wondering if I am in harm’s way.

Search the internet for a good map of Iraq and look at the top of the country. Kurdistan is sometimes confused with the "northern provinces" and the media continues to not distinguish between ethnic Kurdistan and the northern provinces. Mosul is violent and is up north, yes, but way east over near the Syrian border. Kirkuk is dangerous and there are lots of "incidence" down there and that is why we never entered the city. Even though the micro finance bank that I am consulting for operates there, no westerners in my parent organization enter the city. Everyone thinks that after the November election ( here ); Kirkuk will be ethnically cleansed and all the Arabs that Sadam moved in, will be kicked out…. or whatever. The Kurdish paramilitary is ready and they want the city back as well as the oil.

Anyway, Kurdistan is the three or four provinces that form a little icecap across the top of Iraq and border Turkey and Iran. The nasty genocide that occurred two days ago, for example, was outside of true Kurdistan but the area is obviously still populated by Kurds. The distinction is critical to understand, just because some bombs go off, and it is "up north" and some Kurds die, does not mean it is in Kurdistan. This may seem like trivia but I am depending on it. This city, Erbil, has a ten foot moat, or ditch, dug all the way around it to stop vehicles from entering cross terrain. The only way in is on the paved road, through multiple checkpoints guarded by the Kurd Army and the paramilitary. Voila ! No ethnic Arabs allowed. Period.

Nothing is perfect, and that is why I cannot leave the compound. It ( the compound ) is in a suburb of Erbil somewhere near the airport, and is occupied by a variation of religion that I am not sure of, I think there are Christians here or something. The suburb itself is surrounded by walls with watchtowers and guards. I live in a compound within the suburb that, as you already know, has blast walls, only one vehicle gate in and a different one out. The road to the gate has concrete diversions so an approaching car has to go really slow or it will crash. Everyone stops at the gate and the guards run a mirror under 360 degrees of the car, then the sniffer dog does it again. All supervised by Triple Canopy staff ( Google “Triple Canopy” and you can see the level of security that is provided to westerners ) No bombs allowed ! Worst case scenario is that somehow a person gets in past the gate and starts shooting up the place. They would last about one second. There are literally hundreds of armed people here including heavy duty westerners ( South African mercenaries ), not just the Kurds. Or, if someone drove close enough to the suburb, they could touch off some mortar rounds, but that would be so inaccurate that I don't even think of it.

Sorry for all the details, but information can cause relaxation, and that is what I am trying to convey. After all, there were drive by shootings almost every night on the commute path I took through north Oakland when I came back from the bank in Fremont. One of our friends was held up twice on the foot path between the BART station and his house in North Berkeley. So “safe” is a relative term.

It's noon and I am leaving the house to get lunch. Tonight I am hoping to get a security guy and go out of the compound for dinner. If not, then I will stay here, locked up like a caged rat. There is a big citadel about a mile away ( in the suburb ) and it old and famous. Maybe I can include that in my adventure if and when I can arrange an outing.

Best Regards to all

How to upgrade a Derby/Java DB database

With the recent release of Derby 10.3, it's relevant to ask - what happens to the database you created with an older version when you upgrade Derby or Java DB?

Well, Derby is focused on ease of administration and embedded use, and this includes seriously painless upgrade.

There are two types of upgrade: soft upgrade and full upgrade.

With soft upgrade, you can use a new driver to work with a database created under a previous version, but older drivers will still be able to work with the database too -- the database itself is not upgraded to the newer version/format.

This is convenient if you want to just try things out, or if you have a mixed environment where some users are still using older versions of the driver.

The drawback of this approach is that if there are new features in the newer version that rely on a new database format or new system metadata, etc., then you can't take advantage of those new features. For example, Derby 10.3 has added features for security, SQL, and administration that won't work with an older database.

That is where full upgrade comes in.

You don't need to do anything crazy like export all your data, create a new database, and recreate your tables and load your data. All you have to do is set the "upgrade" property to "true" when you connect to the database.

There are two ways to do this. You can set it as a property directly in the URL, e.g
   "jdbc:derby:travel;upgrade=true"
or you can add it as a property when you get the connection, e.g.

String dbURL = "jdbc:derby:travel";
Properties connProps = new Properties();
connProps.put("upgrade", "true");
Connection conn = DriverManager.getConnection(dbURL, connProps);
One important caveat: if you have created a database with a non-GA version of Java DB you can not upgrade it. This is because there is no commitment to support upgrade from what is basically an experimental database. All this mean is, please don't deploy a production solution using Java DB with a beta version of Java DB.

Thursday, August 16, 2007

Larry Ellison: Open Source has no value in and of itself

From an interview with Larry Ellison:

Regarding future challenges, Ellison dismisses open source as a threat to Oracle.

"Open source is not something to be feared. Open source is something to be explained. Open source wins not because it's open and not because it's free. Open source wins only when it's better," he says.

To me this is another example of Oracle trying to address open source by dismissing it. Of course people only choose something because it is better. But Larry doesn't acknowledge that open source is inherently better because it is open and free.

When it is open, it allows for innovation. When it is open, it prevents you from getting locked into a single vendor. Both OEMs and customers trust it because it is not controlled by someone who may be a competitor either in business or politics. When it is free, it delivers significant price/performance benefits.

Larry goes on to say

the purchase price of software is only about 10 percent of the total cost of ownership of software. So even if the software is free, the most you can save is 10 percent off. Now the question is, what are your other costs of developing applications, of running applications on a daily basis, of dealing with problems when they occur? We think that Oracle is absolutely very competitive with open source

I think what Larry is saying here is that open source, if it is poor quality, gives you longer-term higher costs in terms of day-to-day maintenance. But I don't know if there is any data that shows that PostgreSQL or MySQL is not as stable or reliable as Oracle. And here again he is missing the value of open source: the community makes open source more reliable over time, because there are more eyeballs and more people making fixes. It's true for security, and it's true for quality.

My general feeling is, Larry is trying to pooh-pooh open source, because his customers are looking very closely at lower-cost and independent solutions. So Oracle's job is to dismiss and scare and keep their customers from taking open source databases seriously. But if I were Oracle, I'd be checking my rear-view mirror, because history has shown that open source goes where you never expect it would go: operating systems, applications servers, office suites, and, yes, enterprise databases.

Code For Freedom in India

Sun India is having an open source coding contest for university students across India called Code For Freedom - in honor of the freedom of open source and the freedom of India found 60 years ago.

From the site:

Sun Microsystems is happy to announce the Code For Freedom contest where students across India contribute to the technologies that are empowering the participation age. Participating in this contest will provide you with precious industry experience while still learning in college. And there is more. We in turn reward you for your valuable contribution in taking the first steps towards the open source movement.

For more information, see http://in.sun.com/communities/univ/codeforfreedom/

Happy 60th Independence Day for India



This week celebrates 60 years of independence for India. I have always, always been struck with the way that India obtained its independence. Here in America, we fought with gun and musket; in India, it was fought completely with non-violent means. As always, India is giving the world deep and profound teachings.

Many people complain about our jobs being taken to India. But I know for a fact that Indians have been a huge component of the technical revolution from the beginning. And I want to honor and thank all of the contributions from the great Indian community.

I also want to thank India for giving me personally a vast and deep ocean of wisdom from which I can draw. Great statements such as tat tvam asi ("Thou Art That") and chittam mantraha ("The mind is mantra") have been food for years of contemplation and practice.

And the Indian people - sweet, kind, patient, funny, hard-working, passionate, disciplined. I want to thank and honor all of my Indian friends and colleagues.

Happy Independence Day!

An Earth Without People -- an interview with Alan Weisman



A great interview with Alan Weisman, who has a book out which predicts what would happen if humans were to disappear tomorrow. I've always wondered what it would be like if/when nature takes over.

http://sciam.com/article.cfm?chanID=sa006&colID=1&articleID=2691D716-E7F2-99DF-38F54EF6075AAB4D&ec=b_cn

NetBeans 6 will be dual-licensed with GPLv2+Classpath and CDDL

This email from Bruno Souza, community manager for NetBeans, outlines the plans to provide an EA version of NetBeans 6 that will be dual-licensed with CDDL and GPL v2 with Classpath exception. Very cool!

For more information, see the FAQ.

Cool Stuff with Sun's Cool Threads T2000 and PostgreSQL














Thanks to Max for pointing this out. Not only is the price/performance significantly better ($26 vs $113) with the T2000/PostgreSQL vs HP/Oracle, but the T2000 delivers 1 1/2 times higher performance per watt. I love the DB licensing cost of $0 for PostgreSQL.

Wednesday, August 15, 2007

Roumen's Wiki Rant

Roumen hits the same frustration that I did about varying Wiki formats. Someone please save us all...

http://blogs.sun.com/roumen/entry/rant_about_wikis

Alex Bunardzic » Resource Oriented Architecture

Alex Bunardzic presents a series of blogs on the concept of Resource Oriented Architecture, or ROA. He is emphasizing the fact that a resource and its representation are two different things, and a model of web-based programming that embraces this.

http://jooto.com/blog/index.php/category/resource-oriented-architecture/

Tuesday, August 14, 2007

java.net Forums : Please stop promoting new frameworks ...

An interesting forum thread discussing the problems of too many frameworks and too much complexity . I really liked evickroy's comment about how easy it is to deploy Java WebStart apps. I wouldn't mind seeing more of that...

http://forums.java.net/jive/thread.jspa?messageID=230579&tstart=0#230579

DamnHandy : » Where VMWare Fusion Shines Over Parallels Desktop

One blogger's take on VMWare Fusion vs. Parallels. Fusion is looking pretty attractive...

http://www.damnhandy.com/2007/08/13/where-vmware-fusion-shines-over-parallels-desktop/

Tim Bray prognosticates and navel gazes

A great blog, particularly his post-script. Here's one smart techie with his thoughts on the future. Interesting comments on Erlang.

http://www.tbray.org/ongoing/When/200x/2007/08/13/Prognostication

The Secret Diary of Steve Jobs: My lunch with Fester

I am sooo glad this guy is still writing. This one is just a gem. Siooma!

http://fakesteve.blogspot.com/2007/08/my-lunch-with-fester.html

Monday, August 13, 2007

If you want to get scared, talk to scientists



I am a subscriber to Science News, and I always learn at least one new cool thing in each issue. The July 21 edition had an article where scientists have uncovered that England was separated from the rest of Europe by a single mega-flood when a huge lake from the melting ice of the last ice age burst its banks. Sorry, you have to be a subscriber to read this, but the New Scientist has a for-free article on this.

There are many examples of sudden massive geologic and ecological change like this. Another megaflood I learned about yesterday from my brother was the one from another ice-age lake bursting that carved out the Channeled Scablands in Washington. This flood came all the way from Montana.

Then there are the super-volcanos that cause mass extinctions and the comet and asteroid hits, including the one that eliminated dinosaurs.

Interesting, but so what, right?

Well, Pa was explaining what is happening with the Greenland Ice Sheet. This sheet is the last remnant of the last Ice Age, and in some areas is many miles deep. And it is melting very rapidly as the melting water lubricates the sheet where it grips the rock. Many of us know this, but what isn't talked about much (at least I couldn't find anything) is how quickly this could actually happen.

According to my father, it's possible that the Greenland Ice Sheet will literally slide off the rock like snow slides off a metal roof once it melts to a certain point, and that sea levels will rise 20 feet not in 100 or 500 years but in just a few years. Moving vast populations of our coastal cities 20 feet uphill in a matter of a few years: doesn't sound like fun.

It's uncomfortable hearing these things from a fairly cynical scientist. He also made me aware of methane hydrates and the methane cycle. Methane is actually a significantly more powerful greenhouse gas than carbon dioxide. And if the oceans get too warm, vast amounts of methane currently frozen up in methane hydrates may be released, increasing global warming and releasing more hydrates and and and...

In a great book called A Short History of Nearly Everything, I read that the situation where we have temperate zones and an ice sheet is a very very rare situation for Earth. It is much more common to have a very frozen planet (at one point it was completely frozen over) or a very hot planet with no ice. It would seem we are tipping a very wobbly seesaw over to a new point of stability, one which our race may not like very much.

Erlang, the next Smalltalk?

Some interesting comments on the future of Erlang. And take a look at the comments - Scala is a Java-based parallel language? I'm sure some of you know about Scala, but I know very little, and it's time to take a look

http://thanksforallthesnow.blogspot.com/2007/08/erlang-next-smalltalk.html

Nitin Borwankar: Data 2.0: How the Web disrupts our relational database world

Some high-level but insightful perspectives about the future of data in the ever-increasingly data-intensive world of the web.

http://future.gigaom.com/2007/08/10/data-20-how-the-web-disrupts-our-relational-database-world/

Data Visualization Doesn't Have To Be Boring

My bro sent me this link of an amazing palette of interesting, attractive, informational and just cool ways to visualize data.

http://www.smashingmagazine.com/2007/08/02/data-visualization-modern-approaches

Thursday, August 09, 2007

BoingBoing: Virgin America's virgin flight

More rave reviews for Virgin America's new planes. I think Sun has an office in New York, and I have family there. I'm sure I have to go :)

http://www.boingboing.net/2007/08/08/getting_high_with_ri.html

Erlang, the next Java?

I have been wondering, as a programmer, what is coming down the pike for programmers to build applications better suited to multi-core chips. Erlang looks like a possible winner. I wonder if Sun is taking a serious enough look at it?

http://www.cincomsmalltalk.com/userblogs/ralph/blogView?showComments=true&printTitle=Erlang,_the_next_Java&entry=3364027251

Derby 10.3 is an official release

The vote is in, and Derby 10.3 is now an official release. Keep your eyes out for the link on the Derby site.

http://www.nabble.com/-RESULT---VOTE--10.3.1.4-release-tf4239820.html

Academics Waking Up to Wikipedia

I'd like to see more of this: academics embracing Wiki-based knowledge bases. I know my Pa is considering a Wiki-based collaborative effort to work out some nasty details in microfossil classification.

http://opendotdotdot.blogspot.com/2007/08/academics-waking-up-to-wikipedia.html

What to Eat » Raw Milk or Raw Deal?

We do raw milk at home, and we love it. We can definitely tell the difference - it feels good going down. But Marion Mestle makes some good points here worth considering.

http://whattoeatbook.com/blog/raw-milk-or-raw-deal/

Wednesday, August 08, 2007

Hey, what happened to my auto-indent in NetBeans?

The last few days, I have been struggling while writing code in NetBeans, because auto-indent just disappeared. I asked for help on the nbusers list but didn't see an answer.

While walking my kid in the stroller this morning, I had a moment of illumination. When I came into work, I removed my userdir, and that fixed the problem. Magic!

Actually, removing your userdir seems to be the Magic Bullet for strange NetBeans behavior. NetBeans seems to be able to get its configuration repository mixed up from time to time, and then it starts having these little psychotic episodes like no longer indenting, or badging files that compile fine, and so on.

So, what is this "userdir" of which I speak? It's the "user directory" and it contains all the configuration environment for NetBeans for a given user. And where is this beast? Take a look at this FAQ for your answers (note that on a Mac the "About" page is not under "Help" but under the bold "NetBeans" menu on the far left).

Be aware that when you remove your userdir, you lose any configurations you have set up. You will have to re-register your app server, re-install any extra modules you installed, and so on. Perhaps there is a way to avoid this consequence, but I haven't spent the time to track it down.

Tuesday, August 07, 2007

Jonathan Schwartz's Weblog: Sun Enters the Commodity Silicon Business

This part I didn't know: the Niagara 2 design is fully available under the GPL open source license. And we're selling this chip to anyone who wants to buy it, including our competitors. Brash, bold, creative, passionate - that's Jonathan.

http://blogs.sun.com/jonathan/entry/sun_enters_the_commodity_silicon

Global-Warming Deniers: A Well-Funded Machine - Newsweek

I've always had my suspicions, but for Newsweek, about as mainstream as you can get, to document the concerted effort to sow the seeds of doubt around global warming is chilling (sic).

http://www.msnbc.msn.com/id/20122975/site/newsweek/

Earth2Tech : Sun’s Energy Efficient Chip

Sun's announcing our new Niagara chip, with huge power savings because it has 8 cores with 8 threads each on a single chip. People are sitting up and paying attention

http://earth2tech.com/2007/08/07/suns-energy-efficient-chip/

More details on JSON support in JAXB

This one is from Jakub Podlesak, the engineer responsible for implementing JSON support in Jersey.

http://blogs.sun.com/japod/entry/json_entity_providers_in_jersey

Using JAXB to generate XML and JSON from a single HTTP method

I just read this post from Paul Sandoz on the Jersey mailing list ( Jersey is the open source JAX-RS (JSR 311) Reference Implementation for building RESTful Web services.

They've been working on using JAXB to support both XML and JSON bindings.

Paul's recent checkin allows you to annotate a single method with JAXB annotations to support JSON and XML data formats as a response.

Which format is used depends upon the accept header of the HTTP request. If there is no accept header or it is set to *, application/* or application/xml then you get XML. If it's application/json, then you get JSON.

Here is an example from Paul's email:

@UriTemplate("/")
public class MyResource {
@HttpMethod
@ProduceMime({"application/xml", "application/json"})
public JAXBBean get() {
JAXBBean j = ...
return j;
}
}

Note that this is very in line with REST principles. The response is a representation of the state, and you can get different representations of that state for the same request, depending upon what the request asks for.

Pretty darn cool - great work, guys!

Monday, August 06, 2007

Open source study: Developer communities not enough for support

Matt Asay of CNet comments on a new study showing that developer communities do not provide sufficient support for production software. This ties into Sun's business model of shipping open source software for free and then charging for support.

http://blogs.cnet.com/8301-13505_1-9755134-16.html

Friday, August 03, 2007

Open Source at Microsoft

Wow

http://www.microsoft.com/opensource/default.mspx

H2 Database supports PostgreSQL ODBC driver

Now this is a very interesting move. H2 is riding on the coat-tails of PostgreSQL by supporting the PostgreSQL client/server protocol. Now they don't have to build their own ODBC driver, and get automatic PHP, Perl, TCL, etc. support through PG drivers.

http://www.theserverside.com/news/thread.tss?thread_id=46456

To niche or not to niche

James Governor quotes Anne Zelenka on the value of "niching" your blog. I like talking about just about everything, but I have to agree with my bro that posting lots of family stories and photos is going to drag down a "general reader" blog.

http://www.redmonk.com/jgovernor/2007/08/03/on-blogging-no-niche-required/

Roumen does Dilbert for NetBeans

Good ol' Roumen, having fun. He's added a Dilbert plugin for NB that displays todays Dilbert cartoon. I'm adding it to my NetBeans! :)

http://blogs.sun.com/roumen/entry/dilbert_plugin_for_netbeans

Ian Murdock and Marc Hamilton On Sun OS Strategy

Some very interesting observations about the future of operating systems, including some cool stuff about packaaging, commodity storage and 10GB Ethernet support integrated into the latest Sun chips.

http://www.itjungle.com/tug/tug080207-story01.html

Google Gears running on Windows CE powered devices

Looks like the Google Gears team is working on a port to Windows CE

http://groups.google.com/group/google-gears/browse_thread/thread/ecd9aa97b2b47de7

Google Gears Object/Relational Mapping API

Uriel Katz is making available an Object/Relational Mapping (ORM) API on top of Google Gears. Worth taking a look-see. It makes you aware of the possibilities...

http://www.urielkatz.com/archive/detail/google-gears-orm-v01/

New Dojo Offline Release That Integrates With Google Gears

More Google Gears news. Dojo Offline is a nice framework that is now ported to run on top of Google Gears. Features includes a nice offline widget, SQL support, automatic scanning of resources that need to go offline, and more. Check it out.

http://groups.google.com/group/google-gears/browse_thread/thread/74650bbf1fcf1054/274fe41ae4be5d0b?lnk=gst&q=dojo&rnum=1&hl=en#274fe41ae4be5d0b

How to bind stored procedures to visual web components

I didn't think it was possible to bind the results of a stored procedure to a visual web component, but this short NetBeans Wiki entry shows it can be done. There 's also a promise of an article coming soon. Cool!

http://wiki.netbeans.org/wiki/view/HowToUseStoredProcedures

Thursday, August 02, 2007

Google Uses Crowdsourcing To Create Maps In India

As anyone who has lived in or visited an Indian city can attest to, mapping such city is not for the faint of heart. Back alleys, tiny streets, all wandering one into the other, most without real names or addresses. I wonder how accurate this really is.

http://radar.oreilly.com/archives/2007/08/google_uses_cro.html

Stephen O'Grady on The Potential for Online Desktop

A very cogent and detailed plus/minus analysis of the opportunities and issues around an "online desktop" model - e.g. a desktop whose software relies on and integrates online services.

http://redmonk.com/sogrady/2007/08/02/online_desktop/

Cay Horstmann's not happy with The Java DB in JDK shell game

Java DB keeps moving its location in the JDK. This has an impact on everybody relying on it, and Cay Hortsmann has something to say about it. We've had the same problem in NetBeans. I am hoping after Update 3 things will settle down.

http://weblogs.java.net/blog/cayhorstmann/archive/2007/08/a_bundle_of_joy.html

Wednesday, August 01, 2007

1300 miles on a 9.6 gallon tank of gas

Can't beat that!

http://earth2tech.com/2007/08/01/life-with-a-plug-in-prius-1300-miles-on-a-tank-of-gas/

Xerox invents super-green paper

Claims they reduce greenhouse gas production by70% when making this paper. That's pretty impressive

http://blogs.zdnet.com/Berlind/?p=691

Serious high tech on the new Virgin America planes

Wow - I would be happy just with the 110V plugs, but this also includes mpg playlists (that are remembered for your next flight), usb jacks for charging, satellite movies, chat and wireless internet access. Sold!

http://radar.oreilly.com/archives/2007/07/_virgin_america.html

Tuesday, July 31, 2007

What's going on with Parallels?

This is from an email exchange here at Sun.

I'm getting nervous about Parallels if this is what things are looking like. What are the alternatives out there? I guess it's time to find out.

XXX wrote:

All,

Has anyone else tried to avail themselves of Parallels customer service lately?

My account on their website was messed up somehow (error messages) so I tried to call. I stayed on hold on a toll call for 15 minutes despite being told I was "first in line".

Personally, that's making me really nervous about buying any further licenses/upgrades from them.

YYY responds:

When I contacted them regarding the fact that they hadn't sent me my upgrade licence for v3, and that I had already opened one of my vms in v3, making it impossible to go back, I got two nonsensical emails, the a pause of a month (!), after which they sent me a new licence.

For what must be a small organisation, they sure are disorganised, because I had already received the licence I was due from another part of the company.

I wasn't very impressed with QA for v3 either. I've bought Fusion.

Monday, July 30, 2007

Sun Reports Profit, Beating Forecasts - New York Times

Not bad, not bad :)

http://www.nytimes.com/2007/07/30/technology/30cnd-web.html?ex=1343448000&en=e88ef5b47840a100&ei=5088&partner=rssnyt&emc=rss

Earth2Tech

I've been reading this blog for the last week or so and I'm really liking it. Very interesting news around green tech, solid analysis, and easy to read. Highly recommended.

http://earth2tech.com/

Donald Knuth Speaks Out Against Software Patents

A great quote against software patents from what this blogger calls the "patron saint of computing" - Donald Knuth. Read it through to the end, it's just perfect - imagine having to pay a license fee to apply the Theorem of Pythagoras :)

http://opendotdotdot.blogspot.com/2007/07/patron-saint-of-computing-against.html

Thursday, July 26, 2007

Earth2Tech » Toyota’s Testing Plug-in Hybrid Car

Looks like Toyota is going to come out with a plug-in hybrid. Bully for them! Now why didn't they do that in the first place, is what I want to know.

http://earth2tech.com/2007/07/25/toyota-to-sell-a-plug-in-hybrid-car/

Father moves

A correction about where my Dad is blogging -- he's now at http://john.vc.

Even if you don't know him from Adam, I highly recommend you check it out and perchance subscribe. His one about Darwin and bonobos had me laughing out loud.

He has chosen a Wordpress site set up by my bro. Bully for him, as long as he's posting, is what I say. He's been busy too, more than ten posts in the last few days. Can't hold him back!

Mike Olson of Oracle: Open Source Not That Important

Mike Olson of Oracle (previously the CEO for Sleepycat) just posted a blog about his keynote at OSCON. He argues that there is value in collaboration and community, but that it doesn't necessarily require open source code. He mentions VMWare and newer community-based web sites as examples where the power of collaboration is tapped without requiring open source code.

I think if you look at open source as only about collaboration, then yes, you can draw these kinds of conclusions, and you may think, hey, maybe having open source code is not that important.

But as I have mentioned before, I think this misses a crucial point about open source. Open source is not just about collaboration. That may be cool for open source developers, but for users of open source, it's much more than that. It's about freedom. It's about not placing heavy dependencies on a single vendor. Open source and an open community gives you the assurance that the technology you are depending on is not going to be discontinued or put into "maintenance mode," it won't be acquired by someone who you would rather not do business with, and it won't be used as leverage against you to extract money or modify your behavior.

As a representative of Oracle at OSCON, I'm not surprised by Mike taking this perspective. I think we can all agree that open source databases are a threat, to some degree, to Oracle's key source of income. If I were at Oracle, I would be paying close attention to open source databases, and I would be trying to find ways to reduce the panache of open source without coming right out and saying "we hate open source and wish it would go away," which really wouldn't go over well. It's similar to how Sun behaved towards Linux a while back.

That said, MySQL, as the most popular open source database, is I believe less of a threat to Oracle than the other ones. Why? Because it does not have an open community -- it is controlled by a single vendor. This means it's an even playing field. Oracle can compete with MySQL by showing they have better features, or by offering a free version (which they have done), or even, if necessary, by acquiring MySQL or technologies it depends on (which they have done (twice)).

But this tack won't work so well with open source databases that are built in an independent open community. PostgreSQL, by being an open community, provides the additional value of freedom from the tyranny of a single vendor. And you can't "buy" the company that makes PostgreSQL, as there is no company to buy. There's nothing Oracle can do to respond to this, barring opening up their source code to an independent community (shyea, right).[1]

So if PostgreSQL can provide competetive, "good enough" database features and performance (and things are looking good in that arena), and if you can even get support for PostgreSQL, then if I were at Oracle I would start getting a little worried, and just hope that not too many people notice that "other" open source database over there in the corner.



[1] Note that's what Sun did in response to Linux.

Wednesday, July 25, 2007

The dangers of depending on a vendor and the power of an open community

When recently commented that IBM has bought DataMirror and thusly Pointbase, I failed to mention some very amusing history around this, and how this illustrates a very important issue around the dangers of using third-party code.

Some of you may remember that the original Reference Implementation of Java EE that Sun shipped included a copy of Cloudscape. I remember using it at a previous job and really enjoying the simple yet powerful database that came with the RI.

Then IBM bought Informix, who had bought Cloudscape. Now, we're all friends here, but let's be honest, Sun and IBM are competitors. I wasn't involved in the decision, but I suspect that Sun was uncomfortable licensing some pretty key technology like this from IBM.

So Sun found Pointbase, a tiny little company with a nice little Java database, negotiated a license, and replaced all uses of Cloudscape with Pointbase. Sun also started shipping Pointbase in their tools products.

Some years later, Sun decided to invest in Apache Derby. For those of you who aren't keeping score, Apache Derby got it's start when IBM contributed of Cloudscape to open source.

Well, having a database that you can use free of charge, open source, and which you are actually investing engineering resources in, is clearly better than one you need to license. So Sun decided to replace its uses of Pointbase with Java DB (Sun's supported distribution of Apache Derby). In other words, we put the same database back in that we had pulled out years before. Sigh...

And now, if that weren't ironic enough, IBM has acquired DataMirror, which owns Pointbase. My my, this does sound familiar :) But this time, Sun was not caught off guard, and we are not in a position of yet again licensing a key component of our software solution from IBM.

And this leads me to the moral of the story. When you depend on software from a single company, you run the risk (actually, I think a pretty high risk) of that software ending up being owned by a competitor.

If what you are licensing is a key part of your product, you may find yourself over a barrel. The competitor may discover that they have their hands on some pretty nice puppet strings, and they may choose to start yanking them. Oh, did you want that Very Important Feature? Oooh, that's going to cost you... I'm not saying that IBM would ever do such a thing, nor Sun, of course! But it sure is an uncomfortable feeling to find yourself in this position.

Even if the company you are licensing from is never acquired, the existing company may recognize that it is deeply embedded in your product portfolio, and start asking for more money. Ask anyone who is invested in and committed to Oracle or Microsoft, and you'll likely hear an earful about ever-increasing license costs.

These rules still apply in the Web 2.0 world. If you're building a mashup solution that depends on technologies solely owned and controlled by a single company (even if they swear they Do No Evil), you are putting yourself at risk. This is especially true if you're placing your data under their control.

This issue is a very real concern for governments. A lot of governments don't like the feeling of licensing or otherwise depending upon key components of their solutions from companies that are situated in (and governed by the laws of) countries they are not fully comfortable with. This is one of the key reasons why so many governments are mandating the use of open source software.

But you have to be careful what kind of open source you are using. As an example, a lot of companies rely heavily on MySQL. MySQL is open source, but you must be a MySQL employee to commit to the code base, and you have to purchase a license from MySQL if you want to redistribute it. At some point somebody could acquire MySQL (note that Oracle acquired InnoDB, a key component of MySQL), and you may find yourself in the uncomfortable position of licensing your database engine (and if that's not key technology, I don't know what is) from your competitor. Alternately, MySQL may decide to start increasing license costs more and more over time, and you'll have no choice but to grumble as you pull out your wallet.

On the other hand, Apache is an independent non-profit organization that is not up for sale. Apache projects are required to have committers from at least three independent organizations before they can exit incubation, so no one company can exercise absolute control over an Apache project. Apache projects also go through a very strict inspection during incubation to make sure there are no legal encumbrances on the code.

Similarly, PostgreSQL is managed by a non-profit organization and has committers from many different companies and independent developers.

For these reasons, if at all possible, I would much rather base my product on Apache Derby or PostgreSQL than on a product owned by a single vendor like Microsoft, Oracle, DB2, or even MySQL, even though MySQL is an open source product.

So, think carefully when licensing key software from a third party, and take a good hard look at open source/open community alternatives, even if they aren't as perfect a fit. Sometimes it is the right choice to purchase a license, but you should walk into the deal with your eyes wide open to the potential consequences.

Tuesday, July 24, 2007

New Toshiba R500 - The Envy Machine



I just read this article at Popular Mechanics about the new Toshiba Portege R500. I just recently switched to Mac, but this laptop, with its crisp, ultra-thin LED screen that uses the sun's light to brighten itself outside, 10 hours of battery life, 1.7 pound weight, and, in one model, a pure solid state 64GB disk drive to reduce power usage and improve speed, make me more than a little jealous. Innovation happens everywhere, and there is a definite downside to depending on one and only one supplier.

LiquidPiston - Massive Improvement of the Internal Combustion Engine

This looks pretty interesting - LiquidPiston claims its technology can reduce the standard internal combustion engine's NOx emissions by 70% and the CO2 emissions by 50% . Wow.

http://earth2tech.com/2007/07/23/liquidpiston-gets-cash-for-engine-tech/

Microsoft brings multi-touch to the laptop

Check this out. I saw Jeff Han's multi-touch demo from the Ted Conference and was mightily impressed. I was wondering how long it would take to bring it to a laptop.



Some folks ask, will this replace the mouse? I don't think so. A mouse has much finer granularity than a finger. But it will definitely supplement it, and I think it will be used in very creative ways, especially for design and artistic applications.

Monday, July 23, 2007

New contributor agreement for NetBeans

I don't know the legal details that much, but I have heard people complain about the NetBeans contributor agreement.

I recently got an email on the NetBeans announce alias from Darin Reick at Sun, and it looks like Sun has made some changes to make it more palatable.

New Contributor Agreement for the NetBeans Community
--------------------------------------------------------------------------
An updated version of the Contributor Agreement (v1.4) has been posted on http://www.sun.com/software/opensource/sca.pdf. The new version makes it clear that contributions made by signatories cannot be usurped by Sun Microsystems as the joint copyright owner and used ONLY under a closed license. All open source projects sponsored by Sun are adopting this new standard Contributor Agreement. The Contributor Agreement is not product specific, so by signing once, you may contribute to all open source projects sponsored by Sun.
  • Specifically, the Contributor Agreement v. 1.4:
    • Added a promise to make contributions available under open source license (last sentence of Section 2).
    • Added a backup copyright license to Sun in the event the joint assignment to Sun is invalid for some reason (3rd sentence of Section 2).
    • Cleaned up some language.
IMHO, this is a Big Deal for NetBeans, as it removes a big hurdle for folks who would like to contribute.

Note that it's the same agreement as is used for all other Sun-sponsored open source products, like Open Solaris, OpenJDK, and Glassfish. This means you only need to sign the agreement once, and you're free to contribute to all these projects. Pretty cool.

GigaOM: What about the people?

Om Malik asks the question: what happens to our data when companies small or large shut their doors with no warning. Another clarion call for open data.

http://gigaom.com/2007/07/22/what-about-the-people/

Alfresco Open Source Barometer - An Open Source Survey

An interesting survey. Note that PostgreSQL is a close second to MySQL

http://www.alfresco.com/community/barometer/

Sunday, July 22, 2007

Is Java on the client going to take off?

If what Josh says is true, then things are looking very very up for Java on the client. I am eager, hesitant, hopeful, and excited all at once.

http://weblogs.java.net/blog/joshy/archive/2007/07/java_fx_updated.html

Friday, July 20, 2007

At Sun there's no There There

Rama Roberts provides a map from a team meeting. This is exactly my experience, and the map is a great illustration. I don't know about other companies, but Sun is a very distributed organization. It has its drawbacks, but mostly I really like this!

http://blogs.sun.com/rama/entry/managing_an_international_team

Thursday, July 19, 2007

Throwing Finder in the Trash

I have tried, I have tried nobly, to use Mac Finder. But after struggling over and over and over again to easily move a folder from one location to another without having to open multiple windows and losing my place again and again, I give up.

I am now formally seeking a replacement for Finder. The one that appears to be quite popular is PathFinder from CocoaTech. The reviews are strong, and I tell you, if people like it, then it must be better from Finder, which to me is just as brain-dead as it gets. How can Mac get so many things right and get this basic thing so wrong?

And please, don't ask me what specifically I don't like about it. I get so confused I can't even tell you. I just know that if I'm getting frustrated at my file browser, over and over again, then it's time to find a replacement.

Installing X11 and the X11 SDK for Mac

I am in the process of trying to see if I can record VNC sessions on my Mac. Why on Earth would I want to do this? Well, I'm doing a series of interviews with database developers, and I want them to show me how they work, and I want to record this.

So, it turns out you can record a VNC session as a Flash video [1] but it takes some work.

The first step is to install X11 and the X11 SDK on your Mac. This actually was harder than I thought it would be. The Mac pages say it's "on your Tiger DVD". Hm. That's kind of like saying the Indian restaurant you want to go to is "in New York City."

So, after a lot of Googling and poking and false starts, I figured out how to do it without having to reinstall Mac OSX completely (I balked when it said it wanted to reboot my machine and start the install process).

  • Put DVD 1 of Mac OSX Tiger into your DVD drive
  • The contents of the DVD should pop up in Finder
  • Double-click on "Optional Installs.pkg"
  • Skip past the Introduction, the license agreement, and select a location. Don't worry, it won't start installing
  • You will see the "Installation Type" dialog
  • Open the Applications node, and check X11
  • Click Install
Whew, OK, that installs X11.

You also need the SDK. That's somewhere else entirely, but on the same DVD

  • Open "Xcode tools"
  • Double-click on "Packages"
  • Double-click "X11SDK.pkg"
This will install the SDK for you.




[1] I could not get this approach to work for me. The performance was godawful slow. What I have done instead is I got the recommended screen recording tool, Snapz Pro. This seems to be working great, although the movie size is a concern. Once I get this all working, where I can record a telephone conversation combined with a VNC session, I'll let you know how I did it.

Sprint and Clearwire to Build National WiMAX Network - New York Times

Very interesting. But I suspect, at least initially, it's not going to be cheap. In my dreams, I envision grassroots folks building an Internet access web that doesn't rely on the Big Players for the plumbing.

http://www.nytimes.com/reuters/technology/business-sprint-clearwire.html?ex=1342497600&en=aa660723df5e5922&ei=5088&partner=rssnyt&emc=rss

New blog for a special market segment

There is a very small but passionate market segment that is interested, very interested in what's going on with my family. You know who you are.

You now have your own blog. I decided (on the advice of my dear brother) to separate these two audiences so those of you who want to hear about Java, databases, technology, and so on, don't have to sit through my gushing about my kids.

And those of you who want gushing and more gushing, don't have to troll through my dry missives about technology gossip, coding examples, and so on.

IBM buys DataMirror and thusly Pointbase














Just got a note from a friend that IBM has bought DataMirror. Given that DataMirror bought Pointbase a while back, this puts IBM in the awkward position of being invested in two small-footprint, 100% Java databases - Pointbase and Apache Derby.

Given that from what I understand there are a lot of IBM products that rely on Derby/Cloudscape, I don't think this bodes well for the future of Pointbase. I suspect it will hang on in deployments and uses where it is already in place, but I would be surprised if, for instance, IBM start replacing all its uses of Derby with Pointbase. Especially since Derby is a better product (disclaimer: I am highly biased :))

One nice thing is Pointbase owns some fairly good synchronization technology, and maybe IBM will be inspired to incorporate this into Apache Derby. That would be cool.

Trivia note: did you know that the mobile version of Pointbase, Pointbase Micro, was written by Thomas Mueller, the same guy who wrote HSQL and H2. Thomas, you get around! :)

Wednesday, July 18, 2007

The Father Speaks

I think I finally convinced my pa to start blogging. He is a great writer, fun to read, and he just seems to travel everywhere.

He also has some stinging political commentary, straight from the left, so if he gets worked up about something he's read in the New York Times, you may be in for a treat.

Tuesday, July 17, 2007

Accidental URLs

My Dad sent these out. Sorry, I know they're silly, but they just made me laugh.

All of these are legitimate websites - go ahead, click on the URL - that didn't spend quite enough time considering how their net names might read at first glance.

  • The First Methodist Church down in Cumming, Georgia, has seen a big upsurge in attendance after opening their website at http://www.cummingfirst.com/

Peer-to-peer database synchronization



Being a technologist, I often think of technological solutions before I think of an actual use case. I know from past experience with both my own ideas and others that this Doesn't Work.

My latest flash is the idea of having a community of peers be able to securely share a relational database, creating an opportunity for collaboration and dialog, without having to put the data on a central server. My motivation for this is that as soon as you put data on a central server, that central server becomes key. It puts a particular location in a situation of greater power, and that changes the entire dynamics of the model: socially, economically, politically.

I would like to see communities created where only the peers in the community are involved, and each is an equal: nobody holds a "lock" on the data and the community and is thus tempted to exercise control in various ways.

Examples of this that are out there already which seem to fit into this architecture are BitTorrent and Mercurial. But BitTorrent works with binary data, and Mercurial works with text files (for the most part). Neither of these work with structured, relational data, and the advantages a relational database provides.

There are technical challenges. If you open yourself up to accepting connections, you open yourself to all sorts of trolls, worms, ogres and various evil creatures of the Dark Internet. So I don't like doing this, and neither should you (as a standard, regular Internet user). But how do you do peer-to-peer without doing this? You need to implement some very strong security, and strong security can easily mean a big, oafish, burdensome user interface to let someone join a community, which generally is a killer.

But that's not the only problem. The other problem is: who cares? Why would we want peer-to-peer database sharing among communities? What value does it provide? What is the "killer app?" Does anyone have any ideas? I'd rather test this idea out by building an actual useful solution rather than just building it because it's a "cool idea." Cool ideas don't amount to much if nobody cares and it doesn't do anything useful.

So, if you have thoughts, tell me, or point me to what others are doing. And if you think this is not useful, tell me why. I want to know.

40 Terabytes More Data For Amazon S3

Phanfar is going to back up all 40TB of their data on Amazon S3. Wow, that's a huge amount of data.

http://www.techcrunch.com/2007/07/13/40-terabytes-more-data-for-amazon-s3/

Salesforce.com transitions to platform as a service

Interesting - another big player is making their platform available for end users to build on top of. I wonder if the programmer of the future is one who integrates these platforms into a solution, rather than building in-house applications from scratch.

http://blogs.zdnet.com/BTL/?p=5672&tag=nl.e622

Friday, July 13, 2007

Google Mashups Editor: The Google Application Server - Mark McLaren's Weblog

Mark McLaren provides some very interesting details on the Google Mashups Editor. This is something to sit up and pay attention to...

http://cse-mjmcl.cse.bris.ac.uk/blog/2007/07/13/1184319308616.html

Micro Musings

My Dad is a great writer, and every now and then I get a great email about his travels or whatever on the family email list. I have encouraged him to blog, no such luck. So heck with him, I started a cut-and-paste blog for him. Cheers, Dad!

http://johnvancouvering.blogspot.com/

Thursday, July 12, 2007

Now THAT is a playground!

I don't know why we don't go there more often, but there is this amazing place on the Berkeley Marina for kids 7 and older called the Berkeley Adventure Playground.

I went there on July 4 with Ariel, and it was just stunning.  You have to sign a piece of paper when you come in saying you will never in any way sue Berkeley for what happens in this place, and it's obvious why.  Children can check out a can of paint and a paintbrush, or a hammer and some nails, and go to the structures (all built with wood) and paint to their heart's delight.  You can slide down a 20-foot-long rope on a wheel and smash into a pile of sand.  Here's the video of Ariel doing it if you don't believe me:



You can get into a barrell and roll down a hill.   Here's the video:



You can play in a huge pile of dirt.  You can put an old plastic boat at the top of an incline and "surf" it down the hill. 

There is old netting.  There are bits of old piano lying around ready to be painted.  The place is an insane heaven of chaos and play.  It is like the alter-ego of the nice, brightly colored plastic playgrounds where a slide is just a slide and steps are just steps and you can not in any way hurt yourself if you tried.  I don't know if you've noticed, but newer playgrounds don't have merry-go-rounds or see-saws, staples of my childhood play.  Why?  Because you could hurt yourself.

So some parents are willing to sign the paper, take a little risk, and let their kids have a little fun.  And believe it or not, you can even drop your kids off to play there, and the volunteers will watch over them. Wow.

Here's a full slide show of the pictures I took there.  If you're ever in the neighborhood, you definitely have to come over and see it for yourself.

Wednesday, July 11, 2007

Ted Neward responds to Gavin about object databases

I've worked with relational databases my entire career, and saw the rise and demise of object databases. But Ted makes a very good point: "since when does one tool solve all problems?"

http://blogs.tedneward.com/2007/06/12/The+Relational+Database+Needs+No+Defense.aspx

Dynamic Data in jMaki Widgets Using JPA

A very nice, quick tutorial on how to bind a database table to an AJAX table component. Even more cool would be to have the database running embedded in the browser (see my comment on the blog).

http://blogs.sun.com/arungupta/entry/dynamic_data_in_jmaki_widgets

Tuesday, July 10, 2007

PostgreSQL rocks with a SpecJ benchmark



PostgreSQL Elephant


The PostgreSQL team has just published their first official performance benchmark, SpecJAppServer, running on Solaris with Niagara hardware, and it rocks, delivering 780 JOPs!

Josh Berkus of the PostgreSQL core team shares:

This publication shows that a properly tuned PostgreSQL is not only as fast or faster than MySQL, but almost as fast as Oracle (since the hardware platforms are different, it's hard to compare directly). This is something we've been saying for the last 2 years, and now we can prove it.

Max Mortazavi provides some more background on this, and Jignesh Shah and Tom Daly give some details.

If you didn't catch this, this is a free and open source database (with an open community) that has competitive performance with Oracle, and with full enterprise-grade support available from Sun. It's free to use however you like. No restrictions, no dual licensing. That means price / performance = infinity :).

If you haven't been looking at PostgreSQL for your enterprise applications, maybe it's time. And if you think x86/Linux is the best place to run a database, maybe you should think again, and take a serious look at Solaris and Niagara.

Monday, July 09, 2007

Take me out to the ball game


Ariel has been asking me for a while to take her to an A's game. She even has the cutest pink A's baseball cap (see above). So I finally found a good time, and we headed off to the game on BART this Saturday.

She was so excited, and grabbed my hand and smiled as we walked into the stadium. She was stunned at the view.

The first thing she asked me was "can we buy some junk food now?"

I worked at telling her the difference between balls and strikes, foul ball versus home run, what it meant to have bases loaded and why the A's pitcher was really doing a terrible job by walking so many runners and then allowing a home run.

She was very polite and tried to listen, but generally had this vague look of Not Quite Getting It (and not really caring). Mostly she had fun watching the cute elephant mascot do antics, and really really wanted some cotton candy. I checked in with her a couple of times, telling her if she was bored we could go, but she definitely did not want to go.

It really touched my heart. She just loved doing this, and doing it with me. That was all that really counted.

We bought a baseball, and she carries it around with her in the house and won't let Michael touch it.

Later when Linda asked her about the game, what she remembered most was the guy who swung so hard he fell down on his butt, and the guy who broke his bat. That, and the cotton candy, of course.

Whoops!

Michael had cut his foot the day before, so the next morning when he kept favoring one foot and walking in a twisted sort of way and falling down, we were really worried. We finally grabbed him and as he wailed we looked at his feet, trying to find a splinter or a cut or anything. Nothing we could see was wrong.

Then Linda said "I wonder..." and took off his pants. She had put both his legs into the same hole of his diaper wrap. Whoops :)

YouTube - Keith Olbermann - You have stabbed us in the back - RESIGN

Wow. When someone on a large media channel says something like this, that takes passion and dedication and courage. And I have to say... I agree with him. Not that it will ever happen...

http://www.youtube.com/watch?v=pHySV6cCsbI

Tuesday, July 03, 2007

A creative use for an iPod

I was thinking, there will be a lot of iPods available on eBay now that the iPhone is out. May be a good chance to score one. Except that I don't want one.

Speaking of iPods, on the bus today I saw that even an iPod is a multi-functional device, not just the iPhone. A teenage girl across the way from me was using the back of her iPod (while listening to music) to see her face while she did her makeup. Now is that cool or what? :)

Monday, July 02, 2007

It's actually a pretty good life

One can always find things to complain about, but this blog is one where I share some things I'm pretty happy about.

I live in a great town, in a great state, in a great country (yes, can you believe I'm saying that?). I just finished reading a wonderful biography of Abraham Lincoln, and the dedication he and the American people had -- that they were willing to fight and give their lives to save the only country whose government was a democracy -- was quite moving and inspiring:

that we here highly resolve that these dead shall not have died in vain -- that this nation, under God, shall have a new birth of freedom -- and that government of the people, by the people, for the people, shall not perish from the earth. -- Gettysburg Address.

As I read about the sacrifices made to preserve the union, I realized how valuable and precious a democracy for all people is; I am thankful for it, and I am all the more committed to preserving it.

I love California and the Bay Area because of the beautiful weather and because it is a place of innovation and creativity.

I love Berkeley because it's not a city, and it's not a suburb, but something comfortably in between. I also love it because people here generally are dedicated to a healthy lifestyle mentally, emotionally, physically and spiritually. You can't walk a block without bumping into a therapist, a health practitioner, a yoga studio, an organic grocery, restaurants with delicious fresh, organic food, a book store, and so on.

Sun Microsystems is a great company to work for, and one of the things I think they get right is being flexible about where you work. If I had to commute to Silicon Valley every day, I would be miserable. If it was the only way to make money, I'd do it, but I'd be miserable.

But as it is, I am able to work from home, or take a quick bike ride up to one of the many nice coffee houses up on Shattuck that have free wireless. I can drink a latte, listen to some good music, feel a bit connected rather than just sitting in my house, and get some good work done. If I need to run an errand, there is a post office, grocery store, book store, deli, and a great alternative pharmacy all nearby. I recently hurt my back and there is a yoga studio a block from my main coffee house. There is a wide choice of chiropractors and acupuncturists, and generally I can bike from one place to the other without feeling I'm in a war zone.

And because I work at home or a five minute ride from home, I get to see my wife and family, and they get to see me. I am a familiar face. I am woven into my children's life rather than someone who pops in late at night to kiss them goodnight when they're already in bed.

So, there's a lot to be grateful for. I didn't cover the half of it. But this is what is on my mind tonight.

TED Talks -- Hans Rosling: New insights on poverty and life around the world

Great talk, great statistics, passion for human happiness, and an incredible ending - do stick around until the end :)

http://www.ted.com/index.php/talks/view/id/140

Jeff Han: Unveiling the genius of multi-touch interface design

OK, now I get multi-touch interfaces. This is as revolutionary as the mouse, IMHO.

http://www.ted.com/index.php/talks/view/id/65

Sir Ken Robinson: Do schools kill creativity?

TED has made their videos available, and this one is just wonderful! My daughter goes to a Waldorf school, and IMHO they get Everything Right here, including dance every day.

http://www.ted.com/index.php/talks/view/id/66

No way - fully functional Linux computer on a stick

This is outrageous. Fully loaded Linux computer on a stick, Ethernet enabled, ready to go with an SSH server and an HTTP server. Whodda thunk?

http://www.gumstix.com/waysmalls.html

Friday, June 29, 2007

Google Analytics Fun

One of the new things I've been able to do with my new blog site is to add my own elements to the template (and Blogger makes this pretty darn easy to do).

This made it possible for me to add a script that Google Analytics uses to evaluate visits to my site. I can then go to the Analytics page and learn all sorts of things about how this blog is doing. Yes, this is pure narcissism, but it helps to know that somebody's listening.

I had a lot of fun zooming in finding out - OK, who visited from Europe -- drill down -- Northern Europe -- London -- hey, I know who that is, that's my little sister (or maybe it's her hubbie). Hi sis!

Thursday, June 28, 2007

Google Maps Are Now Draggable

TechCrunch announces a very cool new feature in Google Maps - you can now create your own routes or modify them using your mouse over the map. I'm sure I'll find an opportunity to use this soon.

http://radar.oreilly.com/archives/2007/06/google_maps_are.html

Apache Proposes a Code of Conduct

Apache is proposing a code of conduct for email discussions. This seems like a big deal, and a great step forward. To me it's another sign that the Internet community is starting to wake up to the issue of online abuse.

http://wiki.apache.org/incubator/CodeOfConduct

Antidepressants are depressing me

I had a friend the other day who does not have any personality disorders, just a sucky childhood, and now and then he has bouts of depression. He said a number of friends were suggesting he get on medication.

I have another friend who has been diagnosed with mild bipolar symptoms. He is on an antidepressant. When I ask him how he's feeling, he usually says "I don't feel anything. I'm not happy, I'm not sad. I mostly feel a little disconnected."

True, he doesn't go into his binges of being excited about his latest project and flying into it with a passion, and then two weeks later falling into a depression. That's not a healthy way to live, and he needs help. But are antidepressants the solution? My concern is that the antidepressants are blocking his ability to feel anything, and this in turn prevents him from ever really healing himself. It's like living your life as a robot: safe, predictable, and ultimately pointless.

I'll be honest, I don't know very much about any of this. But sometimes you have to go with your intuition. Just as it doesn't feel right for all of us to be listening to music with little ear buds rather than getting together and singing and dancing as a community, it doesn't feel right for so many people to be on antidepressants. Now they're even putting kids on this stuff. Is this really the way we want to go?

I'm not saying that antidepressants aren't effective for the truly psychotic and troubled folks of the world (although there are some doctors committed to, and successfully treating, these folks without drugs). But that's a minority. These new drugs are being taken by everyone, and are being prescribed matter-of-factly whenever a patient tells their family doctor they sleep a lot and want to isolate and feel depressed.

I know there are different opinions and lots of facts supporting the effectiveness of antidepressants. To be honest, I'm not interested in that. I'm just saying, it doesn't feel right, it bothers me, and I believe there must be a better way...

Wednesday, June 27, 2007

Quick Link: Using an Exercise Ball as a Chair

I just hurt my back, and this looks pretty interesting. I might give it a try.

http://www.careerjournal.com/myc/officelife/20070228-athavaley.html

Quick Link: Lijit - A Quick Personalized Search Engine

Very fun to set up, and it looks useful. You tell it your blog and other places you hang out, and it generates a personalized search engine. The idea is you get much more relevant searches. Try it out, it's quite easy to set up.

http://www.lijit.com/

Quick Link: A Veggie-Oil Powered Recycled Computer Cluster

The Alameda County Computer Resource Center is just down the street from me, and they do great things with recycled computer parts, including building a veggie-oil powered supercomputer.

http://www.accrc.org/cluster/

Quick Tip: Making code readable in Blogger

My last post included some source code, and I really struggled how to make this look readable.

I use NetBeans, and I checked, and sure enough, there is an option to export a source file or a selection of source to HTML ("File->Print to HTML..." in NetBeans 6).

This takes care of all those nasty less-than / greater-than conversions. It also sets up some styles and applies those styles to the code, so you get readable code through color-coding.

The trick is, NetBeans generates this as a complete HTML page. But I want to embed this in an existing page. This worked generally, but the styles were lost.

After some thought, what I did was edit the HTML for my template, and then added the styles at the top of the NetBeans generated page to the styles for the template. And voila, I have nice, color-coded source code that is a simple cut-and-paste from NetBeans.

Blogging delicious links

I've really been enjoying Simon Phipp's delicious bookmarks. Its actually one of my favorite feeds.

I like this much better than the "daily links" approach, where I have to open the blog and read them all together. I usually don't bother to open "daily links" blog entries, because the majority of the time there's nothing there of interest for me. With a blog per link, I can quickly scan and pick the ones I like.

That got me thinking, wouldn't it be nice if I could simply tag a link with a quick comment, and have it show up automatically in my Blogger/Blogspot blog? I'm not a big linker, I don't do tens a day, so it shouldn't overwhelm my readers...

Well, delicious doesn't support this capability. But with a little work, I was able to use their APIs and the Google Blogger/GData APIs to accomplish this. And I thought I'd share the code with you. You could probably pretty easily convert this to using other blog platform APIs.

With this in place, now when I want to do a quick blog of an interesting link, just tag it with "blogthis" and run this program. I can run it once for each tag, once a day, or even less frequently. Once all the posts have been blogged, the tag is renamed to "blogged" so that I don't keep blogging the same posts.

There is some preparatory work needed before you can compile and run the code I show below.

First, you need to download the Java client libraries for both the Delicious API and the Google Data APIs. The Delicious API was incredibly simple to navigate; the GData APIs not so. Somehow their documentation is just lightweight and obtuse enough to leave you scratching your head. Maybe they want to use it for interview tests :). Anyway, I finally made my way through and got something working.

Next, you need to get all of the dependent jar files. Ye gods, there are a lot of them. Here they are:

The delicious Java client requires
Then the Google Data client library requires
Finally, you need to get the id for your Blogger blog. To do this, simply go to your blog, view the HTML source, and look for this line:

<rel="service.post" href="http://www.blogger.com/feeds/NNNNNNN/posts/default">

The href attribute is what you use as the postURL for Google Data.

I am using the ClientLogin mode of authentication with Google Data. This mode says it may reject the authentication request and ask for a Captcha response. I didn't want to deal with this, and you can register a particular machine to no longer need Captcha. Since this is for your personal use, this seems a reasonable thing to do. For more information on ClientLogin authentication, see this page.

OK, whew, with that taken care of, here is the fairly simple code to suck down delicious posts tagged with "blogthis" and posting them to my blog.

Make sure
you replace the placeholders for the delicious username and password, Blogger username and password, and the postURL.

import com.google.gdata.client.GoogleService;
import com.google.gdata.data.Category;

import com.google.gdata.data.Entry;
import com.google.gdata.data.PlainTextConstruct;
import del.icio.us.Delicious;
import del.icio.us.beans.Post;
import java.net.URL;
import java.util.List;

public class Main {

public static void main(String[] args) {
try {
Delicious deli = new Delicious("your-delicious-userid", "your-delicious-password");


List<Post> posts = deli.getPostsForTag("blogthis");

for ( Post post : posts ) {
System.out.println("Blogging post: " + post.getDescription());
blogPost(post);
}

deli.renameTag("blogthis", "blogged");
System.out.println("All delicious posts blogged");
} catch ( Throwable e ) {
e.printStackTrace();
}
}

private static void blogPost(Post post) throws Exception {
// authenticate

GoogleService service = new GoogleService("blogger",
"david.vancouvering.delicious-blog");
service.setUserCredentials("your.google.user.id", "your-google-password");

// build entry
URL postURL =
new URL("http://www.blogger.com/feeds/your-numeric-id/posts/default");

Entry entry = new Entry();
entry.setTitle(new PlainTextConstruct("Quick Link: " + post.getDescription()));

StringBuffer buf = new StringBuffer();
if ( post.getExtended() != null ) {
buf.append(post.getExtended());
buf.append("<p>");
}

buf.append("<a href=\"" + post.getHref() + "\">" + post.getHref() + "</a>");

entry.setContent(new PlainTextConstruct(buf.toString()));

// Set the label for the entry

Category category = new Category();
category.setScheme("http://www.blogger.com/atom/ns#");
category.setTerm("quicklink");
entry.getCategories().add(category);

// post entry
service.insert(postURL, entry);
}

}

Moving here

I'm moving my technology blogging here, to consolidate and to make use of some of the flexibility of this blogging platform vs. Movable Type, which really is pretty limited.

I just wrote a cool little utility that pulls all my delicious links labeled "blogthis" and automatically posts them to this blog with the "quicklink" label. When I get a chance, I'll post how I did this, I think it's pretty darn useful and it took some time to figure out.

Talk to you later!

Quick Link: How to Label Posts via the Blogger API

A nice little post from uberdose (whoever he is) showing how to set the type field in your blog when using the Google Blogger API

http://wp.uberdose.com/2007/02/04/how-to-label-posts-via-the-blogger-api/

Monday, March 19, 2007

Bush and global warming

I'm sure this video is making the rounds very quickly, but I just wanted to place my vote for it, I loved it. Also a little scary...

Wednesday, March 07, 2007

A glorious morning walk in Berkeley

Well, I don't know how it is in the rest of the world, but here in Berkeley it has been just gorgeous. I remember, when I first came to the Bay Area over 20 years ago, I came in March. I came from a cold, gray, wintery Boulder, Colorado, to this amazing, almost embarrassing display of blue skies, green hills, and flowers everywhere.

I walk Michael in the mornings a lot, and I am so grateful to be able to enjoy the incredible weather and the beautiful gardens of Berkeley


Just in the few blocks near our house, here are some of the things I saw and snapped with my cell phone on a recent walk this week:








And finally, one of Michael on the same walk. What a smile!