the corner office

a blog, by Colin Pretorius

# Firefox prefetching

A LWN article discusses the fact that Firefox prefetches certain web pages for you. Basically, Firefox tries to be smart and if it thinks you're likely to follow a link (say, one labelled 'next'), it goes and downloads that page so that it'll load faster when (if) you do click on it. The LWN article points out some of the potential security and privacy issues this can cause. Interestingly, Google is already taking advantage of this feature.

Not cool, imho. Sure, when you load a web page a lot of stuff might be referenced and pulled down to your browser, and that's just the way web browsing works - but in principle I'd prefer it if my browser didn't load separate web pages until I specifically asked it to. Least of all, the default configuration should be to switch this feature off, and let users choose to enable it if they feel it's something they want.

The easiest way to disable prefetching is to do the following: type about:config in the Firefox location bar, find the setting network.prefetch-next and toggle it to false.

File under: techie : {2005.06.25 20:07} : Comments (0)

# Home rolled

Sheesh, am I losing interest in blogging or just too easily distracted? Well, I've just finished The Dragon Reborn, book 3 of the Wheel of Time. Another 5 on the bookshelf to get through, and if I'm not mistaken, another one or two that Ronwen hasn't bought yet. Still enjoying the series, even if things do drag on a little.

The other thing that's been keeping me busy has been working on a Java version of this blog. I started it ages ago, as a bit of a a Skool Me JSP thing, and a way to put theory to practice and blahdy blah. I've only really pottered around with bits and pieces, and that often boiled down to trying and retrying different things as they took my fancy, without getting any close to finishing it. I finally decided it was time to either shelve the damned thing or get it done. I'm rather keen to get a virtual server somewhere so that I can migrate my email away from my current ADSL ISP, and generally have some root-accessible space to play around with. It doesn't make sense to have that, and my blog's current DDN hosting, least of all since I've been meaning to redesign my blog anyway, and it just doesn't make sense to keep it as a Notes app when I'm using Notes for nothing other than posting to this blog - and schlepping with Wine just to do that, as it is.

I thought about using an off-the-shelf blog app, Java-based or otherwise, but I really do like the idea of having a home-rolled blog. So I decided to get stuck in and finish it off. It'll be a while yet, even if I don't lose interest, but I'm forcing myself to complete one feature or make a useful chunk of progress each time I work on it. So far so good.

File under: thee_blog, personal : {2005.06.22 22:28} : Comments (4)

# Bye bye Zuma

Zuma's been hoofed, and well done to Mbeki for doing it.

Two interesting issues now.

The first is whether Zuma will be prosecuted. My vote would be not to. Lots of work has been done to frame this as an 'tried by the media' issue, and the distinction between "guilty of a crime" and "not a suitable person to be Vice President of South Africa" has become rather blurred, for obvious reasons. There are no guarantees that prosecuting Zuma will result in a conviction, and an acquittal would simply open a Pandora's box of "he was innocent, el pres for 2008!" Not worth it, in my books. I don't care if he's convicted, but I do care whether he's a potential future president of the country.

The second issue is who's going to replace him. Now that Zuma is no longer the heir apparent, who's likely to replace Mbeki in a few years' time?

File under: politiek : {2005.06.14 19:28} : Comments (1)

# Long weekend and bookishness

We took a long weekend this weekend, and travelled down to Durbs for The Van Grubenwyks' wedding. Now they're just the Grubens. Great to share the day with them, and to catch up with some friends we haven't seen in far too long.

Other than that, I've been as lazy as hell. I've barely touched my PC at home in the past 2 weeks, instead I've been wrapped up in books and generally staying curled up on the couch and being as unproductive as I can. I started working my way through the Wheel of Time books - I'm on book 2 at the moment. Ronwen's been on at me for years to read them, and after a few false starts in the past, I finally got going. I've heard often enough that they get increasingly boring from book to book, but so far I'm enjoying the story. Considering how bloody cold Joburg's been the past day or two, I think I'll stay ensconced on the couch for a little longer.

File under: personal : {2005.06.14 18:59} : Comments (0)

# Profiling Jetty

A for-posterity post. I've been doing some homework with Java profilers the past few days. One problem I had was getting a profiler (any damned profiler) to play nice with Jetty. I normally launch Jetty using MyEclipse which has every feature under the sun except profiler support. The other best-known (free) way to kick-start a Jetty server from Eclipse seems to be to use JettyLauncher. JettyLauncher used to have a 'profiler' edition that allowed one to use it in conjunction with Eclipse Profiler (which I first came across a little over a year ago). I learned, only after a lot of mucking around, that the profiler version got dropped a while back. I had no luck getting the older versions to work, with "Failed to load main Class: PluginRunner.class" error messages, or something like that.

