practicing techie

tech oriented notes to self and lessons learned

Monthly Archives: October 2012

JavaOne 2012 – Java ME and Java Embedded

Much of my day-to-day development related work is in some way associated with Java SE and EE, so attending JavaOne provided a great opportunity to catch up on Java ME. Quite a few things have happened with Java ME, it seems.

Java in the embedded market received prime time coverage, both in the conference technical sessions, as well as in the keynotes. During the Java Strategy keynote Nandini Ramani (VP development; Java Client, ME and Card) characterized the still rapidly evolving embedded space as follows:

“Given the trends in the M2M space, as well as the “Internet of Things”, we believe that the Java embedded space is very exciting at this point in time. In the 1990s it was the internet of computers, with the PC and the web making significant advances, and in the 2000s we saw a proliferation of connectivity of people, where phones took over and everyone was connected to some gadget all the time. And now, as a third wave, we’re seeing the Internet of Things, we’re surrounded by devices, many of the so unobtrusive that you don’t even realize they’re around you all the time, like thermostat sensors, automatic controls and smart homes etc. And this explosion of devices that are connected 24/7 that tend to stay on 24/7 is the next IT revolution and Java, we believe, is the right solution for this space.

Java Embedded solutions provide a framework that not only lets you provision, manage and secure your devices, but also lets you aggregate and analyze the data that you get received. So, in this way you’re not just sending from these sensors data to the backend, but rather sending information to the backend.”

“Internet of Things” represents basically the same vision as ubiquitous computing invented 20+ years ago. Ubiquitous computing, with its vision of small Internet connected devices communicating and coordinating their activities with each other, has been a hot topic in IT on and off for the last decade or so. I remember a colleague of mine having an approximately 80 mm * 50 mm sized single-board ethernet connectable embedded device that could run Java in the early 2000s. It was a mass market device and not a prototype.

The keynote continued by describing three categories of compute devices Oracle targets in the embedded space:

“The first one are the really, really small edge devices, as I mentioned, things like thermostats and sensors, which typically are either connected directly to an backend directly through a operator network over 3g or they form part of a solution, which is in a local or personal area network, in which the gateway tends to be the hub.”

Oracle targets this device category with the Java ME Embedded, which is a runtime for small embedded devices: Microcontroller and low-power devices class platforms. Java ME Embedded is a Connected Limited Device Configuration / Information Module Profile (CLDC/IMP-NG) based Java runtime. It’s meant for headless operations i.e. it doesn’t include UI support.

“And the gateway itself is the second category device, which actually just coordinates the local network. And as the name implies, it performs the duty of being a gateway to the backend.”

This category is covered by the Java Embedded Suite: Pre-integrated full featured Java Embedded Platform. This is a small footprint optimized middleware stack, which includes Java SE Embedded (subset of Java SE optimized for mid-size headless devices), GlassFish application server (subset includes Servlet, JDBC, JAX-RS) and Java DB.

“And the backend itself is the third category of devices that you see here, which is a datacenter or a cloud.”

In this picture the backend is built on server class devices, that are able to run Java EE based middleware.

The Strategy keynote put a lot of emphasis on end-to-end solution and how the entire ME / SE / EE product spectrums form a full device to-data-center solution. There was also, a lot of talk about SE/ME convergence where the target is to reduce SE footprint to make it suitable for embedded devices. Concrete efforts towards this goal include CLDC 8 specification (JSR 360) that aims to make ME a strict subset of SE. Java SE/ME convergence is also supported by process changes where the previously separate two Java Community Process governing bodies for Java ME and SE/EE are merged into one (JSR 355). On the technical side, it’s a lot of effort is clearly being put into Project Jigsaw. Jigsaw’s purpose is to implement a module system for Java SE and apply it to the platform and JDK. This would make evolving the platform and libraries easier in the future, but also allow optimizing application memory footprint, thus enabling SE and EE applications to be run on smaller devices than today. Jigsaw is currently scheduled for Java 9, due in 2015.

At JavaOne 2011 the “Technical Keynote: Java Mobile and Embedded” session put a lot of focus on the mobile space. In the 2012 keynotes mobile devices were a mere footnote, as was the case also with the technical sessions. Looking at the sessions of Java Embedded @JavaOne sub-conference it was all about M2M, healthcare, manufacturing and industrial automation, robotics and even liquor dispensers.

I also noted an interesting piece of trivia while visiting the Oracle OpenWorld Bookstore at the conference (on 2012-09-30 in Moscone West): I counted 7 different books on Android development and quite a few on jQuery Mobile, JavaScript / HTML and HTML 5, but no books on Java ME. This is interesting given the dispute over Android’s Java compatibility.

Based on the keynotes, technical session topics and the fact that Java ME Embedded stack doesn’t support mobile phones, the mobile application platform market doesn’t seem to be a primary target for Oracle or Java ME anymore. Also, Oracle’s Java for mobile offering, the Oracle Java Wireless Client (OJWC) only appears to be targeting the feature phone segment and not smartphones.

Focusing on the embedded, and not the mobile space seems only natural given the current market realities: according to IDC 2012 second quarter smartphone platform market share, Java ME enabled phones (BlackBerry OS, Symbian) have approximately 9% market share of phones sold. Both BlackBerry and Symbian have been losing market share rapidly, and probably with little chance of the other top platforms (Android, iOS, WP) adopting Java ME, ME will likely be losing ground.

