Reverse engineering Google Maps, Gmail and so on…

It only seems fit to blog all the recent efforts to reverse engineer these rich web applications. The interest in client-side processing is very justified. This is a natural evolutionary process for web applications and I am surprised that this did not happen quicker.

To quickly summarise the core idea – to push logic (javascript/XSLT) across to the client, acheive the objective of carrying out as much UI generation and processing on the client-side as possible. Frequency of visits back to the hosting server are cut down. This has a very desirable side-effect of cutting down on the ‘refresh’s’ the user experiences on his browser. The web application begins to feel and behave a lot like the desktop application.

How would you say this affects the wireless space? The frugal use of bandwidth is a very valid motivation for WML-based applications to follow a similar architecture.

WML Scripting

Has anyone heard of a Wiclet?

Jon Udell – Google Maps pushes the envelope. Click article
But wait, there�s more. If you append the term �output=xml� to any Google Maps URL, the server will send back an XML packet. APIs? We don�t need no stinking APIs. In 20 minutes I was able to build a proof-of-concept app — made from snippets of HTML, JavaScript, and XSLT — that accepts city names or ZIP codes and displays information about local businesses. (Unfortunately, the XML feature has since been disabled.)

Try Google suggest!

Migrants’ woes in Dubai worker camps

More people ought to know about this:

[BBC] Original Article

This portion I found particularly horrific:
Regis Johns is the manager of the company that brought Venkatesan and his colleagues from India. I asked him why the salaries had not been paid.

“Our company has gone through certain financial crises for the past one and a half years,” he says. “We said we’d definitely pay them. In fact, we offered them two months’ salary the day before yesterday.”

Mr Johns admits the company holds all its employees’ passports – a common practice in the UAE even though it is illegal.

It is also illegal for workers to strike, which means the employees of Mr Johns’ company are being asked to work without pay and without the documents to return home.

But Mr Johns rejects any notion that this amounts to slave labour.

“We’re against any kind of slavery system here,” he says.

“I can show you the document they signed before coming here, which states the hourly rate, the terms and conditions of the systems out here. They willingly sign this – and only then do we process their visas to come.”

Mr Johns denied the company kept employees in the country against their will and said it was working hard to find the money for the missing salaries.

An unchanging Chinese currency

By the end of 2005, the Rupee (INR) could trade for as little as Rs 35 per U.S. Dollar.

China’s undervalued Yuan…

China’s Yuan – how it hits India

The G7 nations make it sound as though an undervalued Yuan is the only cause for all the woes of their economies. But, as we read on, we see that though it may not be the only cause all their woes, it definitely is a big one.

China has been riding the big waves of growth at an envious 9 per cent plus rate of growth in the last two decades. It is all set to become an economic superpower in the years to come.

The world markets are flooded with China manufactured products, boosting the manufacturing industry in China, hence exports. One reason for this growth in exports has also been the pegged currency of China. China pegged its currency to the dollar in 1994, at 8.24 yuans per dollar.

Analysts claim that now the yuan is as much as 40 per cent undervalued. While the dollar continues to weaken, the Chinese exporters are taking advantage of the peg and growing by leaps and bounds.

On the other hand, the other G7 countries are facing the brunt of the depreciating dollar, making their exports expensive. Adding to the misery is the realisation that poorer countries like China and India are financing their ever-increasing current account deficits.

Stephanie adds: China has actually bought up most of the US debt. In theory, if China pays off enough of it, it can literally control the whole US economy by charging ridiculous interest rates on loans we have been given. In order to slow this from happening, Chinese currency is undervalued. The US is in danger of losing its status of a “first world nation” while we continue to spend $ in order to drop bombs on Iraq, racking upi even more of a debt. Canada is beginning to sound better & better I tell you.

Java Tip: Replacing Booleans

This is an obvious one. However, the ease of using booleans might mislead some into using many Booleans in the signature of a method. A better idea is to combine the Booleans into a Service mask.

An obvious disadvantage is the necessary marshalling/unmarshalling and the more complex error checking. Is the smaller, compact signature worth the extra effort?

Blogging about your work

News recently broke that a Google employee – Mark Jen, was fired for his blogs about life in Google. Mark was only a month old employee at Google. Anyhow, most tech Bloggers who got wind of the story are posting facts on the case. The story also made its way to Slashdot where the community took jabs at Mark. It is obvious that if your like the other bloggers out there who comment publicly about their work/workplace, you had better be careful.

Whats wierd is that Mark blogs on as if he is still at Google.

To quote Scobleizer:
Really, the policy is: don’t piss off your boss. We put a positive spin on it and call it “be smart.”

Reading Mark’s blog I can see a variety of mistakes he made. When you start at a new company you need to build a relationship network before you start discussing the company in public. You need to understand what the various forces that have power (and, at every company there are probably people who have more power than you do — even the CEO has to listen to the board of directors and to other people inside the company) and you have to work carefully and deliberately.

Links
Microsoft geek blogger Scoble
Jeremy Zawodny about blogging at work
Google bloggers
Blogscoped: Mark Jen fired
Google Blogger has left the building

NIO sockets enter CLOSE_WAIT and remain there

Under conditions of load, I caused a service to create a number of socket connections and leave them in a TCP CLOSE_WAIT state. While I was investigating the problem, I found that a certain bug with the NIO implementation maybe related to this problem and might thus explain the symptoms. However, one must keep in mind that a different problem might also result in similar symptoms. I will add more as I investigate further.

Resources
Java Forums: Taming the NIO Circus
Java Forums: select() does not block
Too many open files pattern
Java bug database: Blocking selector stops blocking temporarily