vendredi 25 septembre 2009

Veille technologique semaine 39

Pour le bulletin de la semaine 39, je vous propose les articles suivants :
  • le standard WebGL qui est en cours d'implémentation dans FireFox.
  • L'historique du HTML : de la version 1 à la version 5.
  • Google qui propose un plugin IE qui apporte HTML 5 à IE.
  • Compte rendu de la soirée du club Java de Paris au sujet des outils relatif à la qualité du logiciel.
  • Toujours Google qui propose son nouveau langage Noop pour la JVM.
  • La modularité en Java : vers le JDK 7.
  • Un article sur les principes de conception avancés : déjà diffusé mais à rediffuser.
  • Pourquoi la conception des API est importante ?
  • La programmation en scala : il faut l'utiliser pour apprendre.
  • Le mot final sur le mot final de Java
  • Quelques principes sur la programmation concurrente en Java.


Bonne lecture


Après WebKit, WebGL monte à bord de Firefox
La version 3.7 de Firefox - encore en développement - contient désormais les ressources nécessaires au fonctionnement de WebGL. Ce standard permettra aux développeurs JavaScript - qui n'est pas le langage le moins répandu - de réaliser des contenus 3D via OpenGL ES 2.0, lequel s'appuie sur les possibilités de calcul de la carte graphique de l'ordinateur. Le tout sans que le navigateur web ait besoin d'un quelconque plug-in spécialisé.

WebGL est également apparu il y a quelques jours dans les versions de développement de WebKit, le moteur de Safari et de Chrome. Un développeur avait montré quelques réalisations sommaires tournant dans le navigateur d'Apple.

Vladimir Vukićević, le développeur chez Mozilla qui a réalisé l'intégration de WebGL
promet de livrer quelques exemples prochainement. Il voit aussi poindre de temporaires problèmes d'interopérabilité alors que chacun intègre webGL dans son navigateur. Mais d'autres questions plus compliquées vont se poser comme celle du fonctionnement de WebGL sur des plateformes où OpenGL est absent en standard. Exemple avec Windows où il faudra probablement s'appuyer sur Direct3D si les librairies OpenGL ne sont pas installées.


Why HTML 5: a web history
Critics have complained that HTML 5 won't be finalized until 2012, and that its completion might be irrelevant anyway because Microsoft is unlikely to ever support the new standard within Internet Explorer. Others wonder if the world really needs any changes to the language underlying the web. In reality however, many features of HTML 5 are already in widespread use. Microsoft has opened up official participation on the HTML 5 standard, indicating serious interest in working with Google, Apple, Mozilla and other companies backing the specification.


Running HTML 5 Inside IE with Google Chrome Frame
Google has just released an Internet Explorer plug-in called Google Chrome Frame that enables Chrome rendering inside IE. That means that any page targeted for Chrome Frame will be rendered using Google's rendering engine, including HTML 5 elements supported by Google, while the page is viewed with Microsoft's Internet Explorer.
Google Chrome Frame is an open source project that prepares the way for Wave. Wave is going to use HTML 5 features, but Wave is not going to be largely adopted if Internet Explorer is not supporting HTML 5. The workaround for Google was to create a plug-in for Internet Explorer that completely bypasses IE's rendering engine. Not only pages load faster in IE that way, but all HTML 5 elements that Google supports work fine in IE.


Google sneaks WebKit HTML 5 support into Internet Explorer
Rather than waiting for Microsoft to implement HTML 5, Google has
released a plugin for Internet Explorer 8 that injects its own WebKit
rendering engine, resulting in a ten fold performance boost for
JavaScript.


Compte-rendu de la soirée Qualité du Logiciel au Paris JUG, le 15 septembre 2009
Début de la nouvelle saison du Paris JUG ce mardi 15 septembre avec une soirée sur la qualité du logiciel. La soirée était divisée en 4 sessions de 30 minutes. Après une présentation de la démarche qualité et des différents types d'outils open-sources, nous avons eu 3 présentations sur Sonar, SonarJ et Squale. Une superbe soirée avec 200 personnes dans une salle comble.