Since JettyLauncher creates a new Run... option thingummy watchamacall (r-o-t-w for short), (and other app-launcher plug-ins are variations on the same theme), it gets a big tricky to link it to a profiler since profilers generally specify their own r-o-t-w's and never the twain shall meet unless one of the two sides has specifically catered for the joyous union. The Tomcats and JBosses and Resins of the world generally have the joyous-union support, but Jetty's a little less lucky. As a side note, I'm sure it's all quite doable via remote profiling anyway, but local profiling seems a lot easier and preferable in many cases.

The trick I eventually used for Eclipse Profiler (and YourKit), was to kick-start Jetty as a normal Java app. It's not that hard, really, and the Jetty tutorial has all the code you need to do it. I simply wrapped the tutorial code into a class, like so:

public class MyJettyLauncher
{
public static void main (String[] args) {
try {
Server server = new Server();
SocketListener listener = new SocketListener();
listener.setPort(8080);
server.addListener(listener);
server.addWebApplication("/","./webapps/myapp/");
server.start();
} catch (Exception e) {
e.printStackTrace();
}
}
}
Then I did this:
  1. Created a new Eclipse project
  2. linked all the .jar files in the Jetty's lib and ext directories into the project's build path.
  3. created a class with the above code.
  4. edited the web app context and directory arguments.
  5. Set up a new r-o-t-w thingy and enabled profiling on the app server, which is now just a plain old Java app.
... as easy as that. The Jetty tutorial also has help for working with xml config files and whatnot, but the above worked fine for my purposes.

File under: java : {2005.06.03 21:54} : Comments (3)

# Too much traffic

The little shopping complex around the corner from us has a Brazilian restaurant upstairs. After a name change and a few years of just plodding along, it's suddenly booming, and all the bootiful people seem to be descending upon it in herds.

The problem is that nowadays, it's almost impossible to find parking at the complex. The place has always been bustling in the afternoons and evenings, but the few shops usually have quite a steady turnover of people leaving and arriving, and even at its worst, you'd just drive around the lot once or twice and find a parking opening up. With a restaurant though, it's a different story, and each car is there for at least an hour or few. The result is that people drive around the near-gridlocked parking lot, and there's nothing opening up. I'm sure many of them leave in frustration, and stay away in the evenings in future. So while business is booming for this restaurant, it must have a pretty negative effect on evening business for the Woolies, the Clicks, the Nandos, the pizza joint and the DVD store.

I wonder if there's anything (legal) they can do about it? If the restaurant mysteriously goes up in flames one night, I'll know why.

File under: personal : {2005.06.03 20:45} : Comments (0)

# Guilty

So basically, Shabir Shaik is guilty. Now, if the dude giving the bribe is guilty of corruption, then surely the dude receiving the bribe is too? Will deputy president Jacob Zuma find himself being prosecuted soon? The bullshitometer is in the red already, with COSATU and the like pointing out that Zuma should be presumed innocent until proven guilty. That's a noble ideal, but let's get real here. If one side is guilty, so must the other be.

It's going to be interesting to see what happens next.

File under: politiek : {2005.06.02 19:59} : Comments (4)

meta

-home-
about
contact
disclaimer
articles
code
tech blog

style: [?]
[plain.dark.blue]

Categories

java
linux
music
notes/domino
personal
politiek
studies
techie
thee_blog
world

RSS Feeds

rssfeed all posts
rssfeed all cmts
rssfeed tech posts
rssfeed tech cmts

Archives

2010.09
2010.08
2010.07
2010.06
2010.05
2010.04
2010.03
2010.02
2010.01
2009.12
2009.11
2009.10
2009.09
2009.08
2009.07
2009.06
2009.05
2009.04
2009.03
2009.02
2009.01
2008.12
2008.11
2008.10
2008.09
2008.08
2008.07
2008.06
2008.05
2008.04
2008.03
2008.02
2008.01
2007.12
2007.11
2007.10
2007.09
2007.08
2007.07
2007.06
2007.05
2007.04
2007.03
2007.02
2007.01
2006.12
2006.11
2006.10
2006.09
2006.08
2006.07
2006.06
2006.05
2006.04
2006.03
2006.02
2006.01
2005.12
2005.11
2005.10
2005.09
2005.08
2005.07
2005.06
2005.05
2005.04
2005.03
2005.02
2005.01
2004.12
2004.11
2004.10
2004.09
2004.08
2004.07
2004.06
2004.05
2004.04
2004.03
2004.02
2004.01
2003.12
2003.11
2003.10
2003.09
2003.08
2003.07
2003.06

© Colin Pretorius