Product and corporate development

A post written by Tor started me thinking about business and product development, especially in this age of online products. Classically, and not so many years ago, a company would have years in which to develop and maintain a new product (such as friends-reunited) and then have years to recoup any investment and of course profit!

However in the current markets, there are lots of people, with easy access to both the talent and technologies (developers and already pre-scaled technologies such as Amazon Web Services), that allows for almost any small startup to be able to deliver a globally accessible and scalable web application in essentially a very much shorter development cycle than many “classical” companies can manage.

This is less important in markets where the company is the sole provider of goods and services, such as Satellite TV in the UK (BSkyB), where as an effective monopoly the drive for innovation is less extreme, and that new entrants to the markets cannot compete so directly, and hence normal free-market conditions cannot happen.

Of course, all of this leads to the further development of “lean” development methods, and driving fast development of new products and features, where you are in a strongly competitive market.

JMX and firewalls… or how to hate RMI slightly less

So at least with Java 1.6 the JVM can use SOCKS for proxying RMI requests, so to get the wonderful jvisualvm (think 1.5 visualGC) working use the following incantations.

This requires the initial RMI registry port is open to the client.

First the initial SSH to server enabling the SOCKS tunnel

$ ssh -D localhost:9696 servername

And now for jvisualvm
jvisualvm -J-Dnetbeans.system_socks_proxy=localhost:9696 -J-Djava.net.useSystemProxies=true

props to http://stackoverflow.com/questions/1609961/visualvm-over-ssh for the hints

java log files

So debugging java can be a mighty pain, a little few lines of ways to make it simpler.


# grep -m 1 -n '^2010-06-30 14:20:' catalina.out
11746233:2010-06-30 14:20:01,011 DEBUG com.beginning.of.line
# grep -m 1 -n '^2010-06-30 14:21:' catalina.out
11747788:2010-06-30 14:21:00,161 WARN org.apache.commons.httpclient.HttpMethodBase - Going to buffer response body of large or unknown size. Using getResponseBodyAsStream instead is recommended
# sed -n '11746233,11747788p' < catalina.out

This gives start line and end line between any two greps and then the body of the log file from those two lines.

disabling atime updates on macos X

Create the following plist file somewhere useful, e.g. /Library/LaunchDaemons/com.local.noatime.plist

<?xml version=”1.0″ encoding=”UTF-8″?>
<!DOCTYPE plist PUBLIC “-//Apple//DTD PLIST 1.0//EN” “http://www.apple.com/DTDs/PropertyList-1.0.dtd”>
<plist version=”1.0″>
<dict>
<key>Label</key>
<string>com.my.noatime</string>

<key>ProgramArguments</key>
<array>
<string>mount</string>
<string>-vuwo</string>
<string>noatime</string>
<string>/</string>
</array>
<key>RunAtLoad</key>
<true/>
</dict>
</plist>

Then run the following to pick up the change, or indeed, reboot:


% sudo launchctl load /Library/LaunchDaemons/com.local.noatime.plist

And you should now see the root file system mounted with noatime option, which should improve longevity of SSD boot drives

# mount
/dev/disk0s2 on / (hfs, local, journaled, noatime)

Snow Leopard and the jvm


So in a startling case of “Apple knows best” they have gone and removed the 1.5 JVM – I know it’s pretty old and people were complaining about not having a 1.6 JVM for a long time – but really!

So the following post steps you through re-enabling the 1.5 VM and now semi-happy days