Google lance son langage Noop pour la JVM
Lors du JVM Language Summit de la semaine dernière, Google a présenté
son nouveau langage pour la JVM appelé Noop. LeWiki du projet et sa
présentation permettent de faire le tour des spécificités de ce
langage :

• Syntaxe prévue pour être facilement compréhensible par un développeur Java ou C++
• Pas de types primitifs, pas de classes ou méthodes statiques,
variables non mutables par défaut, pas de syntaxe optionnelle, exceptions uniquement de type unchecked
• Librairie standard s'appuyant sur JodaTime, util.concurrent et Google Collections
• Support natif du concept d'injection de dépendances offert par Guice ou PicoContainer, un type est alors soit newable soitinjectable
• Support natif des tests unitaires qui ont leur structure dédiée sans classes ni méthodes


Les réactions qui ont suivies cette annonce montrent en général un
intérêt couplé à une réserve légitime due à l'état embryonnaire du
projet. Ainsi l'analyse de Dominique de Vito s'inscrit dans ce schéma,
tandis qu'Alexis Moussine-Pouchkine, Sun, explique à 01net qu'il
trouve enrichissant la profusion de nouvelles idées mais que, selon
lui, le langage Java restera malgré tout omniprésent pendant encore
des années.

Reste que là où de nombreux nouveaux langages justifient leur
existence par une syntaxe plus compacte, une nature dynamique ou
encore des concepts élaborés, Noop semble adopter une approche plus
pragmatique et plus proche des besoins quotidiens rencontrés en
informatique de gestion. L'avenir nous dira si les apports de ce
langage sont suffisants pour convaincre des équipes de le préférer à
Java pour leurs développements.



Google travaille sur un nouveau langage
avec pour objectif de gommer les imperfections de java.
Ce nouveau langage aura trois modes d'exécution de fonctionnement : génération de java, interprétation ou compilation.

Pour Alexis Moussine-Pouchkine, architecte Java chez Sun, Noop est une
bonne idée : « Le langage Java n'est pas parfait. La profusion de
langages alternatifs sur la JVM (Groovy, JRuby, Python, Scala, Clojure
et d'autres) en est la meilleure démonstration, et que Noop fonctionne
également au-dessus de la JVM est une excellente chose. Que le
meilleur de ces langages gagne ! En revanche, il ne faut pas tomber
dans l'excès de critique envers Java, qui restera vraisemblablement
par sa lisibilité, par son ubiquité et par son accessibilité au plus
grand nombre, la colonne vertébrale des applications de gestion en
entreprise pendant encore de nombreuses années. »


Google veut moderniser Java avec Noop
Google dévoile un nouveau langage qui reprend le meilleur de Java tout en
introduisant les bonnes pratiques actuelles : injection de dépendance, testabilité...


What is Noop?
Noop (pronounced noh-awp, like the machine instruction) is a new language experiment that attempts to blend the best lessons of languages old and new, while syntactically encouraging what we believe to be good coding practices and discouraging the worst offenses. Noop is initially targeted to run on the Java Virtual Machine. Right now, we are in an early design and development phase. You can't code anything interesting in Noop yet.


Reviewing Noop language from Google,
post-Java but still JVM-based Noop has been recently presented at JVM Language
Summit 2009. Noop development is on-going, the site is here with discussed features. The presentation gives details about development orientation.


Why another language?



Modular Java: What Is It?
Over the last few years, modularity for Java has been an active discussion topic. From the (now defunct) JSR 277 to the recognition of JSR 291 and the ongoing JSR 294, modularity is seen as a necessary step in Java's evolution. Even future JVM-based languages like Scala are considering modularity. This article, the first in a multi-part series on Modular Java, discusses what modularity means, and why you should care.


Principes avancés de conception objet
En matière de développement logiciel, on constate aujourd'hui que la conception reste principalement une affaire de style personnel et d'expérience :

• Les principes de base de l'objet que sont l'encapsulation, l'héritage et le polymorphisme ne suffisent pas à guider la conception au quotidien.
• Les Design Patterns définissent des référentiels de plus haut niveau, mais ils ne forment pas un tout suffisamment cohérent pour guider clairement la construction de designs complets.

Il existe pourtant des principes extrêmement utiles en matière de conception. Ces principes ont été définis par des "hommes de l'art" tels que Bertrand Meyer et Robert C. Martin. Ils ont été présentés par Robert C. Martin dans une série d'articles parus dans C++ Report (accessibles dans la section "Publications / Articles" du site d'Object Mentor). Ce dossier présente à la fois une synthèse et une discussion de ces principes.


