Enterprise grade Java.
You'll read about Conferences, Java User Groups, Java, Integration, Reactive, Microservices and other technologies.

Friday, October 30, 2009

Log4J Twitter Appender - twitter your logmessages :)

09:22 Friday, October 30, 2009 Posted by Test No comments:
, , ,
Don't ask me why, but I was thinking about a "twittering" WebLogic for some days now. And I finaly managed to spend some minutes on this today. This is the first approach. Have some more in mind and would like to contribute them, too.

Let's start over with the Log4JTwitterAppender:
You can download the jar directly. Anything else you need is a recent version of Log4J and JTwitter. I used Log4J 1.2.15 and JTwitter 1.2. Now drop all three jars log4j-1.2.15.jar, jtwitter.jar and l4jtwitterappender.jar to your project and add a log4j.properties file to it.

A sample log4j.properties looks like this:

# Add the twitter appender
log4j.rootLogger=DEBUG, TWITTER
[%d{MMM dd HH:mm:ss}] %-5p (%.20F) - %.49m%n

If everything is configured, you can start logging:

private static final Logger log =

log.debug("your log message");

If everything works fine, you now have a logging twitter account :)

You can configure the layout if you like with the normal PatternLayout machanism. But to be honest ... 140 characters are hardly enough for log messages :)
Anyway, it was fun doing it ...

Thursday, October 29, 2009

Loadbalancing with fail-over through Apache 2.2 and GlassFish v2.1.1

12:33 Thursday, October 29, 2009 Posted by Test No comments:
, , , , , ,
One of the top posts on my blog is about installing and configuring the BEA/Oracle Apache Plugins for WebLogic Server. This inspired me to write a similar howto about how to achieve the same effect with Apache and GlassFish Server. To be honest, I recently came across some projects working with a clustered GlassFish domain behind an Apache Webserver. And there was definitely a need to understand, what is going on ;)

Let's start.

- GlassFish v2.1.1
- Apache Webserver 2.2.14

Setup GlassFish Domain,Nodeagent,Cluster and Nodes:
1) Download and install GlassFish (java -Xmx256m -jar glassfish-installer-v2.1.1-b31g-windows.jar)
2) Build a Cluster domain ( $GLASSFISH_ROOT/lib/ant/bin/ant -f setup-cluster.xml)
3) Start GlassFish ($GLASSFISH_ROOT/bin/asadmin start-domain)
4) Create a Nodeagent ($GLASSFISH_ROOT/bin/asadmin create-node-agent --host localhost --port 4848 nodeagent1
5) Start the Nodeagent ($GLASSFISH_ROOT/bin/asadmin start-node-agent nodeagent1)
6) Login to your admin server (http://localhost:4848/)
7) Create a cluster (name it, whatever you like, I like cluster1)
8) Create two nodes (same here, I like instance1, instance2)
9) Start the cluster
10) Add a property to the clusterwide jvm configuration (-DjvmRoute=${INSTANCE_ROUTE} )
11) Add an instance specific property to instance1 (INSTANCE_ROUTE = w1)
12) Add an instance specific property to instance2 (INSTANCE_ROUTE = w2)
13) deploy clusterjsp example app ($GLASSFISH_ROOT/glassfish/samples/quickstart/clusterjsp)

Setup Apache, mod_proxy, mod_status and mod_proxy_balancer:
1) Download and install Apache HTTPD Server (e.g apache_2.2.14-win32-x86-no_ssl.msi for windows )
2) Edit the httpd.conf:
Change Listen Port to whatever you like. If you run on a single maschine, you should change it to anything but the already blocked GF ports. I use Listen 6666 in this example
3) Uncomment the modules:
LoadModule proxy_module modules/mod_proxy.so
LoadModule proxy_balancer_module modules/mod_proxy_balancer.so
LoadModule proxy_http_module modules/mod_proxy_http.so
LoadModule status_module modules/mod_status.so
4) Add the rewriting configuration to the end of the file:

# Enable the rewriting engine
RewriteEngine On

# Enable Reverse Proxy functions
ProxyRequests Off

# Preserve the proxy host-name
ProxyPreserveHost On

# Set access permissions to anyone
<Proxy *>
Order deny,allow
Allow from all

# Enable balance-manager (http://localhost:port/balancer-manager)
<Location /balancer-manager>
SetHandler balancer-manager

# balancer configuration with two nodes
<Proxy balancer://mycluster>
BalancerMember route=w1
BalancerMember route=w2
ProxySet lbmethod=byrequests stickysession=JSESSIONID|jsessionid nofailover=Off

# define the proxy rules for your application

ProxyPassMatch ^(.*\.do)$ balancer://mycluster$1
ProxyPassMatch ^(.*\.jsp)$ balancer://mycluster$1
ProxyPassMatch ^(.*\/clusterjsp\/.*)$ balancer://mycluster$1

# define the reverse proxy rule
ProxyPassReverse / balancer://mycluster/

# Enable extended server status
ExtendedStatus On

# enable server-status location (http://localhost:port/server-status)
<Location /server-status>
SetHandler server-status

# Set access permissions to anyone (not suitable for production !!!)
Allow from all

