Category: thoughts

laws, laws, laws

What drives the social networks in a technical sense (I heard this in one of the IT Conversations I think):

  • Metcalfe’s law
  • Moore’s law
  • Maslow’s pyramid
  • Do you know them all? It is an interesting mind game to see how they all interact…

    Java and the Client, will they ever be happy?

    In a recent interview (well, that’s a big word, I was asked a question about Java…) I mentioned that there is still a future for Java on the Client. But is there?

    There are so many Rich Internet Application frameworks and solutions nowadays: Flex, Lazlo, Ajax-based, Silverlight, etc… it dazzles the mind. What to pick? Why learn yet another tool, configuration and/or language?

    As a Java developer, would it not be wonderful to do everything in Java. Drop the XML configuration and remoting. No JSPs or inside-out HTML, tags with HTML, Javascript, XHTML, CSS, and what not…

    And I was amazed with the requirements of web applications: master-detail updates, dynamic drop downs, complex grids with excel behaviour, drag and drop, tabs… and all the roundtrips that are needed to get things done. We’ve come a long way now (see Google apps), but I think there is still something to be said for plain old Java GUI’s.

    That was the entry point for a little project that I wrote. I’ve tagged it the “290% Java project” (stole that from the Oracle statement of a couple of years ago: “300% Java…”): Java in the Data layer, the Application Server layer and the Client layer.

    How to accomplish this? Create a Swing or RCP “lite weight” client. Make this available via Java Web Start. Communicate simple POJOs via the Burlap and/or Hessian protocol, using a Servlet in Tomcat Server. Also use those protocols to store the data on disk (no database!). The remote server calls are defined by a clean Java interface. To create a Swing UI use a tool such as JFormDesigner (I hear good things of Matisse nowadays).

    The client app runs both on Windows and the Mac, using Java 5 or 6.

    This app is now being used for almost 2 years in a row, daily, both at home and at the workplace by around 10 people. It is like a bulletin board for a group, that is closed. Everybody in the group can read all messages, but you can specify who the message is intended for. Furthermore, it shows you directly if the message has been read by all that it is intended for (a feature that I did not come acros in email or other bulletin boards), and when it was read.

    It was such a pleasure to create a UI in Java after all the struggles in the Browser world.

    I presented this approach to a group of Java developers. I was surprised to learn that there is fear to start using this “all Java architecture” approach. The reasons being that there skills to program Swing or RCP are hard to find, JSP and JSF programmers are much easier to find. (Is this true?) Also, Swing seems to be considered hard to do and still has a reputation of being slow. Well… look at NetBeans; great job for a Swing ui! I just love the MVC model of it.

    Some other points:

  • Rolling out a new version of the app is as simple as installing a new server side app: just put the news jars on a central site and Java Web Start will automatically get that new version when users open the application.
  • You can make a shortcut from the desktop to a JWS program.
  • You can use the same POJO model for your data on the server and on the client.
  • The model can be effectively cached in the client app. You can make it smart. In my proof of concept there is a version check of the model on the server. If it has not been changed, there is no need to refetch it. If it has changes (e.g. new or updated messages), only send the delta.
  • You can make use of third party jars on the client machine. For instance to generate PDF docs on the fly using iText. This relieves the server of a lot of memory and processor consumption.
  • You can make truely amazing interfaces using Java 2D, Java 3D, jGoodies, and maybe even JavaFX (there is a JavaFX demo on the Hessian RIA page, I discovered recently!)
  • You can use peer-to-peer architectures to communicate via clients directly (a la Azureus :-) )
  • There are some things to be aware of, or “some interesting issues”:

  • How to deal with security and authorisation.
  • How to secure your data over the line. Note that I used https for all communication. It even works behind corporate firewalls!
  • You need to sign all jars to make communication available, or file system access. Not a big deal with a few lines of ant script.
  • You also need to sign with a trusted certificate, so you will not get annoying popups during the app startup. These are quite expensive for a proof of concept (couple of hunderds of Euros). Although you can use a free Thawte personal certificate that is intended for e-mail.
  • There are some caching issues with JWS. Workaround that by putting version numbers in the jnlp filename or url.
  • What about using a very lite weight jump start client, based on Rich Client Platform of eclipse? You would only need Java Web Start for that little client. And then you can use the OSGi plugin model to dynamically load your app (or portal like app!) with the already present upgrade feature in eclipse.
  • All in all, I really like this concept. Who dares to make the jump??? I think it is really suited for intranet apps that have complex GUI requirements, and need to be very responsive…

    Let me know!

    Thoughts on Proximity Information

    More and more phones, laptops and other devices that you can carry around have bluetooth and/or wifi capabilities.

    This opens up interesting use of local wifi sites. In London center area there is free wifi internet access. Every 5 minutes an advertisement shows and the bandwidth is limited. You can also pay and subscribe to the service. That disables the advertisements and provides more bandwidth.

    When I visited the Westminster area I had access to a freely available wifi connection. Unfortunately, the connection did not let me get online.

    Instead it supplied a couple of web pages with local information: car park information and prices, a list of public buildings in the vicinity, local museums opening times,… Very clever…

    An interesting concept: the wifi channel acts like a local information and advertisement bulletin board.

    This can be done anywhere: proximity information! Think of music festivals that show the latest news and actual schedules. Or conferences that show background information for visitors.

    Local contacts: when you walk into a hotel you automatically are assigned some phone numbers in your phone for room service and complaints. These are removed when you leave the building.

    Bluetooth matching: State your interests with a bluetooth list on a trade fair. It will make your phone buzz when you walk past a stand that matches one or more of your interests… what is the progress there? I have heard of bluetooth dating on the streets this way, called toothing. Or was it a hoax?

    Anyway, now that I have a wifi enabled phone, every now and again I scan the available networks wherever I am. And the shear number of them surprises me. It is a pity that a lot of them are not or public use. (And I love the names that some people think of for their wireless networks…)

    Whatever happened to that project I was mailed about two years ago: get a wireless modem for 5 bugs. That was cheap! The deal was that you had to share your connection with everybody.

    To make it useable and safe, it actually provided two wifi channels: one private for your local network, and one public. Now that wifi phones are available, this makes so much more sense!!!

    update 9 april 2008: Recently I was at a pop concert in a big hall, and being surrounded by all these people I thought to check the bluetooth phones around me. And I was surprised to see so many devices listed! Half of the time it was ust the phone name, but the other half were names of the owners: “Suusje”, “Peter Br”, … So with bluetooth you can actually spot who is around you…

    Many Eyes, Many Perspectives

    A while ago I was pleasantly surprised to hear about a project called “Many Eyes” that is hosted (and sponsored?) by IBM alphaware. That project was featured on IT Conversations. Not only the title of the project, but also the goal, reminded me a lot of the article that I got published during the last year of my Software Engineering study. The article was called “So many users, so many perspectives, sharing glasses and throwing remote controls”. It was about visualizing (dynamic) datasets and sharing the visualisations (using the glasses metaphor) with other online users, to aid collaboration between them.

    The Many Eyes project does something similar: upload a (static) dataset (a text, or excel sheet, …) and choose a kind of graph to analyse the data. Then you can share this graph with others, publish it, and discuss it online.

    The similarities in name and goal struck me…

    I wonder if you can hook up some cloud processing on big datasets and then presenting the results with Many Eyes…

    Resources:

  • Many Eyes
  • So Many Users, So Many Perspectives article
  • the Many Eyes talk