API Design Matter
Why changing APIs might become a criminal offense


Programming in Scala
It's time to write some Scala code. Before we start on the in-depth Scala
tutorial, we put in two chapters that will give you the big picture of Scala,
and most importantly, get you writing code. We encourage you to actually
try out all the code examples presented in this chapter and the next as you
go. The best way to start learning Scala is to program in it.


The Final Word On the final Keyword
Some features of the Java language simply cannot be ignored. Consider for example interfaces, used extensively by every Java specification; or try/catch blocks, that form the basis for exception handling. Other features are more obscure – useful, but ignored by the masses. Without looking as far as volatile (probably the most obscure Java keyword), think about final. When was the last time you used final in your code?


Some Java Concurrency Tips
  • Prefer immutable objects/data
  • Hold Locks for as short a time as possible
  • Prefer executors and tasks to threads
  • Prefer Concurrency utilities to wait and notify
  • Producer Consumer Pattern
  • Synchronizers
  • Multithreaded Lazy Initialization is tricky
  • Prefer Normal initialization

vendredi 18 septembre 2009

Veille technologique semaine 38

Pour le bulletin de la semaine 38, je vous propose les articles suivants :
  • Sortie des spécifications 4.2 de la plateforme OSGi : avec les services remote, ....
  • Première implémentation de la norme WebGL dans WebKit : le 3D natif en HTML 5. La vidéo est à voir : http://www.youtube.com/watch?v=2rpKpj6ZO9w&hd=1
  • Un résumé des transactions mémoire : c'est un concept qui commence à ce démocratiser, les articles et les implémentations commence à être en "prime time". C'est donc une deuxième lecture que je vous propose. A intégrer rapidement dans vos socle technique. Un zoom sur le pattern MVCC : Multi Version Concurrent Control qui permet de faire des transactions sans vérrou pour les lecteurs, mais uniquement pour les écrivanis. Le COTS JBossPojoCache en version 3 utilise ce pattern très performant (plus de 10 000 transactions par seconde par instance cache ! Cela nous laisse de la marge).
  • Un bulletin spécial sur le langage de programmation Scala : c'est un langage dont le compilateur génère du byte code JVM ou DotNet, proposé comme remplacement du langage Java ? Scala le futur de Java ?
  • Le JDK 7 et les NIO : nouvel accès au système de fichier.
  • Le JDK 7 et une proposition de fournir une implémentation par défaut des méthodes de la classe Object. Il serait grand temps !

OSGi 4.2 released
The OSGi Alliance has just released the OSGi 4.2 specification. Although early drafts of it have been made available, this is the final release version. Some engines, like Equinox and Felix, have already begun working towards providing 4.2 compatibility with their earlier 3.5 and 2.0 releases (respectively). However, as OSGi 4.2 had not been released at the time, they couldn't claim to be OSGi 4.2 compliant. Now that the release has been done, it's a matter of time before the teams on each determine what still needs to be done (if anything) in order to meet the specs.