5) Test the configuration and start the apache instance
6) Access your application (http://localhost:6666/clusterjsp/)

Thats all. Finaly, this installation behaves like the oracle apache plugins. You can define dispatching rules für dynamic content or whole directories.

Not needed for the cluster funcionality is the server-status. But this is quite helpful if you like to know, what your apache is doing. Give it a shot and have a look at http://localhost:6666/server-status. Don't forget to disable this in production environment.
Another great thing is the balancer-manager. You can define weight based routings and see the status of the server nodes and the LoadBalancer status in general.

Wednesday, October 28, 2009

Oracle Updates Sun Merger FAQ

06:58 Wednesday, October 28, 2009 Posted by Test No comments:
, , , , , ,
Oracle has updated their page on Oracle and Sun and it now includes a PDF entitled "Oracle and Sun Overview and FAQ".

For the first time, it contains some brief answers to some of the hottest JEE community questions around. I copied the relevant sections from the statement in the following. Refer to the PDF for the comple FAQ. I highlighted some interesting parts in italic and commented on the sections. Disclaimer: I know nothing about the Deal at the moment! This are my personal thoughts. Like them, or not!

What are Oracle’s plans for the GlassFish Enterprise (Java EE) Server after the transaction closes?
Oracle plans to continue evolving GlassFish Enterprise Server, delivering it as the open source reference implementation (RI) of the Java Enterprise Edition (Java EE) specifications, and actively supporting the large GlassFish community. Additionally, Oracle plans to invest in aligning common infrastructure components and innovations from Oracle WebLogic Server and GlassFish Enterprise Server to benefit both Oracle WebLogic Server and GlassFish Enterprise Server customers.
To me, this sounds like a commitment to the actual JCP process. As I have written earlier in my "Is Oracle good for Java?" posting, I believe, that the JCP needs a new setup after the merger. If this is done, I could imagine that GF will exist and grow. What I am still not shure about is the support offering around GF. Does it make sense, to fully support two application servers?

What are Oracle’s plans for NetBeans?
Oracle has a strong track record of demonstrating commitment to choice for Java developers. As such, NetBeans is expected to provide an additional open source option and complement to the two free tools Oracle already offers for enterprise Java development: Oracle JDeveloper and Oracle Enterprise Pack for Eclipse. While Oracle JDeveloper remains Oracle’s strategic development tool for the broad portfolio of Oracle Fusion Middleware products and for Oracle’s next generation of enterprise applications, developers will be able to use whichever free tool they are most comfortable with for pure Java and Java EE development: JDeveloper, Enterprise Pack for Eclipse, or NetBeans.
To be honest. I liked NetBeans, years ago. And I never liked JDeveloper. And this probably will never change ;) As a eclipse developer I stands in second row behind the JDev users. This will happen to NetBeans users, too. Know what? Does not feel too bad. I expect Oracle to hand NetBeans over to the community and not investing into the core plattform. They will deliver integration points up to the OEPE level. But that will be all.

What are Oracle’s plans for MySQL?
Oracle plans to spend more money developing MySQL than Sun does now. Oracle expects to continue to develop and provide the open source MySQL database after the transaction closes. Oracle plans to add MySQL to Oracle’s existing suite of database products, which already includes Berkeley DB, an open source database. Oracle also currently offers InnoDB, an open source transactional storage engine and the most important and popular transaction engine under MySQL. Oracle already distributes MySQL as part of our Enterprise Linux offering.
I am pretty unshure about MySQL at the moment. Does it really matter in the enterprise? It never hit my road at customers. Anyway, it could be a smart solution for some Exadata variants for small customers. And it has a great distribution among many non commercial and open source products. It is a strong brand and could work for Oracle as it is. I am not affraid about it's future at all.

How does Oracle support open source?
Oracle has long been committed to developing, supporting, and promoting open source. Oracle has been, and continues to be, committed to offering choice, flexibility, and a lower cost of computing for end users. Oracle has invested significant resources in developing, testing, optimizing and supporting open source technologies such as Linux, PHP, Apache, Eclipse, Berkeley DB, and InnoDB. Oracle continues to embrace and offer open source solutions as a viable choice for development and deployment. More information about Oracle’s support of open source can be found at oracle.com/opensource.
They do. As Mike Lehmann states in my recent email interview:
We believe we have the best open standards server implementation on the planet and agressively are standards compliant. We are also strong believers in open source and actively participate in numerous communities supporting open source development.
(Mike Lehmann, Senior Director of Product Management, Fusion Middleware Oracle Weblogic Server and Java Plattform, Oracle)

Monday, October 26, 2009

Optimize GlassFish Performance in a Production Environment

12:40 Monday, October 26, 2009 Posted by Test No comments:
, ,
I recently came across some projects, that in fact needed some performance tunings. Doing so, I was also looking for some best practices and white papers around.
Found this one: Optimize GlassFish Performance in a Production Environment, Performance White Paper, February 2009 (Sun)

It is designed for users requiring general guidance for initial tuning values in order to improve the application performance on the Sun GlassFish application server v2.

This paper provides the Introductory Steps to achieving better performance for the Sun GlassFish application server v2 application with descriptions of the Eleven tuning parameters; General Recommendations, which can be used to optimize the performance of the application server; and Data from a benchmarking exercise that demonstrates the effectiveness of the tuning changes.

Tip 1: Java Version
Obious .. change to latest JVM if possible.

Tip 2: JVM Mode
GF runs with -client ootb. change to -server

Tip 3: Java Heap Size
Give your server, hat it needs.
By default, the GlassFish application server is set to 512 MB
and the limit for a 32 bit JVM version- is approximately 3.5GB on Solaris, and 1.5
GB on Windows without any operating system tweaks.
Further information is available in this JVM Tunin White Paper!

Tip 4: Tune Java Garbage Collection
A deeper understanding is necessary when tinkering with GC tuning options and it is strongly recommended to read Tuning Garbage Collection with the Java Virtual
for more details and GC strategies.

Tip 5: HTTP acceptor threads
HTTP acceptor threads accept new incoming connections and schedule new
requests for the existing connections. The default number of acceptor threads is one! It is recommended to have 1 thread per 1-4 core.

Tip 6: HTTP request processing threads
This pool of threads retrieve and process incoming HTTP requests. The default
number of request processing threads is 5 but a starting rule of thumb is to tune
the number of HTTP request processing threads to the number of CPUs.

Tip 7: Optimize Keep Alive subsystem
This subsystem prevents the server from being overloaded with connections. A
waiting keep alive connection has completed processing the previous request,
and is waiting for a new request to arrive on the same connection.
Three factors describe the Keep-Alive behavior. Keep-Alive timeout, Keep-Alive max connections and thread-count. Performance tuning in this subsystem highly depends on your applications needs.

Tip 8: Optimize static content delivery
If your application contains static files, it is recommended to enable HTTP file
cache to optimize performance. This should not be relevant for clusters running httpd with mod_proxy or similar in front.

Tip 9: Use default-web.xml to disable dev features
The default-web.xml file defines features such as filters and security constraints
that apply to all web applications. You should use it, to define some common constraints that are performance critic to all deployed applications. Most common two are this:


Tip 10: JDBC Tuning
Tune the steady-pool-size and the max-pool-size, and set them to the same
value. This will avoid unnecessary resizing of the pool. A general
rule of thumb is to tune the value for max-pool-size and steady-pool-size to the
same number of HTTP request processing threads.

Tip 11: Disable Access Logging
To avoid unnecessary I/O activity, disable the access

Further readings:
Sun Java System Application Server 9.1 Performance Tuning Guide

Friday, October 23, 2009

My personal #OOW09 Review

08:04 Friday, October 23, 2009 Posted by Test No comments:
Anybody is writing his personal Oracle Open World review these days. Back in Germany and almost recovered from jetlag and too less sleep it seems as if it is time for me to do the same.

This was my first trip to San Francisco and the United States in general. And this is why I hardly find any words for what has happened to me during the ten exciting days beeing oversea. It was truely awesome!
The flight took about 12h. Thank god, it was a direct flight and I did not need to transfer somewhere. After a couple of security checks in germany and too many paperwork on the plane I finaly managed to get into the United States.
Arriving late at SFO is a big advantage for starting over in Redwood City the next day.

The ACED briefing at the Oracle headquaters was my first contact with all the other great ACE directors, who also attended the Open World. Beside some very informative sessions around products and new features, we also got the chance to talk to Thomas Kurian for a few minutes.
Even if I expected to see and hear some insight persons at all, this was a huge surprise. And you can not imagine, how normal even the biggest persons look, if you meet them in a more informal environment!
To me it feels like all those "get together" things have a special power in it. My first day @oracle was a powerfull experience at all.

OOW itself began after one spare day, I could walk around SF. Even if there are fewer inhabitants in SF than in Munich, it is a huge city and you have to walk a lot, if you want to see a lot :) Inescapable for first-timers are the Pier 39 and a visit to Alcatraz. Both fits perfectly into one day and still leaves space for relaxed looking around. The Alcatraz visit was very scary at all. The great audio tour they provide, spoken by former occupants guides you through this dark piece of history. Having seen movies like "The Rock", you get the needed adjustments to history. Something, you definitely need to see by yourself.

Starting over with swollen feet into Open World and for me especially to Oracle Develop at the Hilton. I planned my sessions with the schedule builder in advance (in fact I tried to. Was a bad experience at all ...). Walking around for three days, seeing and listening to people like Linda DeMichiel (Sun Microsystems, Inc.), Roberto Chinnici (Sun Microsystems, Inc.), and many many more "big names" of Enterprise Java, was a true pleasure. What I can not complain too much about were the arrangements of the sessions at all. If you are interested in a special piece of the Oracle stack, me beeing into Application Grid and Fusion Middleware, you have to walk around a lot. The schedule builder does not realy gives you the chance to take care of your journey times. And the topics are not grouped up in one location. I missed about five planned sessions, because I really did not manage to get there in time. And that was only partly because of the many contacts you meet and want to talk to in between :) And this was also a fantastic opportunity to talk with Oracle Product Managers and engineers.

The place to be was the OTN lounge. Justin and his team did a great job on presenting the live shows and looking after the drinks and snacks for anybody :) Beside all the heavy hitters and techtalks it was great to see James Gosling hitting him for an interview, too. Big names around again and again. Next to the lounge the Unconference took place. This is, where I will give some sessions next year probably, too. And this was also the place to meet many of the ACEs around. And anybody was there to answer questions or open to interesting discussions.Thanks again to all people I meet and who made it quite easy for me to fit into the OTN community and the ACE group, to which I still consider myself a rookie. A special thanks goes out to Stanley for beeing so kind letting me carry him around after Debra's session:)

The weird things happening at OOW are probably the keynotes. Having nearly 40k delegates at Open World and 5k seats available, you have to be there very early. But it was worth it. Not only but also a big show at all. And some more big names out there, too. Scott McNealy (chairman of the board of directors of Sun Microsystems), James A. Gosling (the father of the Java), Arnold Alois Schwarzenegger (38th Governor of the state of California) and of course Lawrence Joseph "Larry" Ellison (co-founder and CEO of Oracle Corporation). You ask about the content? No big surprises this year. We saw the story around Exadata (v2). It was talked about Sun (from a very distant partner like view), IBM bashing, Fusion Apps and BPM. The things most interesting to me, could not be answered because of the ongoing EC investigation about the Oracle-Sun deal. This was somehow disappointing at all.

The last two days were filled with hardly anything. After the end of Oracle Develop, I had some time to walk around the exhibition halls and talk to some more people, I had never seen before. Very interesting topic central discussions and contacts. The friday was nearly completely filled with a special happening at the hotel. Barack Hussein Obama II dropped by to stay one night at the intercontinental san francisco. This was an adventure :) Never seen this before. And never have been in the middle of a secret service operation like this. Beside the fact, that he was not visible at all, I spend about 2 hours inside or outside the hotel willing to go outside or inside again but was stopped because of him, moving inside or outside :-)

Most of the information gathered during Open World still spend their time in my head or my harddrive. I have to work through a couple of things before posting about them. But I will do so. And there are technical things and findings to talk about in the next months. Even if I try to focus this blog on enterprise java I will definitely have a closer and hopefully early look at upcomming versions of Weblogic server and other JEE products from Oracle within the Application Grid.

Thursday, October 22, 2009

“Is Oracle good for Java?”

09:13 Thursday, October 22, 2009 Posted by Test No comments:
, , ,

There are quite some questions around at the moment, talking about the future or Java in Oracle's hands. To be honest, nobody knows about the future. At the moment, nobody even knows about the exact plans Oracle and/or Sun have about their future. What seems clear is, that Oracle is heading into the appliance direction with their products. A good example of this is the Exadata v2 maschine, presented at the Open World 2009. Some thoughts about possible Fusion Application Appliances are also out there. All this, is evidence enough for me to know Sun's hardware in save hands. But what about Software? What about Java in general. Even in the recent email interview with Mike Lehmann (Oracle) I really did get now answer at the moment about any Sun related questions. What is clear to me is, that Oracle is into standards and standardization and open source since the beginning. And even more, the Application Grid Stack forms the basis for any Oracle product. This gets all the way down to Java on Weblogic server. Why should this change?
On a midterm some dissagreements between Oralce's product strategie and other JCP members' ideas could lead to problems. Of course, there is always a lot of politics in it. And I believe, that his will not be easy, if the JCP is lead by a company making money of it's products. To me, this seems as if it is not the biggest problem to others while Sun has the lead. I'll expect this to change. And this probably even leads to a redesign of the JCP in general.

Up to now, it is in your own hands to build your oppinion about all this. Some actuall blogposts around the future of Java, Sun, Oracle and discussions about the famous Larry Ellison quote "Java speaks for itself." are around. Take a look:

Kevin Farnham "Does Java "Speak for Itself"?
Discussion Forum about this quote
Recent poll on Java.net (one third "has it's doubts")
Thoughts from Bert Ertmann
Cay Hostmann about OpenWorld

Wednesday, October 21, 2009

Mike Lehmann on #Weblogic, #JEE6 and Open Standards - #OOW09 Followup

07:39 Wednesday, October 21, 2009 Posted by Test 2 comments:
, , , ,

One of my personal highlights at Oracle OpenWorld 2009 was the OTN techcast series. Livestreaming from the OTN lounge Justin brought up some very interesting guests to talk to. I got the chance to ask some questsions during the session with Mike Lehmann. Mike is the Senior Director of Product Management, Fusion Middleware Oracle Weblogic Server and Java Plattform.
See the complete techcast here. I am asking some live questions during the last five minutes.

The whole session only last a quarter of an hour. Therefore some questions still were unanswered. I asked Mike to kindly answer them by email afterwards. That is, what he did. A big "Thank you for doing that!" goes out to Mike!

AppSrvs have become some kind of comodity these days. What do you believe are the true differentiators for weblogic server?

One of the key benefits of adopting a standard like Java EE is it levels the playing field but there continues even in the core Java server space to be quite a large number of unique differentiators just for the core application server. I will outline examples of these below. We also have seen that the architectural styles and approaches that our community is using to build applications has changed over the years and we have adopted our server infrastructure offering to address these challenges our customers are facing with a new model we call the Application Grid which we think ups the ante on perceived commoditization and potentially redefines what customers expect in an application infrastructure.

On the Java EE side, once one gets beyond the API conformance, you typically see application servers like WebLogic differentating in a number of areas. Ones that are key to WebLogic Server include capabilities like - I have chosen a few representative ones rather than an end to end list:

Development Model

Capabilities like FastSwap which enables customers to replace Java classes (add methods, fields etc) without having to go through a redeployment or bounce of the server. It is an example of a server side capability above and beyond what the JDK proper offers in this space.

- Capabilities like Shared Libraries and Filtering Classloader support that enable developers to include multiple versions of common jars within the infrastructure without impacting the runtime (e.g. xml parsers v1 and v2 or different versions of logging infrastructure or different versions of popular frameworks)

Operations Model

WebLogic Diagnostics Framework - most application servers have some sort of ability to see stack traces or see baseline metrics when executing but the ability to formally set SLA's on the infrastructure and when they are breached dump out sophisticated diagnostics images is not common at all. Certainly it is unknown or limited in open source.

Consistent and deep scripting infrastructure - WLST in WLS - This seems like such a simple requirement but ironically as you probably well know is not a capability that exists in open source or typically in very primitive fashion. WLS's scripting and automation infrastructure is extremely rich and key to what customers achieve remarkably low operational costs on WebLogic compared to writing and invent equivalents on other platforms.

Runtime Model
Capabilities like side by side deployment - the ability to deploy a new version of an application without impacting existing users on a single JVM. Not requiring complex cluster dances to enable customers to transition to the new version of the application.

Thread management with Workload Manager - most other appliccation servers are very primitive here and it is an art versus a more deterministic well understood exercise as it is within WebLogic Server.

Messaging infrastruture - here beyond the basic JMS you see in most servers, WebLogic takes messaging out of the box within a Java EE server to another level not requiring customers to buy separate JMS infrastructure because of the richness we have here. We are remarkably succcessful in the JMS side and frankly it is not only highly differentiated for our standalone messaging customers where we compete against pure play messaging vendors but also to our huge SOA install base who depend on it for capabilities such as the Oracle Service Bus and our BPM solution.

High Availability

Capabilities like Whole Server Migration and Service migration - capabilities that many other servers leave to the imagination of the adminstrator.

These are some very simple examples but represent that even in so called commodity infrastructure there is in fact a long list of features that do result in significant value add to customers choosing application servers and frankly we believe significant operational, development and administrative cost savings that simply can not be achieved by competitive solutions.

Now we have also worked on adapting to how we see our customers deploying our infrastructure. In particular with this concept called the Application Grid. We define the Application Grid as: "The application grid approach to middleware infrastructure allows a set of applications to easily react to peaks and valleys in demand and adjusts capacity to improve overall performance by optimizing shared resources. It also allows for rapid application deployment and automated adjustments—enabling greater efficiency, competitiveness, and simplification in your IT environment.' Product wise in the Java space, the Application Grid consists of three major runtime products - Oracle WebLogic Server for mission critical Java EE applications, Oracle Coherence as an in memory data grid and JRockit for high performance low latency JVM infrastructure and in the management space Oracle Enterprise Manager.

The simple way of thinking about the Application Grid is very much like RAC in the Oracle Database. RAC is all about better quality of service on commodity hardware - improving scalability, reliability and availability on large clusters of commodity hardware. This has clearly been a sensibility in the middle tier for many years but frankly most application server vendors have done little to tackle it square on to make it an out of the box feature. We have done this in several areas within the Application Grid. Two examples that are top of mind are around state management and operational management. In the area of state management as you saw from OpenWorld we talk alot about scaling infrastructure using Coherence but it is not enough simply add Coherence to your infrastructure, it has to be seamlessly integrated with your applications - in our world frequently running on WebLogic Server. In Fusion Middleware 11g we did exactly this - we introduced seamless integration for statement management via Coherence integration with WebLogic Server. We have seen results that frankly extremely compelling and validate our vision of the Application Grid such as customers achieve several fold increase in capacity off of existing hardware and others being able to scale out dramatically further than they were prior to the introduction of Coherence into their infrastructure.

On the management side our investment in Enterprise Manager as an overall strategic management platform for WebLogic and Fusion Middleware has been a great win fairly significantly differentiating us from other vendors. Our ability to not just manage single instances of WebLogic Server, not just single domains of WebLogic Server but manage across multiple datacenters we think plays to where many of our customers are going where issues like Active Passive and Active Active topologies across data centers are actively being used and evaluated by our customers. A management solution that covers that breadth is extremely important to achieve success in these topologies and is a key value proposition that underlies our vision of the Application Grid.

So a long answer to a simple question - yes, there remain a long and compelling list of differentiators for WebLogic Server proper. The evolution of what most customers are now facing in the infrastructure frankly changes the game to not just an application server versus application server but a larger scale application infrastructure problem domain where we think architectural approaches like the Application Grid redefine expectations of customers entirely.

Looking out to GF v3, comming out with a first JEE6 release in the beginning of december. What do you advice erly adopting JEE6 customers to do? Switch? Wait? For how long?

We will have to of course wait to see when Java EE 6 officially released and as you know GlassFish is the reference implementation of it. Currently the public schedules indicate that it will be released before the end of this year and we are optimistic that Sun and the JCP can achieve these goals and thus enable the rest of the industry to also update their products to be Java EE 6 compatible.

As you may know Oracle already has made big strides in WebLogic Server 10g R3 and the recent WebLogic Server 11g to areas that Java EE 6 formalizes - the lighter weight Web profile. In WebLogic Server 10g R3 we introduced the ability to install a lighter weight core WebLogic Server as an option- as low as ~170M - and the ability to turn off containers like JMS and EJB through a single command line option. You may also be aware that Oracle itself is the provider of the JPA reference implementation EclipseLink which we ship in our commercial offering fully supported. Both of these are big areas of Java EE 6 that customers of WebLogic can use today in production environments well ahead of Java EE 6 being available to achieve some of the productivity benefits that many expect to see with Java EE 6.

Of course this approach does not mean WebLogic Server is already Java EE 6 compatible. We are both active participants in the standards community closing down Java EE 6 and actively working on our next major release where we hope to achieve Java EE 6 compatibility assuming the standard comes through the standards process in a time fashion. So what do I recommend to people today? Get involved by looking what is in Java EE 6 and for an understanding of where the experience will be, take a look at what you already get with production products like WebLogic Server 11g today that are remarkably close to some of the key characteristics customers are expecting in Java EE 6.

I saw a GlassFish presentation at Oracle Develop and was impressed by the startup times. What about further reducing development round trip time for WLS developers? Do you plan to optimize this further with the next releases?

We are always very actively engaged in increasing all the performance metrics of WebLogic Server and have strict release criteria that gate our release cycles. We actively engage in both public benchmarks like the SPECjAppServer2004 benchmark - where recently at OpenWorld we once again announced a world record result on single node infrastructure - but also on key metrics like startup time, deployment time, console access time, runtime performance metrics and many more. Already our effort on a lighter weight footprint WebLogic Server does provide significant improvements for developers and our ultimate compatibility with the Java EE 6 Web profile will further improve this. We will continue to heavily invest in as a quick startup time, quick deployment time and overall development cycle is hugely important for us to continue to be credible and adopted within the developer community.

Oracle has ever been an active member of the JCP. What do you expect other companies (e.g. IBM) to do, expecting that the sun deal closes? Will they further contribute to Java or does the whole setup needs to be changed?

Oracle has a long and actively engaged relationship with the Java Community Process and plans to continue this active involvement and participation in the community. It is not possible for me to comment beyond this due to the position we are in with the acquisition of Sun.

The WLS development team is about four times bigger than the Sun GlassFish team is. From a developers point of view I do not understand, why the adoption of new specifications take that long. What about doing more technical previews with weblogic server?

It is difficult for me to comment on development team size as neither company publicly states development numbers on the core application server so this would be speculation. Clearly the Fusion Middleware development team is tackling a broader set of middleware than Sun and thus is sized to deal with that problem domain but that is much different than solving the Java EE problem domain. And correspondingly the Sun middleware team has investments beyond GlassFish proper and would have an equally difficult time with such a comparison.

I can comment on the technical previews. Oracle has historically been very active in providing technical previews probably the most notable in the recent past was with the Oracle Application Server where we actively released ahead of production and every competitor on the market support of JPA and EJB 3.0 in J2EE 1.4 conforming to the final specification. Correspondingly BEA prior to the acquisition was also aggressive in this space being one of the first commercial vendors to come to market with a preview of Java EE 5.0 support. We would like to continue this going forward and our investment in developing EclipseLink in open source where daily snapshots of the software are available by the very nature of the development process are a great example of this. Bottom line: both Oracle pre-BEA and BEA pre-Oracle actively engaged the developer community with technical previews, we hope to continue that going forward.

How do you see the future of WLS within Fusion Middleware? Will it continue to be the fondation, but still be available as a solid standalone product? Or will the integration into the stack finally lead to a highly optimized Oracle Applicationserver (again)? And what would be your wish about the future?

We see WebLogic Server as both a compelling standalone product as it is today and also as the foundation of Fusion Middleware as it is today with Fusion Middleware 11g. Generally we see the roadmap of WebLogic Server in three dimensions:

1. Just Enough Application Server - this is aimed at the light weight, agile Java EE profile nature we see developers evolving to today and is represented nicely by the Java EE 6 Web profile and Oracle long investment in OSGi as a key modularization technology for application servers. Areas here include not only the runtime but deep integration into build, test, and continuous integration and qa environments - aimed at the full development lifecycle not just the core server infrastructure. This has applicability for the general standalone WebLogic Server market as well as customers adopting Fusion Middleware who want fast, lightweight development and deployment environments.

2. Large Scale Shared Services Infrastructure - this is aimed at customers who are deploying WebLogic Server in large deployments both large clusters and across multiple datacenters with an cost of operations that is significantly less than any other competitor on the market. A different mind set around extremely efficient and automated administration, operations and management has to be built into the product than that of working in smaller clusters like other more simply API compliant servers. Again this has huge applicability to our general standalone WebLogic Server market where this is a hard requirement but also our customers who are adopting Fusion Middleware across their enterprise.

3. Fusion Middleware and Fusion Applications - Clearly as you note, we have a clear business incentive to make WebLogic Server the best application server for Fusion Middleware and Fusion Applications. Ironically while some folks think this could be seen as a bad thing for standalone WebLogic Server customers, I tend to look at it as the opposite: Fusion Middleware and Fusion Applications represent some of the most challenging and functionally rich software infrastructure on the planet and an application server that is capable of running these sets of applications and infrastructure has unique and differentiated capabilities for our customers who also need a rock solid, proven infrastructure for their equivalently challenging and feature rich application infrastructures.

I think this is a challenging mission so when you ask for my wish for the future, it is to deliver on this mission. Oracle WebLogic combined with the Oracle organization that continues to have a world class engineering team that is uniquely positioned to change the industry's view of what application server infrastructure by executing against this set of goals.

Some customers complain about "vendor lock in" things and sometimes they switch to open source appservers. What would you tell those customers? why should they further invest into Weblogic?

Oracle has long had the mantra that there is a difference between open source and open standard. Open standards are one that are developed in conjunction with participants from the entire industry - commercial and open source vendors/participants. Java EE is a great example of this. Open source is a different approach - effectively making the source code available and in a number of cases, like with commercial offerings, can and do step up to being compatible with open standards.

WebLogic Server is a Java EE compatible server and as such applications developed on it that are conformant to Java EE standards have the optional choice and risk reduction strategy of being able to deploy on other Java EE compatible application servers. If customer decides to develop on an open source server and adopt a non-open standards framework (e.g. not Java EE) then they are taking on a risk that they may be locked into that server and unable to migrate unless they re-write their application. Some customers take this risk and face the challenge of those vendors - as you have seen in the open source market - being acquired and the resulting lack of certainty over the future of these non-open standard approaches. With Oracle because of corporate wide mandate and commitment to open standards as long as customers are building to standards like Java EE they have a strong certainty that they can mitigate any risk of vendor lockin by looking to alternative application servers.

Oracle also understands the attraction of open source - particularly since some areas of open source evolve faster due to lack of overhead associated with reaching a consensus across all major industry players and that can be sometimes advantageous to bring to market some technologies. This was particularly apparent in the web framework space with Apache Struts many years ago and Spring more recently. This is why in conjunction with a strong adherence to open standards you have seen Oracle actively participate and support open source projects be it contributions such as Apache Trinidad, EclipseLink (both standards and open source - ) or Spring (our contribution of WebLogic transaction integration to the project and Spring Pitchfork) or finally our Ecliplse Plug ins for Java EE (Oracle Enterprise Eclipse Pack [OEPE]). Our contributions in open source are actually fairly unique and are exemplified by EclipseLink. You will see that EclipseLink is not a fork from our commercial offering - it is one and the same. This is the same with OEPE where we develop in open source and ship it/support it as the commercial offering within our software packaging.

Bottom line: We believe we have the best open standards server implementation on the planet and agressively are standards compliant. We are also strong believers in open source and actively participate in numerous communities supporting open source development. Our efforts are backed by a development organization, support organization and sales organization who strongly believe in this mission, so we believe investing further in WebLogic Server is frankly in customers best interest and gives them the benefit of world class, standards based infrastructure with maximum risk mitigation while leveraging the best open source has to offer.

What would be your personal favorite feature of Weblogic 11g if you could make a wish?

I have been quite fond, as you have heard me speak at OpenWorld, of a feature we call ActiveCache which is the direct integration of Oracle WebLogic Server and Oracle Coherence to manage state in a separate tier from WebLogic Server. We see this giving pretty substantial benefits to our customers - reported benefits of doubling capacity on the same hardware as an example - for a remarkable simple and declarative change to ones application infrastructure. Coherence seriously changes how one can write applications when one takes the leap that you have a completely reliable and redundant in memory data grid available to your applications like you do with ActiveCache. We have seen customers using WebLogic and Coherence go from using it for basic state management to simple caching to using it for architectures where data is lazily written to back end databases to enable even more capacity into processor bound backend infrastructures and finally to complex computational risk analysis on that same in memory data. A truly exciting an unique technology that I think we are just seeing a small taste of what we will be able to do with it in coming releases.

What does the OTN Community mean to you? And how do you try to integrate or take advantage of their feedback?

OTN is of huge value to my team as product managers planning releases of WebLogic Server and our engineering team as they work on individual features. There are literally millions of developers who participate in OTN in numerous ways - forums, contributing articles, wikis, contributing code samples and directly feeding back to product teams. We as the product teams use it constantly as vehicle to developers with podcasts, blogs and participation in forums. We frankly have a lot of difficulty keeping up because it has grown so large - I think because of the quality of material and the quality of the community - but fortunately we have not only ourselves within Oracle to scale it we also have programs such Oracle ACE Directors where our top users also become very active and well known within the community and contribute and guide discussions.

Tuesday, October 20, 2009

Magic Quadrant for Enterprise Application Servers - Gartner

06:47 Tuesday, October 20, 2009 Posted by Test No comments:
, , , , , ,
Gartner takes a look at the current application server landscape and places Oracle in the "Leaders" quadrant. Compared to former MQs this is a slightly worser performance for Oracle/BEA at all.

In the circumstances of continuing consolidation of the market [...] and the simultaneous pressures of the economic recession [...] the leaders in this market have notably separated from the rest of the competitors.

Oracle's EAS offering includes the strategic Oracle WebLogic Server (WLS) family of Java EE 5-compliant products, deriving from the 2008 acquisition of BEA Systems and the internally developed J2EE 1.4-compliant Oracle Application Server (still supported but not strategically promoted anymore). The WLS product line includes WLS Standard Edition, WLS Enterprise Edition and the WebLogic Suite, which bundles extra capabilities like the Oracle Coherence distributed caching platform, extended management capabilities, WebLogic Real Time (an enhanced version of Oracle's JRockit JVM) and WebLogic Operations Control for application virtualization. Other products that play an integral part in Oracle's EAS offering include the Oracle JDeveloper integrated development environment (IDE), the Oracle TopLink object/relational mapping tool and Oracle Enterprise Manager for advanced monitoring, administration and management. The popular Oracle Application Server is supported for maintenance purposes, but Oracle doesn't plan for major evolutions and actively encourages users to replace it with the strategic WLS product, by means of specific migration tools.

If completed, the anticipated acquisition of Sun (still pending due to certain conditions, including clearance from the European Union at the time of publication of this Magic Quadrant) will further extend Oracle's portfolio of EAS-related technologies. In particular, crucial for the future of the Java-based EAS market will be Oracle's strategy about Java technology and the Java Community Process, of which the company will gain ownership and control. Oracle's strategy about Sun's open-source GlassFish application server, which Oracle will probably position as the entry level of its EAS family of technologies, will also have a strategic relevance from an industry perspective by being the product reference implementation of the Java EE standard.

  • WLS is a comprehensive EAS offering sitting at the foundation of Oracle Fusion Middleware (OFM) — Oracle's strategic application infrastructure stack — and Oracle's packaged application business products. WLS is primarily focused on enabling business-critical applications, but is able to support a wide range of user requirements, from small to midsize business-oriented packages to advanced XTP-style applications via Oracle Coherence, one of the leading products in its category.
  • BEA Systems was able to build, since 1998, a market share coleadership that was maintained for many years and that has generated a wide and loyal installed base (in the order of many tens of thousands of deployed instances of WLS products), a large industry following and massive third-party support. This adds to the notable Oracle Application Server customer base accumulated by Oracle since its entry in the market in 2001.
  • WLS is a widely proven, state-of-the-art, Java EE 5-compliant and OSGi-enabled product that is supported by a visionary road map covering compliance with the future Java EE 6 and dynamic "SOA inside" modular architecture, support for multiple programming models (e.g., SCA, OSGi/Spring, Scala), massive scale-out capabilities and autonomic/rule-based management, specialized event-processing server technology, support for XTP architectures, and extensive use of metadata and virtualization/cloud capabilities.
  • Both WLS and Oracle Application Server are frequently used to support opportunistically oriented products. However, pending the Sun GlassFish integration in the offering, Oracle doesn't yet have specific EAS products focused on addressing the fast-productivity, low-cost requirements of mass-market developers, nor does it support Web 2.0-style or opportunistically oriented application projects.
  • The demotion of Oracle Application Server to a nonstrategic role creates opportunities for both closed-source and open-source Java EE vendors. Should the transition to WLS prove too expensive or too difficult or undesirable for other technical or commercial factors, competitors may be able to attract Oracle Application Server customers (especially those not locked into Oracle via packaged applications or other OFM layers).
  • Despite Oracle's track record in managing acquisitions, the many potential challenges of the forthcoming acquisition of Sun may distract Oracle's management or slow down the company's EAS plans, and may create new business and technical discontinuities.

Sun Microsystems
Sun's core EAS is its open-source GlassFish Java EE 5 Application Server. A Java EE 6 preview is also available in GlassFish Application Server v.3 Preview. The technology is the Java EE reference implementation and is available for free download from Sun. The road map for all offered products is subject to review after Oracle's acquisition of Sun.

This biggest strength from Gartners point of view ist the industry leadership in defining Java and Java EE standards. It injects Sun into all Java-related industry initiatives, while a strategic all-company commitment to the open-source software distribution model differentiates Sun from most Java competitors.

One of the Cautions for Sun Microsystems states, that the pending acquisition by Oracle deters many prospects from committing to Sun software offerings.

(Source: Gartner MQ)
Read the full MQ at Gartner.

Monday, October 19, 2009

Thursday, October 15, 2009

Preview: WebLogic DM Server - WebLogic Server Architecture, OSGi and Java Enterprise Edition

17:56 Thursday, October 15, 2009 Posted by Test No comments:
, , ,
I attended a session by Adam Leftik and Jeff Trent at this years Oracle OpenWorld. It was all about the future of weblogic server and some upcomming features. As usual this has been presented under the standard disclaimer which states, that it is only an outline of the general product direction and no commitment to any features at all. Anyway, I strongly believe that this gives quite a good overview about what is happening to the next Weblogic Server major release.
Oracle WebLogic DM is comming!

WebLogic 10gR3 surfaced a preview of server profiles, and some of the underpinnings to support the profiles which were put in place. For example, the console is already capable of dealing with the profiles (i.e., the absence of a full EE server). So a WebLogic DM Server profile can coexist inside of a WebLogic domain, alongside an EE profile. Both profiles will share the same OSGi-based microkernel, the management capabilities, and lifecycle support. The common microkernel and the investment in modularity allow for examining other packaging options – for example, a messaging profile.

  • OSGi provides a lightweight and robust service oriented modularity framework for Java.
    Enabler for the next generation of Java server infrastructure
  • WebLogic DM is a server environment that allows users to provision infrastructure services based on their application dependencies
  • WebLogic DM also provides enterprise quality programming model and associated runtimes
  • WebLogic DM leverages WebLogic Server OA&M infrastructure for next generation Data Center deployments

  • Currently prototype targeting next major release of WebLogic Server in 2010/2011

Monday, October 12, 2009

OOW in Numers

17:33 Monday, October 12, 2009 Posted by Test No comments:
1966 Sessions on OOW, 5 Content Streams, 314 Demo Kiosks, 4500 Oracle Experts, 81.266 Hotel Rooms, 170.000 Cups of coffee :)

Oracle OpenWorld Live

00:21 Monday, October 12, 2009 Posted by Test No comments:
, ,

Watch the best of live programming from Oracle OpenWorld, including major keynotes, Q&A with OTN Heavy Hitters, special editions of TechCast, technical keynotes and sessions and more.
Live programming
Sunday 10/11: 12:30 p.m. - 7:00 p.m. PT
Monday 10/12, Tuesday 10/13, Wednesday 10/15: 8:00 a.m. - 5:00 p.m. PT

Replay programming
Monday 10/12, Tuesday 10/13, Wednesday 10/15: 5:00 p.m. - 8:00 a.m. PT

Friday, October 9, 2009

Tuesday, October 6, 2009

Oracle OpenWorld 2009 - pictures and tweets

12:38 Tuesday, October 6, 2009 Posted by Test No comments:
, ,
I am departing the day after tomorrow. SF I am coming! Even if I do not know about how and when I will have internet access, I still try to post some updates from my Oracle OpenWorld 2009 visit.

TwitPic updates on OOW09


Or follow my tweets:

Twitter updates on OOW09

    follow me on Twitter

    Jim Driscoll about JSF 2 and Ajax

    08:45 Tuesday, October 6, 2009 Posted by Test No comments:
    , ,
    Jim Driscoll has been at Sun for over 13 years, ever since he joined JavaSoft to work on the Java Web Server and the first version of Servlets. At various times, he has been the manager of the J2EE RI, the Java Web Services Developer Pack, and a host of Open Source, web and XML projects that Sun has either participated in or led. His current job title is Senior Engineer, on the JavaServer Faces team, and he has been specializing in Ajax.
    (Source: Jim's Blog)

    Friday, October 2, 2009

    JSF, Facelets, Myfaces and Richfaces Performance Tuning

    12:18 Friday, October 2, 2009 Posted by Test 4 comments:
    , , , ,
    I often come across the same issues in projects. One very hot topic is performance.
    Beside the things you should do to garantee performance during the development process,
    you are often left alone with tunings for frameworks. Good examples are the widly used JSF
    frameworks Myfaces from Apache and Richfaces from JBoss.

    I tried to sum up some of our performance findings during the last profiling and tuning sessions.
    Happy to hear your ideas and best practices on that, too.

    Myfaces General Performance Tuning

    If you use the MyFacesExtensionsFilter you can start optimizing here.
    It buffers and parses the response on every request.
    You can disable this, and still gain all functionality the ExtensionsFilter is providing,
    by doing the following.

    If you use myfaces the traditional way, you end up having all resources needed for your components
    beeing loaded in separate includes. You could optimize this using the following context param:


    The only thing to do now is get rid of the <HEAD> tag in your HTML, and instead use Tomahawk's <t:documentHead/> tag.
    Of course, your <f:view/> tag has to enclose your <t:documentHead/> tag for this to work. Now
    all resources needed by your components get loaded in one single file.

    Think about using an optimized sirialization provider. (Following example is for JBoss)


    Server Side State Performance Tuning

    There are a many settings you can enable in your web.xml file to make MyFaces perform well.

    JSF components tree state takes big enough memory. In the server-side
    state saving ( default JSF behavior ) these objects are stored in the
    session. For a many concurrent user connections every user gets own
    session object.

    In general serverside state saving is more performant than the client side. You also get lower
    page sizes and faster loading times with this.


    If your performance is ok, but you have memory problems try to switch to the client-side state saving.


    If this is not enough, you could disable serverside state compression. Compression always
    takes time. If you have enought memory, try this one:


    Very important, too, is to disable the serialization of state, serialization and deserialization of the component tree is a major performance hit.


    If you find that memory is a constraining factor, then reducing the number of views stored in the session might help. The setting is controlled by:

    Only applicable if state saving method is "server" (= default).
    Defines the amount (default = 20) of the latest views are stored in session.

    Sun-RI Performance Tuning

    You should increase response buffer (to reduce reallocations at render time)


    Think about using an optimized serialization provider. The following example is a JBoss provider (code here)


    Facelets Performance Tuning

    If you don't want to store too many state in either the server or the client, another possible
    solution is to allow Facelets to build view before request processing instead of state saving.
    But be warened about some unpredictable side effects. Use web.xml init parameter
    together with the attribute.


    The ultimate solution for solving session state memory or performance problems is to create a custom
    aceletsViewHandler subclass with special state handling where needed.
    The custom handler could , for example, call buildView method instead of real restoreView
    procedure for pages that typically do not need state (e.g. menue, navigation).

    Facelets library in the "debug" mode stores information about
    components and beans up to 5 times for an every user. You should disable this in production mode!


    You should increase response buffer (to reduce reallocations at render time)


    You should also turn of the facelets refresh trigger in production environments.


    RichFaces Performance Tuning

    Most filters use buffering for request processing. According to the
    profile information, these buffers took big enough memory in the
    application. Therefore you should limit the size for the RichFaces Ajax filter, too.


    For a production server, it makes sense to reduce the value to a real page
    size or even remove that parameter at all.

    Richfaces comes with some build in parsers to ‘tidy’ all HTML HTTP Responses so that they are valid
    XHTML (thus XML compliant). This is needed as dynamic DOM updates in the browser need correct XML.

    Of course, parsing HTML incurs a performance overhead.
    This can be minimized by setting the forceparser setting to false. In that case only AJAX responses will be ‘tidied’. In the other case all JSF responses are ‘tidied’.

    <display-name>RichFaces Filter</display-name>

    TIDY xml filter is DOM-based, thus it requires a lot of memory. It
    would be better to use more optimized "NONE", "NEKO" ore "TIDY" should be the second and third best choice. The following example shows that ORDER parameter defines the order in which particular filter types are used for pages code correction.


    You can even set sets of pages for which the filters should apply. The following example applies the NEKO filter to all URLs.


    Before the version 3.1.3, RichFaces loaded styles and script on demand. I.e. files are loaded only if they are required on a particular page. Since RichFaces 3.1.3, it's possible to manage how the RichFaces script and style files are loaded to application.
    Using the web.xml org.richfaces.LoadScriptStrategy setting, you can tell Richfaces to either:

    * Load ALL script in one file.
    * Load NONE scripts (you do it yourself instead - eg. in the manner prescribed by your book).
    * Load scripts when needed (the DEFAULT).



    If you use LoadScriptStrategy ALL, turn the compression off like it shown in the code snippet above

    Some basic JSF performance principles

    • Never put logic into your getters. They are called multiple times and should only return something already populated by another method. For example if you are chaining drop-downs together use an a4j:support tag on the first one with an action attribute that loads the data which is then retrieved when you reRender the second one.
    • Use the ajaxSingle="true" unless you actually want to send the whole form back to the server.
    • Don't use a rich component if you only need a normal one. For example don't use rich:dataTable unless you are making use of some of the features that it has over and above h:dataTable.
    • Consider using immediate=true attributes on elements where you do not need validation
    • Avoid displaying large tables to user. Use pagination
    • Do not over complicate EL expressions, code them in Java in backing bean

    Web Dynpro for Open Source?

    06:52 Friday, October 2, 2009 Posted by Test No comments:
    , , ,
    First of all, I would like to state, that I am not a real big fan of SAP. From a technology point of view only. This changed slightly with the avalability of SAP applicationserver Java 7.x. This was the first appserver which has a satisfying standards compliance and a fast behaviour from a developers point of view. Beside this, I always liked the Netweaver Developer Tools for Java. Based on Eclipse the "Workbench" was always comparable to other vendors products or even products from the open source community. If you ever did SAP development with Java, you probably came across another favorite of mine. The WebDynpro framework for Java. Beeing a composite and sophisticated framework for UI development it gave SAP applications a common look and feel in the Java world. As you might have guessed this is only true for the NetWeaver platform. Running it outside their own applicationserver was not possible. Very frustrating at all. This again forces you to keep special knowledge about another framework up to date to deliver value. As a developer you already know about thousands of other solutions to keep track with.
    Now things seem to move on with this. A recent blogpost from Benny Schaich-Lebek, a product specialist at SAP NetWeaver product management gave voice to the community and wrote about his thoughts about WebDynpro for open source.

    To make it very clear: I'm not in the place to decide for such a step, I'm not even working for Web Dynpro itself. I'm more like a catalyst here, giving voice to the community who does not want to confront SAP with a maybe uncomfortable wish. Let me say so much: many people inside the company likde this idea very much.