Spring and Scala
Scala is an interesting language that appeals to a lot of Java developers as it is statically typed - just like Java. However, Scala focuses on concurrent processing. The choice of frameworks for typically bread and butter issues that you see in Enterprise applications is rather limited. For that reason it makes sense to look at Spring as a very mature and established Java Enterprise technology and whether it can be used with Scala. So here is a presentation and some sample code:
https://github.com/ewolff/scala-springLabels: Scala, Spring
JAXLondon The Future of Messaging: RabbitMQ and AMQP Slides Online
The slides for my talk "The Future of Messaging: RabbitMQ and AMQP" is now online at
slideshare.
Labels: AMQP, RabbitMQ, Spring, Spring AMQP
Dependency Injection Is More Than Wiring Components
Dependency Injection is widely used nowadays. However, at least in the Java EE space this is narrowed down to "wiring components". I think configuring beans and injecting simple types is at least as important. The alternative is to read in configuration properties from files. Here is why I think DI is the much better approach for that:
- Every project with a certain complexity has this problem. It needs to be adjusted to different users, use cases etc. A common problem should have a standardized solution
- Reading in configuration files is not that easy. You have to handle exceptions if the file does not exist. You need to figure out what to do if a certain value is not set. You might want to have multiple files that can override configurations. I have to admit that I have seen projects in which the most complex code handled the configuration. Spring's XML configuration is already a powerful solution for this. And if you want to use properties files: The PropertyPlaceholderConfigurere allows to use those for configurations as well without writing any code. The PropertyPlaceholderConfigurere is very flexible - see its JavaDoc. But even if this is not enough: Using the BeanFactoryPostProcessor interface you can add your own configuration extensions.
- As configuration is needed almost anywhere the class handling the configuration file becomes a dependency for a lot of classes. This is not a good design. Using DI the configuration will be injected and there is no such dependency.
- Testing will also be hard if each class depends on the class handling the configuration. You will need a complete and correct configuration even for the smallest unit test. Otherwise the configuration cannot be read in. Changing the configuration for a specific test will either be impossible or the code for the configuration will become even more complex. Using the DI approach this is no problem as the configuration is injected and you can easily inject different values.
Of course this is not apparent during a short demo - but in real life DI for these kinds of applications it is a huge advantage.
Labels: Configuration, Dependency Injection, Spring
Preview: JAX 2011
The annual JAX conference in Mainz is the main event for Germany's Java scene. For JAX 2011 I had the pleasure to organize the Spring Day again. The schedule contains:
- Agim Emruli will start the day by discusssing "Web, RIA and mobile Aapplications with Spring". The client technologies are constantly evolving and this talk will present an overview about the current state of affairs.
- Then Jürgen Höller will talk about the upcoming Spring 3.1 release. Jürgen is the lead engineer so we will get some information from the source.
- Next is a talk by me about "Spring in the Cloud". I will show why Spring is a good solution for the Cloud and what you can do with it right now.
- Oliver will discuss Spring Data. He is one of the developers on that project which will support relational databases as well as NoSQL databases.
- Stefan Scheidt will show how to create a backend for an iPhone application using Spring Roo. This is a very good show case about Roo's capabilities.
- Finally we will have a panel to discuss any questions and get some feedback. So all the speakers will be there and it will be highly interactive.
There will also be a basic Powerworkshop about Spring. This time I decided to do it based on Spring Roo which in my opinion is a great way to create Spring applications quickly. Also there will be an Advanced Spring Powerworkshop during which I will talk about advanced topics such as Patterns, architecture, migration to Spring etc.
During the conference I will also do a presentation about AMQP and RabbitMQ for Java developers and a presentation about Java PaaS.
Last but not least: We are planning a panel about the next decade in the Java world with Lothar Wieske and Stefan Tilkov. I am looking forward to this and I hope we will have some interesting discussions there. If there is anything you think we should be talking about I would be more than happy to hear about it!
So JAX 2011 will be quite a packed conference for me. But I am sure it will be a very nice conference again and I am looking forward to meet as many of you there as possible!
Labels: JAX 2011, Spring
Why I care about Spring...
My blog post
Spring vs. Java EE and Why I Don't Care mentioned a lot of challenges that I believe are crucial for the future success of Java. There are numerous projects that are working on these challenges. In this blog posting I will provide an update about those projects that VMware/SpringSource is investing in:
- In the original post I mentioned Groovy/Grails and Spring Roo as new approaches to gain more productivity. Shortly after the blog post Spring Roo 1.1.0 (blog post) was launched and 1.1.1 shortly thereafter (blog post). The new releases include Google App Engine support, GWT support and database reverse engineering.
- For NoSQL there is the Spring Data project (see project homepage) which supports many NoSQL and relational datastore. I believe this is the most important and most ambitious project in the NoSQL space for Java. The broad support for all the different data stores is quite unique.
- Spring Social offers uniform support for most social web site, see project homepage. This is very important as social media change the way the internet is used and in particular offers new ways to become more popular on the web.
- Another challenge is integration into existing applications. Spring Integration 2.0 was launched, see this blog post.
- Besides the Caching abstraction in Spring 3.1 already mentioned in the original post there is also Spring GemFire to support our own Data Fabric GemFire in Spring.
- Messaging: Support for AMQP is developed in the Spring AMQP project (see project homepage).
So if you are interested in these technologies: Give them a try! If there are any issue or if you want to see other features in the products don't forget to issue JIRAs for that. It is the feedback of the community that makes Spring and Open Source so vivid - that is your chance to add to that!
Labels: Challenges, Spring, SpringSource
Spring vs. Java EE and Why I Don't Care
Disclaimer: I work for VMware / SpringSource. That means I might be biased - but then again we did not just create Spring. We are also a member of the Java EE 6 Expert Group. The views are my personal view of course.
History
Spring has established itself as a very popular solution for Enterprise Java applications. In particular the advantages of Spring as compared EJB 1.x / 2.x were very obvious and were a major reason for Spring's success.
The Current State
Due to Spring’s early success and adoption, Java EE 5 and Java EE 6 were pushed to greatly simplify the Java EE programming model, increase developer productivity and become much simpler to use than previous versions. The current Java EE 6 solutions are thus just now achieving the ability to compete against Spring's programming model. Developers now are ready to ask the question "Why you would prefer Spring?" Here is my take:
- Many key elements of Java EE 6 such as JSR-330 (@Inject), Common Annotations (@Resource, @RolesAllowed etc) and even some EJB annotations (@TransactionAttribute, @Asynchronous etc) are supported by Spring. So you can choose a programming model that is very similar to the Java EE programming model.
- There are differences, among others: Spring typically uses Singleton beans, EJB typically used pooled beans - and of course the annotations for them are different. But do you really think this will impact productivity or even the success of a project?
- However, Spring is much more flexible. Instead of the annotations mentioned above you can choose XML or Java based configurations. You can create custom extension using AOP. You can use the JMS and JDBC abstractions - all of that is not included in Java EE. So the programming model Spring can almost be considered a superset of Java EE. Usually more power and flexibility to choose different options is considered a superior solution.
- There is a difference in platforms that you can deploy on: Typically you will need to use Java EE application server for Java EE solutions while Spring is perfectly happy to run on Tomcat or other simple servers. Tomcat is the predominant server in the marketplace so this is actually an important difference. (Let me add that you might use OpenEJB on Tomcat i.e. you can support more of the Java EE APIs on Tomcat if you really want to.) Also there are problems: If you want to run Java EE 6 you are limited to the very small set of certified servers. If you have a strategic commitment to an application server vendor who doesn't support Java EE 6 you can still use Spring. If operations won't install the latest release of your application server, you can still use Spring. Spring happily runs in these environments.
- Of course Java EE also has an advantage: the fact that Java EE is baked into the server. Therefore you don't need to deploy it with the application which can make some things easier. It might be easier to set up your infrastructure. It might be easier to package and share your application. But I personally would prefer to be flexible in deployment over these advantages.
Before we start a flame war and get lost in technical details let me reiterate: Java EE and Spring can have a similar programming model. Spring is more flexible and I would prefer it. But: I don't think your project will fail because of the decision you made concerning this. And: I think a Java EE vs. Spring shoot out will be boring. If you do a side by side comparison you will end up with minor differences such as @Component instead of @Stateless or whether you will need to deploy some additional JARs. While that might be impressive in a demo I don't believe this will convince anyone to use one platform or the other. Certain features of Spring (e.g. the flexibility to use XML or Java based configuration) will probably not be shown as they just cannot be done using Java EE.
Why I don't care
So if a side by side comparison doesn't make a lot of sense - why would I choose Spring? There has to be a clear advantage somewhere to definitely answer this question. A personal note at this point: I am frequently work at a shared office space with some JavaScript and Ruby on Rails guys - I am the only Java guy there (and sometimes I think they pity me). After talking a lot with these other developers, I believe we need a compelling Java story that can live up to their developer experience. If Java EE and Spring are both on a comparable level concerning productivity we need to come up with novel ideas to improve. Looking at Ruby on Rails helps here - the approach is to combine a dynamic language with a powerful framework and a code generator. The next level of productivity is not Java EE vs. Spring. It must be something that can counter the productivity of Ruby on Rails. I believe this is:
- Groovy / Grails: it combines a dynamic language with a powerful framework and a code generator - like Ruby on Rails. The only difference is that the solution is more adapted to the JVM and has better integration with Java, the most important platform in the Enterprise space.
- Spring Roo: it combines Java/AsepctJ with a powerful framework (Spring) and a code generator - like Ruby on Rails. This is easier to learn for Spring developers than Groovy / Grails and has therefore appeals to a different audience.
So if you look at productivity the comparision should not be "Java EE vs. Spring" but rather "Groovy / Grails vs. Spring Roo vs. Ruby on Rails". Better productivity is not gained on the level of the framework or the programming model any more.
Asking the Wrong Question
The other reason why I think "Spring vs. Java EE" is the wrong question is: Both models on their own do not solve the challenges I typically see in projects. Let me give you some examples:
- Integration: Today almost any project will need to integrate with other technologies through file transfer, Web Services, messaging etc. There are well known patterns for this - the Enterprise Integration Patterns by Gregor Hohpe. Neither Java EE nor the core Spring Framework help here - you will need to use a framework like Spring Integration, Apache Camel or its competitors.
- Batches: A lot of project use batches. They might import data - or to run complex business logic. In the latter case, chances are that the batches are actually mission critical. Neither Java EE nor the core Spring Framework help here - you will need to use a framework like Spring Batch. (I believe there are no real competitors but I might be wrong).
- Caching: Like many of our competitors we at SpringSource believe that caching is a very important part for a performant enterprise solution - you can tell by the product strategy in the Java EE space. Again this is something that Java EE does not cover. However, for Spring a cache abstraction is planned in Spring 3.1. A standard in Java EE - if there is ever to be one - won't be there until the next Java EE release.
- Again looking at my Ruby on Rails office mates: They deploy a lot of projects into the cloud. Offerings like Heroku make that extremly simple. Of course you could run Spring or Java EE on an IaaS like Amazon EC2 or VMware vCloud Director cloud. But it might be easier to use a PaaS that will deal with scaling, fault tolerance etc automatically and it usually offers some interesting additional services. Google App Engine as the predominant public PaaS as well as VMforce have strategic commitments to Spring. The Cloud has clear economic benefits so this technology will become more and more important. The Java platform has to have a solution here - otherwise it will eventually become irrelevant.
- More and more data is stored in non relational databases (NoSQL). Actually that is the only way we will be able to cope with the exponentially growing amount of data and the structures like graphs in social networks or unstructured user content. Again it this quite common in the Ruby on Rails camp - while for Java there is currently a lack of APIs. Java EE has no support - and it won't for a while. There are so many non relational stores a standard will be hard to define in a standards body.
- Also integration in social networks like Twitter, Facebook and other common internet services will be more and more important. Again this is common in the Ruby on Rails community. And at least one of my customers with a very large web site mentioned this as "a feature marketing will love" - remember Facebook is almost as important a source for internet traffic as Google nowadays. We need solutions for this in the Java space.
- Messaging: In the Java EE community the JMS standard has been very stable for 10+ years. Outside the Java community there was actually innovation. Therefore a lot of the office mates use RabbitMQ - and that is also the predominant messaging solution on the EC2 cloud. It is standardized on the protocol level (AMQP) and it is much more flexible (not just topics and queues). That is why SpringSource bought Rabbit Technologies and why we are investing considerable resources in the Spring-AMQP project.
So there are a lot of challenges Java EE just has no solution for. A side by side comparison of Spring and Java EE might lure you to believe that JSF + Spring / Java EE + database is all you will ever need. Look at your projects and decide for yourself if that is true. It certainly contradicts my experience.
Sum Up
To cut a long story short:
- You won't see a lot of change in your productivity if you use Spring or the newest Java EE releases. The next level of productivity is not about these programming models but about Groovy / Grails or Spring Roo.
- Spring and Java EE will only be a part of your technology stack. You will need to look at solutions for a lot of issues outside these. That is why SpringSource and others are currently investing heavily in creating such solutions for the Java crowd. And a lot of these solutions are well integrated with Spring.
...and a last thing
So you have read this blog post to the end. That is great - thanks a lot! Please don't start a religious battle now. Instead code something or do something fun. Enjoy!
Labels: I don't care, Java EE, Spring
Developing for the Cloud Workshop
The move to the Cloud is inevitable. SpringSource is now a division of VMware and therefore the Cloud is the most important topic of our work now. And there is a lot of technology we are putting out in this area - e.g. RabbitMQ, GemFire, Redis. So are you wondering what this is all about? Need more insight in how to develop for the Cloud?
Take a look at
Java Development for the Cloud at Entwickler Tage. This one day workshop covers:
- What is the Cloud?
- Advantages of Cloud technologies
- Developing for the Cloud with Spring Roo
- Infrastructure as a Service (IaaS): How applications can be developed with Amazon EC2 and VMware technologies
- Platform as a Service (PaaS): Developing Java application for the Google App Engine and SpringSource Cloud Foundry
- PaaS: Concepts of VMforce
- Architecture for the Cloud
- Data in the Cloud: NoSQL with the example Redis
- Distributed Caching and Data Fabrics for better Scalability with GemFire
- Cloud messaging: RabbitMQ, the AMQP protocol and Java
Interested? You can register above for the event in Mainz, Germany. Let me know if you think other locations might also make sense or if you have any other feedback.
Labels: Cloud, GemFire, RabbitMQ, Redis, Spring
Wir stellen wieder Consultants ein...
Wir planen dieses Jahr unser Consulting-Team in Deutschland weiter zu verstärken. Neben Spring geht es dabei auch um tc Sever, Tomcat, Hyperic, Groovy und Grails. Der Job ist sehr abwechselungsreich: Man sieht viele verschiedene Projekte und Einsatzkontexte der Technologien. Inhaltlich beschäftigt man sich mit der Beratung und dem Abhalten von Trainings. Außerdem gibt es Möglichkeiten, sich an unseren verschiedenen Projekten zu beteiligen. Außerdem hat man praktisch freie Wohnortswahl - unsere Organisation ist sowieso verteilt. Allerdings muss man reisebereit sein.
SpringSource und VMware haben noch viel vor - dabei zu sein ist sicher sehr spannend! Bei Interesse bitte entsprechende Nachricht an mich: ewolff bei vmware punkt com .
Labels: Consultant, Grails, Groovy, Hyperic, Job, Spring, tc Server, Tomcat
S2G Forum: *Der* Spring und Groovy / Grails Event in Deutschland
Wie schon angekündigt findet am 18.3. das S2G Forum in München statt. Noch sind Plätze frei, so dass ich die Gelegenheit nutze, noch mal auf den Event hinzuweisen. Für einen recht geringen Betrag von 94€ gibt es die Möglichkeit, die erste Garde aus den Bereichen Spring und Groovy/Grails zu erleben. In dieser So viele hervorragende Speaker gibt es sont nur selten - dazu zählen verschiedene Projekt-Leads wie Jürgen Höller (Spring), Graeme Rocher (Grails), Guillaume LaForge (Groovy), Mark Fisher (Spring Integration), Christian Dupuis (SpringSource Tool Suite) oder Keith Donald (Spring Web Flow). Außerdem haben wir mit Mark Thomas auch noch einen ausgewiesenen Tomcat-Experten - es gibt also eine Menge zu sehen und zu hören.
Nähere Infos:
Und zur
Anmeldung geht es hier.
Labels: Grails, Groovy, S2G Forum, Spring
SpringSource S2G Forum am 18.3. in München
Dieses Jahr macht SpringSource wieder einen Event in München und zwar das S2G Forum. Wir haben dieses Mal drei Tracks: Einen zu Spring, einen zu Tomcat, Hyperic und Cloud und einen zu Groovy/Grails.
In dem Spring-Track werden neben Jürgen Höller (Spring Projekt Lead), Mike Wiesner (Spring Security Guru) und verschiedene Committer wie Keith Donald (Spring Web Flow) und Mark Fisher (Spring Integration) auch ich sprechen. Der zweite Track wird unter anderem Tomcat 7.0 besprechen und einen Einblick in die Strategie rund um Cloud, Management und Administration geben. Hier haben wir auch sehr gute Speaker wie Mark Thomas (Tomcat Comitter) und Christian Dupuis (SpringSource Tool Suite Lead) gewinnen können. Im Groovy/Grails Track werden die Vorträge von Guillaume Laforge (Groovy Committer) und Graeme Rocher (Grails Comitter) gehalten.
Ingesamt ein sehr hochkarätiger Event, bei dem die Teilnahme nur einen Unkostenbeitrag von 94€ kostet.
Nähere Infos:
Und zur
Anmeldung geht es hier.
Labels: Grails, Groovy, Hyperic, München, S2G Forum, Spring, Tomcat
Dritte Auflage meines Spring-Buchs steht vor der Tür...
Die dritte Auflage meines Buchs steht vor der Tür. Noch in diesem Quartal sollte es lieferbar sein. Neben einem Update auf Spring 3, Spring Web Flow 2.0, Spring Security 2.0 wird nun auch zum Beispiel OSGi und dm Server näher erläutert. Es hat sich also vieles an dem Buch geändert, so dass es sicher auch sinnvoll ist, es zu kaufen, wenn man eine der vorherigen Auflagen besitzt.
Hier die Links, wenn man gleich zugreifen will:
Bei Lehmanns Bei dpunktLabels: Spring, Spring Buch
Ein kleines Weihnachtsgeschenk
Vorab: Frohes Fest!
Ich habe mir gedacht, dass ich dieses Jahr zu Weihnachten ein kleines Geschenk an die Leser dieses Blogs bastel. Und zwar habe ich die kleinste Spring-Bean gebaut. Hier ist der Code:
package com.blogspot.jandiandme;
public class MyService {
private MyRepository myRepository;
public void setMyRepository(MyRepository myRepository) {
this.myRepository = myRepository;
}
}
Wie man sieht: Keine Spring-Abhängigkeiten, keine Annotationen, nur Java-Code. Kleiner geht es nicht.
Nun erwartet man natürlich, dass in der XML-Konfiguration das Repository und der Service konfiguriert werden müssen. Das ist aber nicht wirklich der Fall:
<?xml version="1.0" encoding="UTF-8"?>
<beans xmlns="http://www.springframework.org/schema/beans"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://www.springframework.org/schema/beans http://www.springframework.org/schema/beans/spring-beans-3.0.xsd
http://www.springframework.org/schema/context http://www.springframework.org/schema/context/spring-context-3.0.xsd"
xmlns:context="http://www.springframework.org/schema/context"
default-autowire="byType">
<context:component-scan base-package="com.blogspot.jandiandme"
use-default-filters="false">
<context:include-filter type="regex"
expression=".*Repository" />
<context:include-filter type="regex"
expression=".*Service" />
</context:component-scan>
</beans>
Wie man sieht, werden das Repository und der Service durch eine Namenskonvention bei den Klassen identifiziert. Alle Klassen, die auf Repository oder Service enden, werden automatisch zu Spring-Beans. Dies ist im component-scan-Element entsprechend definiert. Das Wiring kommt durch das default-autowire-Attribut im beans-Element zu Stande. Es wird automatisch eine typ-kompatible Spring-Bean injiziert, wenn dies möglich ist. Damit kann man also mit dieser Konfiguration sehr einfach auch beliebige weitere Spring-Beans analog definieren - ohne zusätzliches XML.
Das Beispiel gibt es mit Maven-Build unter
http://spring-buch.de/small-spring.zip.
In diesem Sinne: Frohes Fest!
Labels: Spring
Noch Plätze frei: Spring: Performance, Skalierbarkeit & Betrieb am 3.11. in Düsseldorf
Am 3.11. findet in Düsseldorf der Event zu Spring: Performance, Skalierbarkeit & Betrieb statt.
Auf der Agenda steht:
- Monitoring und Performance Optimierungen mit Spring (Eberhard Wolff)
- Portabilität auf Framework-Level - Spring als Runtime (Agim Emruli)
- Hyperic HQ - Die Open-Source-Monitoring-Lösung (Agim Emruli)
- Tomcat und OSGi als Plattformen: Alternativen, Vor- und Nachteile (Eberhard Wolff)
Nähere Informationen finden Sie unter
http://spring-performance.eventbrite.com/. Dort können Sie sich auch registrieren. Es wird ein Unkostenbeitrag in Höhe von 99€ erhoben, für das leibliche Wohl ist gesorgt.
Labels: Betrieb, Düsseldorf, Performance, Skalierbarkeit, Spring
SE-Radio-Interview mit mir über Spring
Unter
http://www.se-radio.net/podcast/2009-09/spring-2009-eberhard-wolff gibt es eine Interview mit mir zum Spring-Framework - allerdings in Englisch. An dieser Stelle mein Dank an SE Radio und insbesondere Markus Völter für das Interviews.
Labels: SE-Radio, Spring
Event: Leichtgewichtige JEE Entwicklung mit dem Spring Framework
SpringSource und OPITZ CONSULTING zeigen auf unsere gemeinsamen
Veranstaltung „Moderne Enterprise-Java-Entwicklung mit dem Spring
Framework“ welche Vorteile die Entwicklung mit Spring bei
Individualsoftware bringt. Individualsoftware unterstützt komplexe
Prozesse optimal und lässt sich so flexibel anpassen, dass sie den
ständigen Änderungen im Geschäft gewachsen ist. Jedoch verbindet man
Entwicklung und Betrieb individueller Unternehmensanwendungen oft mit
drei Eigenschaften: teuer, riskant und aufwändig. Dass es mit den
richtigen Werkzeugen und Methoden auch anders gehen kann, möchten wir
Ihnen in dieser Vortragsreihe beweisen.
Termine:
23.9.2009
Frankfurt12.10.2009
Hamburg13.10.2009
München14.10.2009
Köln9.11.2009
Zürich Agenda
10:00 Uhr Softwareprojekte in wirtschaftlich schweren Zeiten
- Chancen und Risiken
- Bedeutung von Vorgehen und Technik
Referent: OPITZ CONSULTING
10:25 Uhr Effizienz durch moderne Entwicklungsverfahren
- Spring als Grundlage moderner Architekturen
- Qualität und Wartbarkeit durch Testautomatisierung
- Effizienz durch Vermeidung nichtdifferenzierender Entwicklung
Referent: OPITZ CONSULTING
11:15 Uhr Integration statt Neuentwicklung
- Spring als Integrationsplattform
- Effizienz durch Vermeidung nichtdifferenzierender Entwicklung
- Fallbeispiele
Referent: OPITZ CONSULTING
12:00 Uhr Mittagspause
12:45 Uhr Spring kosteneffizient betreiben
- Monitoring und Administration
- tc Server, dm Server und Hyperic
- Praxisbeispiele
Referent: SpringSource
13:30 Uhr Get together
Labels: Opitz, Spring
Event am 3.11. in Düsseldorf: Spring: Performance, Skalierbarkeit & Betrieb
Sie benutzen Spring zur Entwicklung Ihrer Anwendungen - aber was ist beim Betrieb und Performance-Tuning zu beachten? In diesem Seminar erhalten Sie Hinweise, wie man Anwendungen mit Spring effektiv betreiben kann und wie man typische Performance-Optimierungen vornehmen kann. Dabei stellen wir Ihnen Projekte wie die Hyperic HQ Open-Source-Monitoring-Lösung, Tomcat und dm Server vor.
Bitte registrieren Sie Sich unter
http://spring-performance.eventbrite.com/ - dort finden Sie auch den genauen Ablauf. Es wird ein Unkostenbeitrag von 99€ erhoben. Für das leibliche Wohl ist gesorgt.
Labels: Betrieb, dm Server, Hyperic, Performance, Skalierbarkeit, Spring, tc Server, Tomcat
Das Problem mit Java EE oder: Die reale Realität vs. die Konfernenz-Realität
Wenn man Konferenzen besucht und sich Vorträge anhört, bekommt man leicht den Eindruck, dass Java EE eine ernsthafte Alternative zu Spring ist und vor allem - es ist ja im Application Server enthalten, warum also Spring nutzen? Dabei ist die Rede natürlich von Java EE 5 und dem noch nicht fertig spezifizierte Java EE 6. Diese Standards haben neue Programmiermodelle eingeführt - über die Probleme von Java EE 1.4 und EJB 2.x braucht man wohl nichts zu sagen.
Interessanterweise hat diese Konferenz-Realität aber nichts mit der realen Realität zu tun, die da draußen in den Projekten wirklich gelebt wird. Zunächst einmal sagen zahlreiche Statistiken, dass Tomcat die führende Java-Plattform ist. So zeigt der
JAXenter Quick Vote zum Beispiel, dass 58% aller Java-Entwickler Tomcat als Basis aller Web-Projekte verwenden, 24% gelegentlich je nach technischer Entscheidung und 12% gelegentlich je nach politischer Entscheidung - zusammen 94%. Das 2008 Evans Data Survey geht von 68% Markt-Anteil von Tomcat aus. Das TheServerSide Survey kommt zu ähnlichen Ergebnisse. Ingesamt arbeitet die Mehrheit der Java-Anwendung also mit Tomcat und hat daher keine vollständige Java-EE-Umgebung. Sie können oder wollen also nicht die vollständigen Java-EE-APIs nutzen. Es kann auf keinen Fall die Rede davon sein, dass man die Java-EE-APIs "eh schon im Application Server hat". Das Gegenteil ist der Fall - der Java-EE-Application-Server ist die Ausnahme, nicht die Regel. Und selbst wenn einer genutzt wird, ist es oft eine alte Version, die noch kein Java EE 5 unterstützt. Der Betrieb ist eben eher konservativ. Java EE 6 ist noch nicht einmal fertig standardisiert - es macht also wenig Sinn, das weiter zu betrachten.
Diese Wahrnehmung spiegelt sich auch in konkret in letzter Zeit erlebten Projekt-Szenarien wieder:
- So das Projekt, das zwar auf einem vollständigen Java-EE-Server läuft, aber auf JDK 1.4. Java EE würde hier EJB 2.x anbieten, was niemand wirklich will. Die einzige sinnvolle Alternative ist also Spring.
- Oder das Projekt, dass auf einer Standard-Software aufbaut. Die läuft auf einem gebundelten Tomcat - der eben kein vollständiges Java EE anbietet. Selbst wenn man wollte, kann man kein vollständiges Java EE nutzen.
- Oder das Projekt, das von EJB 3 wegmigriert, um auf Tomcat umzusteigen - weil man Tomcat als gegenüber Java EE als Ablaufumgebung vorzieht.
Die Realität im Java-Bereich ist, dass eine vollständige Java-EE-Unterstützung - im Gegensatz zu dem Stand vor einigen Jahren - bei Enterprise-Anwendungen keine große Rolle mehr spielt. Und ich denke, dass sich dieser Trends aufgrund der Dominanz von Tomcat und dem OSGi-Aufschwung noch weiter verstärken wird.
Labels: Java EE, Spring, Tomcat
Spring EInführungsartikel
Unter
http://robbbert.hostrator.com/ steht ein recht umfangreicher Artikel mit einer Einführung zu Spring bereit.
Labels: Spring
Case Study mit QuinScape online
Unter
http://www.springsource.com/files/QuinScape%20Case%20Study_0.pdf steht nun eine Case Study zur Verfügung, in der unser deutscher Partner QuinScape über die Vorzüge von Spring und dm Server bei der Entwicklung von Anwendungen berichtet.
Labels: dm Server, QuinScape, Spring
Video zum Vortrag "Architekturen und Spring" online
Unter
http://it-republik.de/jaxenter/news/JAX-TV-Gute-Architekturen-mit-Spring-049097.html kann man nun meinen Vortrag zum Thema "Architekturen mit Spring" anschauen. Viel Spaß!
Labels: Architektur, Spring, WJAX
J for Java |
I for Internet, iMac, iPod and iPad |
Me for me