WebGL fait son apparition dans Webkit
Les dernières build de Webkit embarquent une pré-version de WebGL. Ce standard chapeauté par le consortium Khronos Group, a pour vocation d'afficher de la 3D dans une page web sans plug-in. Pilotable intégralement par JavaScript, et intégrant des liens vers OpenGL ES 2.0, il permet l'affichage de modèles 3D en tirant parti de l'accélération matérielle des machines.

Wolfire
, a publié une petite vidéo montrant ce qu'il est possible de faire avec cette technologie. Si cette dernière s'impose, elle pourrait notamment révolutionner les jeux en ligne.


What is WebGL?

WebGL is basically an initiative to bring 3D graphics into web browsers natively, without having to download any plugins. This is achieved by adding a few things to HTML5, namely, defining a JavaScript binding to OpenGL ES 2.0 and letting you draw things into a 3D context of the canvas element.

What does that mean exactly? Here's a video of the initial WebGL layout tests included in WebKit r48331. Be sure to watch them in HD!

http://www.youtube.com/watch?v=2rpKpj6ZO9w&hd=1

These demos are very simple, but they're a great start. I'm sure we'll see some complicated OpenGL scenes pop up soon, and I'm curious to see how complex they can get before FPS becomes a factor. Maybe I'll make a WebGL mini-game in some spare time!

Why is this cool?

This has a million applications - I'm obviously biased towards gaming though. Basically, imagine playing Lugaru or Black Shades instantly in your browser, on any platform, without having to install anything. In the same way Gmail is killing desktop mail applications, full-fledged 3d video games could start migrating to the web.

Flash gaming would have a serious run for its money as more advanced, standards-based, hardware-accelerated games started popping up. This would have huge implications for the entire PC gaming market, which I might explore in a separate blog post.

Of course, this utopia of browser-based OpenGL gaming will require the cooperation of all major browser vendors. When will we start to see WebGL outside of isolated, developer previews?

When can we actually use it?

This is a brand new web technology, we won't be seeing this for another 10 years right? Well, this actually has the potential to show up in browsers in the not-so-distant future. As you've seen above, this is already significantly developed in WebKit. It will take a little while before it's enabled by default in thenightly WebKit builds and longer still for Safari to adopt it, but that could theoretically be as soon as six months from now.

The same goes for Google, FireFox, and Opera, who are part of the WebGL working group. Google Chrome, of course, is based on WebKit and has pledged to support this (in addition to its own O3D, which hopefully will be standard soon as well). FireFox has an extension which enables an implementation of Canvas 3D, and Opera has supported its own (albeit different style) canvas 3D for a while.

What about Internet Explorer, which hardly supports existing standards, let alone up and coming ones? Given Microsoft's history, I wouldn't hold my breath, but there will undoubtedly be some kind of extension that simulates WebGL, like there is for the canvas element. Until then, it will be yet another awesome WebKit feature for people who are developing specifically on the WebKit platform to brag about.

It will be pretty cool when Awesomium updates to the latest WebKit and we can render 3D scenes inside of our own 3D scene!


Khronos Details WebGL Initiative to Bring Hardware-Accelerated 3D Graphics to the Internet


WebKit adding support for GPU-accelerated 3D via WebGL
WebKit developers are adding support for WebGL, a new API designed to deliver hardware accelerated 3D graphics within the web browser without the use of a separate plugin.

According to a report posted by a developer on the Wolfire Blog
, WebGL provides HTML5's Canvas with hardware accelerated 3D rendering features by adding a JavaScript binding for OpenGL ES 2.0, enabling web developers to present 3D scenes and models that tap the full native processing power of the client's graphics hardware.

The open, royalty-free WebGL specification is administered by the Khronos Group, the same organization that manages OpenGL and the new OpenCL API for cross-platform and GPU vender-neutral general purpose computing on GPU hardware.

