Wednesday, June 25, 2008

SEAS / DTC conference dinner

Last night was the conference dinner, and before you ask, yes I feel that today. It was held in an old church in Edinburgh called Mansfield Traquair, which is a really beautiful old building that has been refurbished into a social venue.

We started out with a "wee" glass of champagne as the Scots would say, and then were guided to our tables in the main hall of the church. The food was excellent and the wine was good, but I must say that the entertainment was not quite my cup of tea, with musical numbers between each course performed by "Stars of the West End". Mind you, they were all great performers, but I'm not very keen on all those musical songs. They even managed to mangle Queen's "We are the champions" at the end...

Fortunately, due to great company at the table by Simon Roberts and others, the evening was not a total loss. Thanks guys.

Tuesday, June 24, 2008

SEAS / DTC conference

Today and tomorrow I'm in Edinburgh for the Systems Engineering for Autonomous Systems conference. This is a conference on autonomous systems put on by the British Ministry of Defense, presenting the results of research done for mostly military purpose.

Then why am I here? The short answer is that we try to learn what we can about buiding autonomous systems in our own domain (oil and gas operations), and the research has come furthest in the military domain. We were first turned on to this conference last year by our good friends at AOS last year, and have been participating ever since. This year it is my turn.

I hope to learn as much as I can about the wast range of topics presented, ranging from architecture of autonomous systems to sensor utilization and communication.

I really think this could be relevant for our work in the coming years.

Also very interested to hear in the opening session this morning the focus on agility and agile concepts in wast research projects such as these. It is good to see that even though they talk about systems engineering, the focus of analysis and specification has been turned down in favor of capabilities and demonstration.

Monday, June 23, 2008

The beautiful city of Edinburgh

I'm here in Edinburgh for the SEAS/DTC conference (more on this later), and I must say that this is a very beautiful city. I'm especially taken by the location of the castle on the hill in the middle of the city.

I went for a walk tonight after settling in at the hotel, and got to see the sun set on the parapets of the castle. Very beautiful indeed. You should definitely come here if you get the chance.

Saturday, May 24, 2008

ScalaLiftOff

This has been a most excellent day. Just being in the company of so many great developers is inspiring. If you have a look at the list of participants at the site, you'll understand what I mean. Also, since this was the first community conference on Scala, I'm glad to have been present.

Martin Odersky had a couple of interesting sessions himself, in particular the one where he demonstrated the building of a fully functional spreadsheet in Scala. In fact this is the example from the upcoming book. Following this lead, David Pollack (creator of Lift), show how we could take this spreadsheet app into lift and make it web based. Very cool.

I also participated in an interesting session with Bill Venners on testing in Scala. As you know I'm bordering on obsessed on testing, so it was good to have an overview of what approaches are most common in the community.

Also we had a great discussion about what we can do about object persistence in Scala. As you may know, I'm not very happy with the state of the current tools in Java, and in particular I want to have more of a disconnect between the object layer and the persistence layer, enabling a varied choice of persistence mechanisms underneath a standard api. A number of interesting people was involved in this discussion, including Paul Snively from Lambda the ultimate.

So what did we get out of this first conference on Scala? The answer I feel is in two parts. Personally I got to learn a lot about Scala, and see who was interested in it, as I'm quite new to it. As a community, it was great to see people from so many different backgrounds getting together in support of a great new language. There were language theory guys, like the guys from LambdaTheUltimate, Ted Leung from the Python community, a bunch of guys from the Java community, and I even saw a couple of the Twitter guys there. I guess they are looking for a new paradigm to help with their scalability problems.

All in all a most excellent day. I certainly learned a lot.

Tuesday, May 13, 2008

Java SE 7 - New language features

There are a number of new features that has been proposed for future Java releases, and when the spec lead for the new Java 7 release, Alex Buckley set up this talk, I was naturally interested in finding out what had been chosen.

Alex cleverly avoided talking about many of the controversial issues, like closures or no closures, and instead focused on what is good language design and how to grow a language, as well as some of the smaller uncontested features that are almost certain to be included. All in all I thought it was a good approach, and a discusson on closures was done in other talks later in the week.

So, to the language features he presented as almost certain to be included in the next version. The first thing he mentioned was that they were adding the possibility to switch on strings. Today this is not possible (only works with enums, byte, short, char and int), and is really a nice addition to the language.

Next up was the possibility of multi-catch of exceptions. This will be very useful when you have to catch several exception and perform the same task. Today the solution would be to have repeated separate catch blocks and then call the same method for each catch block, while the new proposal allows catching multiple types in the same block.

This code:

try {...}
catch (X1 e) {foo();}
catch (X2 e) {foo();}
catch (X3 e) {foo();}

will turn into this

try {...}
catch (X1,X2 e) {foo();}
catch (X3 e) {bar();}


