By default IntelliJ is setup to use a maximum of 192 MB of heap. The JVM memory settings are as follows:-Xms16m -Xmx192m -XX:MaxPermSize=92m
I have found this to be almost always too low, systematically resulting in OutOfMemoryError. So every time I install a new version of IntelliJ, the first thing I do it to change this setting with:-Xms16m -Xmx392m -XX:MaxPermSize=92m
If you are on a Mac, you can do this by editing the following file* and searching for -Xms in the file:/Applications/Selena-7670.app/Contents/Info.plist
* Replace Selena-7670 with the name of your the IntelliJ executable, which, if you are using regular releases instead of EAP builds, will look more like IntelliJ IDEA 7.0.
Monday, January 28, 2008
Memory Settings for IntelliJ
Saturday, January 26, 2008
The Right Title
Aircraft Crashes on Los Angeles Freeway. This is the headline of an article I see today on the New York Time home page. Sounds like a major event, doesn't it?
Click on the link, start reading the article, and you will see that the aircraft wasn't a plane but and helicopter. This is a tragic event: the pilot died in the crash, and I can't help to think that whoever crafted that title made it imprecise on purpose to lead people into thinking that this is a bigger story that it really is. Is this ethical, especially since this is a tragic event?
Labels: ethics
Friday, January 25, 2008
Reformat XML with XML Spy
If you wouldn't think of IntelliJ when looking for an XML editor, think again: IntelliJ is a great XML editor. As a matter of fact, it has been my XML editor of choice many year now.
But I have to admit: IntelliJ isn't perfect; in particular, it is very slow at reformatting XML on large files. Say you have a document that weighs a few MB and you want to reformat it to make it more readable. This happens to me frequently when dealing with XML generated by Microsoft Word, which likes to put pretty much everything on a single line. Going through a few MB of XML all in one single line not what I would describe as an enjoyable experience. So here is the trick:
- Open your large XML file in XML Spy, reformat it, and save it.
- Open the newly formatted file in IntelliJ (or your favorite editor).
Thursday, January 24, 2008
Delete All Files With Exceptions Using find
Gavin suggested a clever trick to recursively get the list of all the files in in a directory, except those under .svn. It goes like this:find WEB-INF -path "*/.svn" -prune -o -print
I used this quite a bit, but never thought about how this really works, until today:
- The
-ois an or operator. So either-path "*/.svn" -pruneor-printis true. Let's look at each part. - The first part
-path "*/.svn"is true for the.svndirectories and with-prunewe skip the content of those directories. - If you just had the first part, you would be skipping over the content of the
.svndirectories, but not over the directory itself. The second part-printprints what isn't matched by the first part (because of the or). So it won't print the.svndirectories.
- directories;
- files in the CVS directories.
find . -path "*/CVS" -prune -o -type f -exec rm {} \;This can be useful for instance when you have files checked out from CVS or Subversion and want to replace all your files by a copy of those files that you receive from someone in an archive.
Labels: unix
Wednesday, January 23, 2008
Twitter: No Usable RSS Feed
Twitter is simple. It lets you do only two things:
- Post a 140 character status message.
- See the status of the people you are following (to use the right Twitter terminology).
- Updating your status must be one of those operations you can do really fast. I don't want to go to a web site for that. I imagine a dashboard widget would work nicely. I tested two (Twitterlex and Twidget). They both are not quite usable. IM is another option, but only GTalk/Jabber is officially supported, and it works only if you have a single Twitter account.
- Twitter provides an RSS feed with the updates of those you are following. But you need to be authenticated to read it. So that feed won't work online feed readers, such as Google Reader. Bummer.
Labels: web2.0
Tuesday, January 22, 2008
Happy Employees Are More Productive, or Are They?
You would think that happy employees are more productive. At least I would. On that premise, companies are spending quite a bit of money to improve the workplace.
While there indeed is a correlation between happiness and productivity, increasing happiness does not necessarily increase productivity. Read what Nathan Bowling has to say about this, as quoted by Freakonomics:
My study shows that a cause and effect relationship does not exist between job satisfaction and performance. Instead, the two are related because both satisfaction and performance are the result of employee personality characteristics, such as self-esteem, emotional stability, extroversion and conscientiousness.Or said otherwise: both happiness and productivity are causes of other factors, themselves not necessarily well known and easy to identify or quantify. So just increasing happiness independently of those factors does not necessarily influence productivity.
What is the most interesting about all this is to see how easily we mistake a correlation for a causality. Because two factors are correlated does not automatically mean that one is the cause of the other. If there is one lesson to be learned from Freakonomics, it would have to be this one.
Labels: gtd
Monday, January 21, 2008
Google Drive (GDrive) Coming Soon
I have been surprised to see how quickly the free storage capacity on Gmail has been increased during the last few month of 2007. Wikipedia has some numbers for us:
On 12 October 2007, Google ramped up the storage counter to 5.37 MB per hour. Approximately a week later, the counter went back down to 1.12 MB per hour. This adds up to about 806 MB per month or over 9.8 GB per year. From 4 January 2008, the counter went back down to about 3.35 MB per day.While some people will end up using a significant portion of this space, most people, even power users, won't. So what is the point of increasing the storage capacity to those level? Maybe Google is just doing it because they can. I will be optimistic here and predict that Google is drastically ramping up their storage infrastructure to get ready for a new file storage service, often referred to as Google Drive or GDrive, that they are planning to launch later this year.
Labels: google, prediction
Wednesday, January 16, 2008
More Features not Announced and the $20 Upgrade
Listening to MacBreak Weekly's Keynote Analysis made me realize how many iPhone features were not announced at the keynote. Even some that we expected to have in the iPhone when it first came out, as most modern phone have those capabilities:
- Take video video clips
- Send and receive multimedia messages (attaching photos and video clips)
It could also be the beginning a a trend for Apple: I have been wondering how Apple would deal with software updates to the iPhone. Should they make the updates available only on the latest iPhones, or should they make them also available for free for older iPhones? Maybe Apple will pick a way which is somewhere in the middle: make the updates available to existing iPhone, but for a charge. This is somehow similar to what Apple is doing with new releases of Mac OS X.
Labels: iphone
Tuesday, January 15, 2008
Steve Jobs Keynote: What Apple Did Not Announced
This morning, the MacBook air was the big thing: a super-portable laptop, both cool and expensive. It is innovative, but maybe not as much as the "tablet iPod touch" some imagined (like an iPod touch, but with a much larger work surface).
For those of us interested in the iPhone, Steve's keynote this morning was almost a non-event. We had a minor upgrade to the iPhone software; really nothing earth shattering. I (any many others) expected Apple to announce at least a couple of items from the list below:
- A new 3G iPhone to be released in June, maybe also equipped with a GPS and tactile feedback
- A new Apple Bluetooth stereo headset which you can use with the iPhone (A2DP)
- A new ultra-small Bluetooth keyboard for the iPhone (or maybe this one is more wishful thinking on my part than a prediction)
- Some of the new iPhone applications created by vendors who go an early access to the iPhone development kit
Labels: iphone
Monday, January 14, 2008
Text from Your Computer with Joopz
That must be a generation thing: I am not a big user of text messages (SMS). But every time I get to do a trip in Europe, I come back with a renewed interest in text messaging.
Here comes Joopz, that I discovered through Russ. Russ says he loves the service. Love is a big word, so I had to give it a spin. The premise is that Joopz lets you send and receive text messages from their web site. It is free up to 50 messages sent per month, and $3/month after that (unlimited).
It sounds good. But this is not a service I will be using. When I sent a message to you with Joopz, you get from a weird number; in my test, this was: (010) 10-0001. Then the message reads: FRM: 14085555555-kjfj@joopz.com MSG: My message here. This is bad for 2 reasons:
- This is not user friendly for the recipient of the message: you have to decode the content of the message, figure that 4085555555 must be the phone number of the sender, and go find who that person is. This just doesn't look like a regular text message.
- This looks like a message sent through an email to SMS gateway. That is: a message the sender didn't pay to send. But the recipient is paying to receive the message. And then paying again to respond. To me that reads as I want to talk to you and I don't want to pay, but you will pay to get my messages and to respond. That doesn't send a good message ;).
Friday, January 11, 2008
"Crowd Hacking" Coming Soon to a Restaurant Near You
TechCrunch wrote about a Subvert And Profit:
Subvert And Profit is a service that lets users pay to get their sites on Digg (and more recently StumbleUpon).How long is it going to be before we see this type of tactics being used for all the services where some sort of rating by the community ("crowdrating") is being used? Consider restaurants. In the Bay Area I would think Yelp is the most popular crowdrating service. A lot of new established restaurants have less than 50 ratings, and new places can have less than 20 rating for a long time. It would be quite easy for a company like Subvert and Profit to influence the final score of a restaurant. For that matter, it would be even easier for restaurant managers to ask their friends to just post a positive comment on Yelp for them. Or are some already doing this?Unlike Pay Per Post, the company doesn’t waste a lot of time trying to spin their business into something socially acceptable. People pay them to pollute big social sites and get traffic, and they’re ok with being slammed for that. As long as they make money. The whole operation is complete with founder pseudonyms (Ragnar Danneskjold, Vasili Taleniekov), proxied whois records, and a clandestine PayPal Account.
Will this make the pendulum swing back? Will ratings by experts such as those you find in the Michelin Guide for restaurants become more popular again?
Labels: web2.0