Being able to render rich 3D content on the web without a proprietary, opaque binary runtime plugin such as Adobe Flash or Microsoft's Silverlight means that any standards-based device can be targeted by web games developers, from a desktop web browser to a mobile device like the iPhone. The technology can also be used to animate complex navigation and data visualizations.

Earlier this summer, WebKit added support for CSS 3D transforms
, which allow web developers to position page elements in a 3D space. Apple rapidly added support for that feature in iPhone 2.0 and Safari 4.0.

Support for WebGL's hardware accelerated 3D rendering is likely to be similarly exposed within desktop and mobile versions of Safari over the next few months, opening up new potential for increasingly sophisticated web apps and rich media
content. A public release of WebGL is scheduled for the first half of 2010.

Google, Mozilla, Opera and various GPU hardware vendors have joined in on the industry consensus to deliver advanced 3D web graphics using open standards, building support behind the Khronos portfolio of technology specifications.


Software Transactional Memory : STM


Overview

Writing software applications in which parts of the application run in concurrent threads introduces many challenges not present in single-threaded applications. Since the order of operations isn't fixed, failures can be difficult to repeat. Also, thoroughly testing the software requires more effort.

The goals of this article are to:

  • spread knowledge about STM
  • support reasoning about the performance characteristics of STM
  • encourage implementations of STM for many programming languages
  • provide developers with enough understanding of the Clojure STM implementation that they can develop tools to help with tuning STM usage (such as tracking the number of times a transaction retries and why it retries)
Conclusion

STM implementations are somewhat complicated. However, developing applications that use STM is less complicated and easier to get correct than using a lock-based approach. It seems likely that over time using STM will become as common and trusted as using garbage collection is today.


Multi-Version Concurrency Control (MVCC)

"MVCC uses timestamps or increasing transaction IDs to achieve serializability. MVCC ensures a transaction never has to wait for a [database] object by maintaining several versions of an object. Each version would have a write timestamp and it would let a transaction read the most recent version of an object which precedes the transaction timestamp."

"If a transaction (Ti) wants to write to an object, and if there is another transaction (Tk) (that also wants to write it), the timestamp of Ti must precede the timestamp of Tk for the object write operation to succeed. Which is to say a write cannot complete if there are outstanding transactions with an earlier timestamp."

"Every object would also have a read timestamp, and if a transaction Ti wanted to write to object P, and the timestamp of that transaction is earlier than the object's read timestamp, the transaction Ti is aborted and restarted. Otherwise, Ti creates a new version of P and sets the read/write timestamps of P to the timestamp of the transaction." (The Clojure STM implementation does not use read timestamps.)

"The obvious drawback to this system is the cost of storing multiple versions of objects [in the database]. On the other hand reads are never blocked, which can be important for workloads mostly involving reading values [from the database]. MVCC is particularly adept at implementing true snapshot isolation, something which other methods of concurrency control frequently do either incompletely or with high performance costs."

"A transaction executing under snapshot isolation appears to operate on a personal snapshot [of the database], taken at the start of the transaction. When the transaction concludes, it will successfully commit only if the values updated by the transaction have not been changed externally since the snapshot was taken."


Scala et avenir de Java
Depuis son apparition en mai 1995, juste avant l'explosion d'Internet, Java a beaucoup évolué. Il est notamment devenu une référence en matière de développement d'applications professionnelles, Web comme Desktop. Après ces 14 ans il convient de dresser un bilan sur l'adéquation de Java aux objectifs et contraintes actuelles.

On constate deux approches distinctes :
Beaucoup se focalisent sur Java 7 : les discussions font rage sur les évolutions qui pourraient composer cette nouvelle version. D'autres considèrent que Java, avec sa spécification de 600 pages, est devenu trop complexe : qu'il ne pourrait donc plus apporter de réelle révolution et qu'il faudrait donc réfléchir à son digne successeur.