Connected with this, is the possibility for safe re-throw, where the catch block will now allow re-throw of the same type that was caught. For example
catch(final Throwable e)
that is really NullPointerException for instance will rethrow NullPointerException. Today, the rethrown exception will be Throwable, which is not good.

Modularity in the language is another big thing. JSR 277 proposes a module system that is included in the language to provide similar functionality to what you can get with OSGi today. A core package like com.statoil.jef.core can be a module, and introduces an accessibility level of classes and methods within a module. Will enable both package private and module private. Adding annontations for metadata like versioning of modules. The main advantage over OSGi is that it is in the languague and things like javadoc and javap will understand the module concept. It has unfortunately many disadvantages over OSGi, and the JSR 277 work is only meant as a starting point. More of the features of OSGi are planned to be included in later versions.

Then a demo was given about some of the additions to the Java annotation system. JSR-308 proposes several extensions to the annotation system ment to provide better compile-time type checking.
  1. Allow annontations in other places than declarations.
  2. Pluggable type systems, that you can define to your specific needs, plug into the compiler, and use.
The focus here is very much compile-time verification of the code, and some of this seems like a good idea, but in my experience, this problem has never been so big as to warrant this level of effort. I'm sure that there are systems out there that can benefit from this extra type checking, but to me this seems like too much for too little benefit. Makes the code more unreadable just for catching bugs that might not be there. I certainly prefer to use tools like Findbugs and unit testing instead. My main problem with the presentation was that they never mentioned these alternatives even with a single word.

Alex then rounded off the talk with a discussion about the long term evolution of Java, areas of interest and of non-interest. This is a very interesting part, since it hits at what will be considered for future versions. The main message was (as I understood it), that even if something is not included in the Java language, it doesn't mean it is not on the platform (JVM), with a reference to other languages on the JVM like Groovy, Ruby, Python, Fortress and Scala.

All in all a very enlightening talk.

Wednesday, May 07, 2008

JavaOne Day Two

The second day of JavaOne started with a refreshing jog towards the Golden Gate bridge. Thanks to Rune for dragging me out at 0630 for this, it was truly worth it.

We decided to skip the Oracle general session in favor of some breakfast, but the jog ended up making us so late, we barely made the first sessions after the general session.

I was lucky enough to get some fruit and a croissant at Moscone Center just in time to catch teh Script Bowl. This was a wonderfully exiting contest between some of the main developers of the different scripting languages that run on the Java Platform, namely Groovy, JRuby, Jython and Scala. Scala as you may know is not really a scripting language, but it can be used for this type of rapid development all the same.

The contest was divided into three rounds where the first task was to develop a twitter client as a desktop app, the second app was to create a web app, and the third was free-form development. The whole contest was judged by the audience via SMS, with the overall victory going to the JRuby guys. Way to go! Part of the reason for their success was that they had used their community to get the apps done, as well as bringing a very flashy app for the free-form round.

After this session I ended up getting Tom Enebo to sit down with me to do some development on JRuby. We couldn't really find anywhere good to sit down, and ended up sitting in one of the lounging areas with less than perfect wireless access, and thus did not get much done apart from downloading and setting up the latest JRuby trunk on my computer. I guess I'll have to get by on my own when I get home. Hopefully I'll have some time to contribute in the coming weeks. Tom (as well as the rest of the JRuby guys) is a very easygoing guy, and I enjoyed spending some time with him and the rest of the guys throughout JavaOne.

After our little coding session, we went to see Ola Bini's talk entitled JRuby on rails. It was nice for me to see how rails apps could be ran on the JVM with for instance the Glassfish server. Gives an idea of a good way to make use of JRuby.

The final session I attended was a session with Ben Galbraith and Dion Almeir on What's new in AJAX. It was a nice little history lesson in the development of JavaScript and the different frameworks based on it over the years. These two guys are a couple of masters of the art of presentations, and just for that is worth the time to show up.

After the AJAX talk I walked around the pavilion for a bit, and actually bumped into the JavaPosse guys (minus Tor), while I was talking to Pete Moore of Atlassian. They were there to talk to Pete too, so they didn't have too much time for me, but I did manage to discuss some Scala stuff with Dick and Carl. Turns out we are all going to the ScalaLiftOff unconference on Saturday.

Well that was it for the JavaOne stuff, and I joined Rune and Paul and a couple of other guys at a great steakhouse off Union Square for a big steak meal. Very nice.

Tuesday, May 06, 2008

JavaOne - Day One

Day one of JavaOne always starts with the Opening General session. This is Sun's showcase for new Java technology. This year there was a JavaFX theme. JavaFX was launched last year at JavaOne, and is supposed to be the answer to Adobe Flex and Microsoft Silverlight on the Java platform. This year they show a whole lot of apps created with JavaFX, and it was a lot of nice looking webapps. For closing, they brought out Neil Young and the announcement of his "collected works" on BlueRay disks using advanced java features.