But what exactly is Oracle’s mobile strategy? They don’t currently appear to have any mobile application platform or runtime products covering the high-end smartphones. JavaFX was previously targeting also mobile devices, and Oracle even demoed JavaFX on iOS and Android tablets at JavaOne 2011. Now, JavaFX seems to be only for desktop (with ARM support in the works).

Oracle introduced Project Avatar at JavaOne last year, which was described in this year’s technical session as follows:

“Avatar is a modular, end-to-end web development framework for building enterprise mobile and desktop applications using JavaScript, HTML5 and a thin-server architecture.”

There’s also a related project called Project Easel, which provides the foundation for tooling support for project Avatar. Easel provides advanced tooling in NetBeans for HTML 5 projects. The tooling includes among other things static web resource synchronization between NetBeans and the browser, JavaScript debugging, improved HTML 5, CSS and JavaScript editing support (documentation, code completion, navigation etc.) and is available in NetBeans 7.3 beta. The browser plugin lets the developer easily adjust the screen size to various pre-defined sizes, including common smartphone screen sizes. These are nice features, but arguably, not radically better than the tools currently used by web frontend developers (e.g. FireBug etc.).

So, Oracle, like many others in the industry, seems to be betting on the browser becoming the application runtime environment also in the mobile space, as has already happened on the desktop. Avatar/Easel provide just the basic plumbing, but a technology such as Apache Cordova (previously PhoneGap) could additionally be used to achieve native application like capabilities.

References

JavaOne 2012 – on picking sessions and other practicalities

To make your attendance succeed and ensure efficient use of your time, you need to think about quite a few practicalities in advance when attending a large conference, such as the JavaOne. This can take up a surprising amount of time and effort that you should account for.  The practicalities you need to think of include travel arrangements, accommodation but also picking the sessions to attend.

With many parallel sessions, choosing between them can be tricky and sometimes prioritization is not easy. For instance during JavaOne there’re multiple conferences being held, such as Oracle OpenWorld and MySQL Connect, which all have interesting sessions. Here’re some numbers for JavaOne:

  • nearly 500 sessions total
  • as much as 18 parallel sessions during peak hours
  • over 150 sessions on peak days

So, picking your sessions can be challenging. Possible selection strategies may include:

  • short vs. long term benefit – learn about things you know you need now or things you think may be useful in the future
  • trend spotting – try to learn what’s in and what’s out. Which technologies people are using, for what kinds of problems and domains, and which solutions are yesterday’s news.
  • what’s available – sometimes there aren’t any interesting session at a given time or the interesting ones may have filled up
  • semi-random – you can’t really predict if a session will be useful to you in advance just based on the author, title and abstract. Occasionally, some exploratory selection may be a good thing
  • technology vs. case studies – learning about solutions or hear about how to apply them in a given domain

Typically, you may want to hedge your bets and use a combination of different selection strategies.

The most popular session may fill up quickly, so you may need to register in advance for them. So, go through the session catalog and sign up for the ones that interest you the most as soon as possible to ensure access. Often, you can still get in to full sessions, but it’s not guaranteed, and especially for the “hands-on lab” session types availability may really be limited.

For many presentations there’s some kind of sales message to be read somewhere between the lines. The presenter may want to sell you products, services and/or adopt a particular view of the world. Depending on your situation, and how pronounced the selling viewpoint is, the session may still include information that you can use. For example, if you’re shopping for products or services this can be a good thing. But, if you’re planning on building something yourself, you may not be getting much out of the session.

Some presentations can also be viewed later, even if you  couldn’t attend, for example due to another concurrently running session. Cool, flashy presentations can be very entertaining, but also problematic in this respect, and you may not get too much out of them just by looking at the slides later on. And even if you attended the session you might not want to skip taking your own notes.

I’ve felt that my time is best spent on getting short intros on new technologies, trend spotting, case studies and talking to people. For actually learning to master a particular technology, you can always take some time to read and try it out in practice. Or even go on a course, read a book or get hold of a colleague that has experience in the subject. So, I don’t usually attend multiple sessions on a given subject. Focusing on a single larger theme from different perspectives can be very useful, though.

But, conferences aren’t just for one-way communication, they’re great for dialogue: connecting with other attendees and discussing about technologies, in what kind of context and problem to use them, how to use them etc. Think, question and discuss. You may be the world’s best expert on matters relating to your exact problem setting!

In my opinion, one of the greatest things about conferences is, that they provide an excellent opportunity to think different and step outside of your routine work. They give you a chance to look at the problems and solutions you’re facing in your day-to-day work in an entirely different setting. Ideally this allows you to really think outside-the-box, which can have a great impact on your work.

Other important practicalities include gadget power usage. If you’re using a laptop, mobile phone or a tablet for taking notes or other things during sessions, make sure you know your battery capacity. Learning how to save battery power can also be useful, as well as locating places where you can recharge your battery. Don’t miss any recharging opportunity.

The JavaOne and the other Oracle conferences taking place at the same time are huge. The streets sometimes get really crowded with conference attendees. I don’t know how accurate this is, but an Oracle president said there were in the order of 60,000 attendees. This means that getting accommodation that meets your quality, cost and location expectations can be difficult, unless you book early. Two months in advance may not be early enough, make arrangements as early as you can. JavaOne 2012 is over today, so if you want to attend next year, start making your preparations 🙂