Scala as the long term replacement for java/javac?
The long term replacement for javac? Certainly the dynamic languages like Ruby, Groovy, Python, JavaScript have been getting very popular the last few years - lots of folks like them.

Though my tip though for the long term replacement of javac is Scala. I'm very impressed with it! I can honestly say if someone had shown me the Programming in Scala book by by Martin Odersky, Lex Spoon & Bill Venners back in 2003 I'd probably have never created Groovy.


Is Scala really more complicated than Java?
After a conversation with a guy at work, I was inspired to take a look at whether
Scala is inherently more complex than Java, and decided it wasn't.


NIO.2 : Accès au système de fichier dans le JDK 7
Dans le cadre de la JSR 203, plus connu sous le nom de NIO.2, Java 7 va enfin être doté d'une toute nouvelle API pour l'accès au système de fichier, en remplacement de la classe File, qui malgré le fait qu'elle soit logiquement très utilisée, reste très problématique et incomplète dans de nombreux cas...
Mais que reproche-t-on à l'API de la classe File ?


JDK 7: What Frequently Rewritten Methods Should be Included in java.util.Objects?
In preparation for the arrival of a new class in JDK7 called java.util.Objects which will contain frequently-written utility methods, Joe Darcy of Sun has put out a request to the OpenJDK core-libs-dev group for ideas on what methods should be contained in this class. InfoQ would like to pass this request along to the wider Java community.

vendredi 11 septembre 2009

Veille technologique semaine 37


Pour le bulletin de cette semaine, je vous propose les sujets suivants :
  • le club Java de Paris, propose une soirée sur la qualité du logiciel : il faut s'inscrire.
  • Le langage scala : prise en charge nativement de la programmation concurrente. Introduction.
  • La compression de pointeurs des JVM 64 bits : la théorie
  • Dans les architectures Event Driven Architecture (EDA), le Complex Event Processing : CEP c'est quoi ?
  • Article d'IBM sur Java temps réel : qui est responsable du non déterminisme dans la JVM et quelles sont les solutions ?
  • Un complément sur les évolutions du JDK 7 : après les évolutions du langage, les évolutions des API avec les Java Specifications Request (JSR) prévus.
  • Le détail de la sérialization Java.

Bonne lecture.


JUG Soirée Qualité du logiciel (15/09/2009)
Mardi 15 septembre 2009
Dans les locaux de l'ISEP

19h15 à 19h30 : Accueil
19h30 à 20h00 : Les frameworks open source

Le monde Open Source Java proposent de nombreux outils d'analyse de code (PMD, CPD, FindBugs, JDepends, CKJM, JavaNCSS, Crap4J, Emma ...). Ces moulinettes produisent des dizaines de métriques (parfois cryptiques, parfois abstraites, parfois élaborées par des docteurs en informatique, barbus!!).
Basé sur ces métriques, des outils comme XRadar, Sonar, QALab vous permettent de créer de joli rapports (parfois même de beaux graphiques) que les esthètes, les clients, les architectes ou encore les chefs projet peuvent apprécier.
Mais, nous, petits artisans (ou grands industriels) du Java/JEE, devrions nous nous soucier des dépendances cycliques, de la complexité cyclomatique de notre code ? du niveau d'abstraction de nos paquets ? de la détection de tel ou tel pattern dans l'arbre syntaxique de nos objets Java ? Que devrions-nous réellement surveiller ? Quelles règles suivre ? Quels moyens pour voir ces règles comprises, acceptées et respectées ? Intervenants : Romain Pelisse, François Le Droff

20h00 à 20h30 : Sonar
Comme toute activité humaine, développer du code source nous expose en continu à la tentation de céder aux 7 péchés capitaux du développeur. Cette présentation ludique et interactive permettra aux participants de (re)découvrir ces 7 péchés et la manière de les chasser avec Sonar.
Pour rappel, Sonar est une plate-forme de qualimétrie Open Source éditée par la société SonarSource.
Intervenant : Olivier Gaudin

