Friday, November 07, 2008

I guess it has begun: the environment is at fault for everything

I'm always amazed at the amount of bullshit people are able to come up with, especially when explaining some corporate move.

Take for example my main bank BRD - Groupe Société Générale. Yes, it's the same Groupe Société Générale which showed at the end of 2007 a € 4.9 billion fraud. But it's OK since the Romanian branch is really profitable for them due to limited consumer education here and powerless consumer protection institutions.

I just noticed a new message from them on the Internet Banking site: due to increased environmental awareness from the Bank, they are encouraging people to get alternative bank account statements via online banking or by post. Otherwise you are entitled to one printed account statement per month from their offices.

The reason is, of course, to save the trees by printing less. Of course they are willing to print tons of the stuff if you are willing to pay -- which will go directly into their profit but that's another problem, no ?

Also add here that they also increased the tax for having an account by 20% for individuals and 50% for companies. That probably also had some environmental reasoning that's escaping me.

Anyhow, I'm looking forward to more price increases and consumer ripoffs that's going to be done in the name of the trees.

Too bad us people can't buy our own carbon credit so that companies won't be able to offset that extra cost in the name of the environment on us. But you know what ? I'm pretty sure some one will introduce carbon credit for the masses. After all, why not ? It's a nice way to bring some more money to the state budget.

And only then that old saying will come true: they'll tax you for the air you breath !

Well, technically for the air you exhale but we're close enough.

Thursday, August 07, 2008

No new mail! Want to read updates from your favorite sites?

For a while now I've started using GMail's "Archive" button aggressively on my inbox. The end result has been that from thousands of emails, I now have 0 (zero) ! Everything is archived.

When I get a new email, it sits in the Inbox until it is resolved (ie. I reply or read it). Then it's instantly archived. Out of sight, out of mind.

I've found that this technique greatly reduces the information overload coming from emails. With a full inbox that was also showing snippets of the message (ie. small previews), every time I looked at my inbox I had some information to process. Like: oh, look, that one is starred, I wonder when they'll reply or hm, it's been quite some time since I've got an email from X as the name is on the bottom on the inbox, etc. etc.

Basically a full inbox sends you some information even when no unread emails exist. It's also quite a bad way to "search" for email. I used to manually look for some subject and/or sender in order to hit reply. Now I just use GMail's search.

I remember about some TED video where the host said something like our brain likes new information, we have an addiction for new stuff. Which is exactly what email feeds. It feeds our addiction for new things, even by just having a full list of previously received emails. I also assume that's why sites like Slashdot, Digg and Reddit are quite popular: they feed us new, easy to process, information. Imagine brain junk-food if you will or the Internet-equivalent of too much TV will rot your brain.

Related to this need to always get new stuff, I find it interesting the way Google handles this. When your inbox is empty, you get this message: No new mail! Want to read updates from your favorite sites? Try Google Reader (with a link to google reader).

So what Google is doing here is proving us what we have become used to. Not enough interruptions, not enough new stuff from email? Why gee, why don't you try this other source of new things: Google Reader. Come on, get a quick fix !

Thursday, July 17, 2008

Oh, my, how the NetBeans community has grown !

For quite some time now I've noticed an interesting trend: I don't have the time to read the email in the NetBeans mailing lists. A lot of emails where I could have given some help just fly by me as they are just too many.

Just now openide@ has 2000 unread messages, the oldest unread being from 26 November 2006 about the Manifest File Syntax tutorial (boy, a lot have changed in the Editor APIs). nbdev@ also has about 1700 unread but that's ok as I rarely post / answer there.

Now, this trend seems to be caused by two reasons: me being busy (and lately I'm working full-time on getting the Editor APIs usable in a standalone way) and the community growing.

I do remember the time when I had zero! unread messages. Now I hardly notice when another hundred adds-up.

So, how do you guys handle the workload ?

Of course, the solution might be to be a little more methodical about it and dedicate some exact time (like 30 minutes / day) but it just doesn't seem to work with me. Must be the 100 Editor modules I have open right now in the IDE -- sigh...

Sunday, July 06, 2008

I'm not sure I like Web 2.0

Remember when an URL linked to something static on the net ?

Sure, an URL could be actually a script behind that allows for a more dynamic page.

But when the script is used to discriminate users for a supposedly free site like YouTube, I'm getting kinda annoyed.

This video is not available in your country ?

Un-believable.

So Web 2.0, besides all the AJAX thingy, also brings a wide-spread encouragement to use a proxy to hide your identity ? Is this a social construct to teach us about security and privacy ? Or just a degeneration of what the Internet was supposed to be ?

Thursday, May 22, 2008

I forgot what Alt + F4 does

I saw today an avatar on a forum which said "To view my display picture hold down Alt + F4".

Now, it was clearly some funny-man trick but then it occurred to me that I'm not certain what Alt+F4 does.

I've been using OSX for so long I had forgotten about Alt+F4 on Windows. I guess this is enough Microsoft-independence.

I never wanted to program on Windows or using anything Microsoft specific. This lead me to Java initially then Java on Linux and soon to Java on OSX...

Monday, April 21, 2008

Should the language shape the mind ?

I've read an interesting blurb from Lera Boroditsky (Cognitive Psychology & Cognitive Neuroscience, Stanford University) in Do our languages shape the nuts and bolts of perception, the very way we see the world?, where the basic answer is: yes, languages not only influence our way to interpret information, but also they way we perceive it.

There is an often quoted phrase in the programmers circles:
When the only tool you have is a hammer, everything looks like a nail
,which basically states the same thing: the languages we programmers know and use influence the way we perceive reality.

That's a dangerous thing, because languages (programming languages) were only supposed to help up interpret information. Skewing our perception means we obviously don't even notice the wrong path we've taken.

Being multi-cultural -- that is, knowing multiple languages -- helps, as these may overlap and give you various perspectives on the information and thus make a better representation of the information. The end solution is also most likely to be better.

But I often wondered: shouldn't we at some point just stop trying to force our thoughts into some language and just start expression into another language altogether ? Into our language ?

Sure, learning a language might bring some "discipline" into minds; using it might help up programmers get along with each-other. But in the end a language should just give a programmer some new perspectives. The output should still be in our language.

I assume this is the reason most people think everybody else's code is shit: their internal interpretation doesn't map with the mapping inside the other programmer's brain. A younger you produced a lot of bad code by your current mapping.

Which basically means we are utterly unable to find a way to fully express our thoughts in a way other people would understand, agree and like. And by like I mean having a close mapping with the other (or just bring something totally fresh).

And this limitation doesn't just apply in relation with others but to ourselves.

Then, how should we function ? Each new problems brings into us a current solution with our present interpretation. Should we express this into something like a Domain Specific Language (DSL) ? Should each new problem be represented into a new Problem Specific Language ? (And sure, maybe PSLs at a given time might have something in common as they also represent us).

So what means that some code looks like shit then ? It means the chosen PSL is incomplete, somehow flawed or just not elegant enough compared with our current PSL. Rarely does code look like shit if we like the PSL and the solution is somewhat broken -- then it just has bugs or is incomplete, but we fix it while following the given PSL.

Won't this make cooperation really hard ? Well, not really as cooperation might change the PSL for the better. It will also force programmers to slow down a bit and try to first understand the PSL before understanding the solution. We do this anyway as even while using a common language there is always a meta-layer programmer-specific; only that this layer is sometimes obfuscated by the language used instead of being very prominent like in a PSL.

Maybe general purpose programming languages should stop existing and be replaced only by programming paradigms and concepts.

Tuesday, January 22, 2008

NetBeans Platform autoupdate via BitTorrent

Something I'm pursing nowadays is having my platform applications as decentralized as possible.

And the fist pet peewee I had is that fact that the Update Centers are such, big, centralized, monolithic blocks.

I always assumed that I would need to hack the AutoUpdate module from the NetBeans Platform quite hard in order to get what I wanted all along: BitTorrent downloads for new or updated modules.

So, the first thing we have to notice is that the AutoUpdate Catalog (see DTD) provides for each module in the Update Center a location called distribution. The distribution may be a relative path to the catalog location. That is usually something like ./com-example-mymodule.nbm or it can be a totally new URL.

Now we have a first step towards splitting traffic: we can put the actual NBM file on another URL altogether. Or, if we have the AutoUpdate Catalog location sit behind a servlet we could even try a bit of balancing and return a different distribution link depending on how loaded are the servers. That's a plus...

Ok, that's something but it isn't BitTorrent, you still download the whole file from a single place.

It's alive !

But what the Platform does offer is the possibility to register in the Lookup your own URLStreamHandlerFactory . So, I can register a new handler for the torent:// protocol and the AutoUpdate module will just use my stream handler.

And thus, a few hours later I have a working AutoUpdate infrastructure via BitTorrent. My StramHandler downloads behind the scenes with BitTorrent using Snark and provides a nice InputStream to the AutoUpdate module. It's still not polished but already useable. Install the module from this update center: http://emilianbold.ro/modules-updates.xml or just grab the NBM.

Something else: the destination of the module is no longer pointing now to the NBM, but to a torrent file actually which has the NBM file.

The steps are: place the torrent file on http://example.com/module1.torrent.nbm, edit the catalog to have destination="torrent://example.com/module1.torrent.nbm" and you're good to go. Behind the scenes I'll actually download the http file and then download the torrent.
<!DOCTYPE module_updates PUBLIC "-//NetBeans//DTD Autoupdate Catalog 2.3//EN"
"http://www.netbeans.org/dtds/autoupdate-catalog-2_3.dtd">
<module_updates timestamp="35/26/18/21/01/2008">

<module codenamebase="org.yourorghere.emptymodule"
distribution="torrent://example.com:6881/cc032d0c003b12568c91a0339f88301fa6ca67f5.torrent.nbm"
... >
...

A small remark: note the .nbm extension. It's something the AutoUpdate module needs otherwise it won't be able to install the file as NBM (could be a bug, I'll report it at some point).

The module still needs some extensive testing and different BitTorrent libraries (I'm using Snark, but I would like to have the Azureus core as a different provider in the Lookup maybe) but it does show it is possible.

Using the same technique one could write multiple backend/"protocols" for the AutoUpdate. Drop me a message if you want to know more or want to help me (source code will be online soon).

The case of the different jsch 0.1.54 binaries

As part of the Apache NetBeans IP clearance we are combing through all the code and dependencies. One interesting thing we bumped into wa...