background preloader

Osgi

Facebook Twitter

Turmoil Driven Development: OSGi With Scala, Java, Groovy, Maven. In this first installment, I'm going to attempt to walk you through the setup of an OSGi project that is comprised of three OSGi bundles; one for Java, one for Groovy and one for Scala. In an effort to keep it simple, I'm going to employ a trivial hello world example in each bundle. The emphasis of this post is to introduce some concepts and illustrate how to get an environment up and running.

I'm going to leverage maven and the extremely useful PAX maven plugin to automate much of the grunt setup work, packaging and runtime management. In subsequent posts, I'll show how we can leverage Spring DM to eliminate the OSGi API from our code and I'll show how to get these bundles to actually interact with each other. I think that OSGi has an enormous amount of potential. There are many high profile commercial and open source projects that make exceptional use of the framework already. If you'd prefer to look at the code as you go, you can grab it from bitbucket. 3.cd helloworld Java That's it. A Dozen OSGi Myths and Misconceptions. We Recommend These Resources Anybody who knows me or has been following me lately knows that I have an interest in OSGi. And I'm not alone--there has a lot of buzz about OSGi in the past few years. But as I talk about OSGi with other developers, I often hear them say things about OSGi that simply aren't true.

It's not their fault, though. Unfortunately, there's a lot of misinformation and misconceptions about OSGi out there. It's hard to sort out the good information from the bad. And more often than not, it's the bad information that sticks with people. There's no perfect technology and OSGi isn't going to be nominated as the first one. OSGi is too complex I've been told that OSGi is too complex because it requires rigorous management of the META-INF/MANIFEST.MF file (you know...that file that's in every JAR file...the on you never look at). Bundle-SymbolicName is used to identify a bundle (the unit of modularization in OSGi) to an OSGi framework. Export one or more packages. 08. 12. Creating an application with dm Server. Copyright 2009, SpringSource. Licensed Under the Apache License, Version 2.0 (the “License”); you may not use this file except in compliance with the License. You may obtain a copy of the License at .

Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an “AS IS” BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License. Trademarks. SpringSource and dm Server are trademarks or registered trademarks of SpringSource, Inc. Java, Sun, and Sun Microsystems are trademarks or registered trademarks of Sun Microsystems, Inc. in the United States and other countries. OSGi is a trademark or a registered trademark of the OSGi Alliance in the United States, other countries, or both. Eclipse is a trademark of Eclipse Foundation, Inc. UNIX is a registered trademark of The Open Group.

Modularizing existing web applications with OSGi. OSGi modularization on the server side is well embraced by vendors (Spring DM Server et. al.). OSGi provides "true modules". With OSGi, we can keep together everything that belongs together. For web applications, that means we can deploy code, resources, JSPs etc all together in a bundle. Today you can write a new web application and just run it with Equinox/Jetty or Felix http services. However, what if you need to keep evolving an existing web application and can't just stop and spend months rewriting everything to OSGi architecture?

This article explores how you can build on an existing webapp and adopt OSGi for web components without first having to rewrite the whole application. An example is provided using Tomcat 6 and Equinox. The author of this article Wolfgang Gehner is co-author of the book "Struts Best Practices" published in German and French. This article was reviewed by Kirk Knoernschild and John Wilson. Introduction Run the example 1. 2. 3. [Image 1: Browser output] Summary. Glassfish And OSGI Part I : A Look Into Glassfish V3 Development. We Recommend These Resources The Glassfish V3 Architecture adopted the Felix OSGI Runtime as a microcontainer.

In a series of articles, I will look into the “Glassfish and OSGI”. The aim of this is to research how to adopt OSGI as an application server’s microcontainer. As a middleware developer,firstly, I pay more attention to the building of development environments. In this article, I will show how to use Eclipse 3.4 as your Glassfish V3 Development Platform based on my experience. Preparing Tools Related To V3 Building and Development J2SE 6Download J2SE 6 From , and set the JAVA_HOME and system path environment variables.

Check out Glassfish V3 SRC Open the command shell, or use the Tortoise SVN Graphical Tool, to execute the following command: svn checkout Generating V3 Project File of the Eclipse IDE mvn -DdownloadSources=true eclipse:eclipse 02. 04. 05. 06. 07. 08. 10. 12. 13. 18. 19. 20. Migrating From Spring dm Server. We Recommend These Resources The easiest way to develop Spring-powered OSGi applications is to use SpringSource Tools (Eclipse plug-in) and SpringSource dm Server combo. They allow rapid development such as MANIFEST.MF validation, convenient deployment and automatic downloading of required (and OSGi-fied) libraries. Later on, when you need to migrate to plain OSGi (just like I do), you can follow this tutorial series.

A month ago I started development of an application with SpringSource dm Server (ssdms). In the middle of the project, concerns arose to deploy it in "plain" OSGi container (namely Equinox). The migration was rocky, so I decided to blog it for the sake of sharing. First I downloaded the bare bone "Framework" from Eclipse. The framework is a < 1MB jar runnable with "java -jar JARNAME.JAR -console". Note for Mac users: Since it's the same launcher used in Eclipse IDE, it doesn't work in Java 6 64-bit. Verify the framework by running it. 3.Framework is launched. 1. 2. 3. 4. A Recap on OSGi - Why and How? Over the past several months, I’ve written quite a few blog entries about OSGi. Here’s a recap of those entries. If you’re not familar with OSGi, the posts under How OSGi might be of interest. If you’re familar with OSGi, but aren’t clear how it can help, the posts under Why OSGi will be of interest.

And if you want to get a sense for where OSGi stands in the market today, the posts under OSGi Market may peak your fancy. Why OSGi Here are some posts that describe the motivating factors behind OSGi. Rotting Design - Discusses how a system’s design tends to rot as change occurs, and what we can do about it. How OSGi Here are some posts describing how to use OSGi. Simple OSGi Service - The simplest OSGi service just to show the basics of OSGi. OSGi Market Here are some posts on the OSGi market. OSGi Survey Results - An OSGi survey I conducted back in 2008 with some fairly interesting results. Late last year, I also published an in-depth research overview on OSGi.

Le Touilleur Express » Petit compte rendu de la soirée JBoss au. Ce soir le dieu de l’informatique, le pigeon magique du JUG, le Duke ultime golden-platinum qui refait venir l’être aimé étaient tous aux abonnés absents. Panne de vidéo projecteur, panne de micro (c’est une contrepèterie) et donc bilan mitigé. En première partie, Sacha Labourey le CTO de JBoss, une division de RedHat effectue une présentation sur JBoss AS 5.0. En deuxième partie, présentation de JBoss Seam par Malik Saheb. Le tout devant 200 personnes, la salle étant comble comme la fois précédente.

Sacha Labourey présente d’abord un petit historique de JBoss Application Server. A ses débuts en 2000 la volonté des développeurs est de proposer un serveur d’app plus léger, avec la possibilité de recharger à chaud une application sans relancer le serveur. Sacha enchaîne ensuite avec une justification sur la prochaine version de JBoss, JBoss AS5. L’un des objectifs de JBoss Application Server 5 est de s’affranchir du kernel basé sur JMX.

Quand sort JBoss AS 5 GA ? OSGI ? Donc stay tuned.