20h30 à 21h00 : Buffet
21h00 à 21h30 : SonarJ


Langage Scala
Scala is an object-oriented programming language for the Java Virtual Machine. In addition to being object-oriented, Scala is also a functional language, and combines the best approaches to OO and functional programming.

In Italian, Scala means a stairway, or steps—indeed, Scala lets you step up to a programming environment that incorporates some of the best recent thinking in programming language design while also letting you use all your existing Java code.

Artima is very pleased to publish the first book on Scala, written by the designer of the language, Martin Odersky. Co-authored by Lex Spoon and Bill Venners, this book takes a step-by-step tutorial approach to teaching you Scala. Starting with the fundamental elements of the language, Programming in Scala introduces functional programming from the practitioner's perspective, and describes advanced language features that can make you a better, more productive developer.


A Scalable Language
The name Scala stands for "scalable language." The language is so named because it was designed to grow with the demands of its users. You can apply Scala to a wide range of programming tasks, from writing small scripts to building large systems.

Scala is easy to get into. It runs on the standard Java platform and interoperates seamlessly with all Java libraries. It's quite a good language for writing scripts that pull together Java components. But it can apply its strengths even more when used for building large systems and frameworks of reusable components.


Compressed oops in the Hotspot JVM
What's an oop, and why should they be compressed?
An "oop", or "ordinary object pointer" in HotSpot parlance is a managed pointer to an object. It is normally the same size as a native machine pointer, which means 64 bits on an LP64 system. On an ILP32 system, there is a maximum heap size of somewhat less than 4Gb, which is not enough for many applications. On an LP64 system, though, the heap for any given run may have to be around 1.5 times as large as for the corresponding IPL32 system (assuming the run fits both modes). This is due to the expanded size of managed pointers. Memory is pretty cheap, but these days bandwidth and cache is in short supply, so significantly increasing the size of the heap just to get over the 4Gb limit is painful.


Complex Event Processing (CEP), de quoi s'agit-il?
Depuis quelques années, on assiste à l'émergence de nouvelles solutions logicielles, dont le concept à la base est loin d'être nouveau, mais dont l'offre est de plus en plus riche et perfectionnée, à savoir, Complex Event Processing. Alors de quoi s'agit-il ?


Developing with real-time Java, Part 1: Exploit real-time Java's unique features
Take advantage of real-time Java performance in your application.


JDK 7
This is the list of features being developed by Sun, and others, for JDK 7.


JDK 7 Milestones
The JDK 7 development schedule is divided into a sequence of milestone cycles,
each six to seven weeks in length. There will be no formal beta or early-access
releases, as in the past. Major features and other potentially-destabilizing changes
will targeted for integration early in a specific milestone. For more information,
please see the current draft of the JDK 7 Development Process.


The Java serialization algorithm revealed
Serialization is the process of saving an object's state to a sequence of bytes; deserialization is the process of rebuilding those bytes into a live object. The Java Serialization API provides a standard mechanism for developers to handle object serialization. In this tip, you will see how to serialize an object, and why serialization is sometimes necessary. You'll learn about the serialization algorithm used in Java, and see an example that illustrates the serialized format of an object. By the time you're done, you should have a solid knowledge of how the serialization algorithm works and what entities are serialized as part of the object at a low level.

vendredi 4 septembre 2009

Veille technologique semaine 36

Pour le bulletin de cette semaine, je vous propose les sujets suivant :
  • un concours proposé pour les développeurs JavaFX : faire une application d'ici le 30 septembre JavaFX en 30 lignes de code maximum. A vos NetBeans !
  • la liste courante des évolutions du langage Java prévues pour le JDK 7. Quand pensez vous ?
  • un article sur l'architecture logicielle à base de composants : quelle est la différence entre une architecture modulaire et une architecture à base de composants ? La séparation des préoccupations.
  • La JVM qui devient multi-langages : la plateforme Java (la JVM + les API) est plus importante que le langage Java lui-même.
  • Les cinq conseils pour faire des revues de code efficaces.
  • La JVM et son tuning : explication.
  • Les optimisations du JDK 7 : encore des améliorations de performance possible.
Bonne lecture


Starting Soon: New JFXStudio Challenge for JavaFX Developers
Josh Marinacci has announced a new JFXStudio Challenge: Small is the New Big. JavaFX developers will have from September 8 through September 30 to develop an interesting application in 30 or fewer lines of code (3000 characters maximum), all contained in a single JavaFX file.


Liste finale des évolutions du langage Java apportées par le JDK 7

En début d'année, Sun a initié le Project Coin, un sous-projet d'OpenJDK visant à recueillir les propositions d'évolutions du langage Java pour le JDK 7 prévu pour début 2010. Les soumissions ont été nombreuses et Joseph D. Darcy, leader du projet, informait régulièrement la communauté sur l'avancement du processus de sélection. C'est maintenant la liste finale des évolutionsqu'il annonce. Sauf problème de planning, il s'agit donc là de ce que le langage Java sera dans JDK 7 :

On est loin de la liste d'évolutions très audacieuses initialement prévue pour JDK 7, mais les évolutions finalement retenues ont l'avantage d'être réalistes en terme de temps d'implémentation, tout en apportant un confort supplémentaire au quotidien pour les développeurs Java.

Rémi Forax, très au fait des développements sur l'OpenJDK, propose d'ailleurs son analyse des tâches restant à accomplir et de leur complexité pour chacune des évolutions.


Final list of Project Coin changes for JDK 7
Project Coin got its name because it is about making "small change"(s) to the Java programming language for JDK 7. Sun's Joe Darcy has been leading the project. In his blog post, Project Coin: The Final Five (Or So), has announced which small changes will actually make it into JDK 7.


Project Coin: The Final Five (Or So)


Component-Based Software Engineering
the benefits of components modularity, focusing exclusively on the component based architecture software paradigm. Component's relationship to reuse and touch on how components helps ease maintenance and improve extensibility, also making the system easier to understand, maintain, and extend:

Maximizing reuse complicates use.


Java yields to other languages on the Java Virtual Machine
the JVM is becoming a polyglot platform, where developers can take advantage of different languages for different needs.

Java the platform taking more prominence than Java the language. Sun's Bray emphasizes that the Java platform is becoming more important than the language itself: "I personally think that the Java platform has more strategic importance than the Java language, going forward."



5 tips to make good code reviews
Code reviews are one of the most valuable engineering practices.
1. Code reviews improve the quality of the code through the suggestions from the code reviewer.
2. Code reviews are a great tool to indirectly teach other developers parts of the system they may have to maintain in the future.
3. Code reviews encourage people to learn best practices from other developers.
4. Code reviews can be used as a validation of the clarity and simplicity of the system.

You may have noticed that I have omitted from the list that code reviews help finding bugs and enforce coding standards and that's because:
1. Code reviews SHOULD'T be performed to find errors in the code.
2. Code reviews SHOULD'T be performed to enforce coding standards.



Java Performance Tuning, Profiling, and Memory Management
Java application performance is an abstract word until you face its real implications. It may vary depending on your interpretation of the word 'performance'. This article is meant to give the developer a perspective of the various aspects of the JVM internals, the controls and switches that can be altered to optimal effects that suit your application. There is no single size that can fits all. You need to customize to suit your application. You may be facing one of the issues listed below:

1. The dreaded java.lang.OutOfMemory Error
2. Your application is literally crawling.

Before we take the plunge into solving the issues, we first need to understand some of the theory behind the issues.


Java HotSpot Virtual Machine Performance Enhancements - JDK 7

  • Zero Based Compressed OOPS
  • Escape Analysis Improvements
  • NUMA Collector Enhancements
  • NUMA Performance Metrics