After the general session I went to the JRuby talk. Not much new for me in the talk, since I've been following the project, but they had some very nice demos of what you can do with Ruby on the JVM.

After lunch I attended Joshua Blochs talk about More Effective Java, containing material from his second edition of the Effective Java Book. He launched a mnemonic for helping to remember when to use extends and super with generic wildcards: PECS (Producer Extends, Consumer Super) which reduces the problem to figuring out which is producing and which is consuming, and that's kind of the hard part anyway. It's a bandaid on a gushing cut. Generics are just not easy. The rest of the talk he spent on how to make effective use of enums, which was good, but didn't really seem that useful to me.

For the final session of the day I chose a session about the new Java 7 language features. There were some interesting things here that I'll make a separate post about later, but one interesting thing that they did not talk about was the closures debate. In stead the Java SE 7 spec lead Alex Buckley talked about the principles and considerations of language design, and at the end there was a long session about adding more annotation for better type safety. Like I say, I'll talk about that in another post.

After this I wandered around the pavilion for a while, looking at the different stands.

Blogging at JavaOne

I will try to put out the most of the news from JavaOne as the conference proceeds, but this is a very fast paced conference, and I must say that after the conference started today, it looks like I'm going to be very busy.

There are a lot of sessions, a lot of people, and very little wireless access, so I doubt that I'll be able to post my blog-entries until after the conference is done on Friday. Please bear with me.

Monday, May 05, 2008

CommunityOne

The week of intensive conferencing started today with the CommunityOne conference. CommunityOne is a free pre JavaOne conference organized by Sun. The conference includes several open source topics such as Linux, programming languages, NetBeans and others.

When I was going to the general session, I bumped into Tor Norbye and Dick Wall from the JavaPosse, and finally got to meet them. While we were talking, Ola Bini from the JRuby core team came by, and so I got to meet him too. This was a great start of the day.

The general session was dominated by talk about open source communities and their importance, and finally Sun launched the new OpenSolaris version with the new logo. Also the demonstration of OpenSolaris included a cool demo of the raid capabilities of ZFS (included with OpenSolaris). They had a raid with seven disks running live, and there on the stage put a sledgehammer to one of the disk, litterally turning it into a cupholder. For good measure they also kelled a second disk by putting a drillbit thorugh it. Of course the disks died, but ZFS were able to keep running and when new disks were plugged in, it also rebuilt the content. Very impressive.

After the general session I went to the NetBeans session to check out what were the new stuff in NetBeans 6.1. I have been using NetBeans 6.0 for my Ruby development, but since my experience before this has mostly been with Eclipse, it has seemed a little awkward to me. Now, this new version really seems to be a lot more polished, and I really like the fact that there is much more support for different dynamic languages like Ruby, Scala, Python and JavaScript in NetBeans. I'm definitely going to have a closer look at the new version over the next couple of days.

At lunchtime there was a quick performance by the JavaPosse, where they recorded a live podcast. It was fun to be there for the first time at a podcast that I listen to regularily these days. I really think this is a good group of guys, and they are able to gather all or at least the most important news and then discuss it in a meaningful fashion. I strongly recommend that you have a listen if you haven't already.

After lunch I wandered around a bit and got some coffee, and then it was time to listen to a panel about Ruby. What ruby is doing in a Java related conference, you say? Well, Sun hired the JRuby guys about a year and a half ago, and are now committed to getting Ruby on the Java VM, and I think there is a growing interest in dynamic languages in general and Ruby in particular in the Java community. I'm certainly one of the followers, and I believe that the JVM is a great way to run Ruby in the enterprise, getting imporoved performance and deployability. I will certainly be talking more about the benefits of JRuby later.

Sunday, May 04, 2008

Arriving for JavaOne 2008

So, I'm finally here at JavaOne 2008. I've been lucky enough to get to participate in this years conference, and I will do my best to relay my experiences to you. It was a long trip getting here. I only arrived yesterday, having spent last week in Paris on vacation with my family. I only got back home on Saturday evening, and had to unpack and repack for my trip to San Francisco.

I got to San Francisco yesterday after a gruelling 11 hour flight from Frankfurt. My flight coming in to Frankfurt was late, so several of us had to be ushered through the airport in order to make our flight, but we made it in the end. The flight was uneventful, but too long, and when we finally got to SF, and got through immigration and I got my bags, I boarded the BART train to the city center. Finding the hotel was not a problem as it is right on Union Square, smack in the middle of San Francisco, and when I got to my room, it was already ten in the evening (local time).

I went out for a little walk to clear my head and get some water, and as I returned to the hotel I ran into Rune and Paul in front of the hotel, and we agreed to meet the next day for breakfast. And with that, I was ready for bed.