Archive for October, 2008

07
Oct
08

WebSphere Performance Monitoring Infrastructure (PMI)

For the next weeks I’ll be posting some feedback about my experience on using WebSphere PMI tool. It is an incredible tool for performance tuning. Basically it frees you from plugging a CPU intensive profiler (that is also usually hard to setup) and lets you see (for example) performance data such as waiting and use time for connections inside a pool. Still there are cases when you need to see information in bits as it is available on a profiling tool such as Eclipse TPTP.

JCA posts have been updated, I have made some changes about ManagedConnections and Connection Handles interaction in the Foo Connector. For those who have read the previous version of the post I suggest re-reading it.

Still on the performance topic there is one phrase atributed to Donald Knuth that is worth mentioning:

“We should forget about small efficiencies, say about 97% of the time: premature optimization is the root of all evil.” (Knuth, Donald. Structured Programming with go to Statements, ACM Journal Computing Surveys, Vol 6, No. 4, Dec. 1974. p.268.) Wikipedia – Optimization

Advertisements
06
Oct
08

matchManagedConnections short tip

Be aware that the container may send invalid connections to the matchManagedConnections method and if you happen to return any of the invalid connections it’ll give it back to the application. This check is important since connectionErrorOccurred is only safe to be called while connection is in use. Some containers have optimizations that deny you from calling while connection is not in use by the application (more exactly while in the pool).

So even if your ManagedConnectionFactory implements the interface ValidatingManagedConnectionFactory you should also check for invalid connections during the selection of a matching connection inside matchManagedConnections method.
The getInvalidConnections method usually is called after one connection has been detected as invalid (after a valid call to connectionErrorOccurred) or by a container timer thread (on WebSphere this timeout is specified in the reap time parameter).




ClustrMaps

Blog Stats

  • 359,406 hits since aug'08

%d bloggers like this: