Ivan Smirnov’s Blog

October 31, 2009

Update on Alphablox in WebSphere Business Monitor

Filed under: Uncategorized — Tags: , , , , , — ivansmirnov @ 11:58 AM

Earlier this year I blogged about installing Alphablox as part of WebSphere Business Monitor. Real production environments require clustering, and it was difficult to accomplish. Using DB2 on z/OS for data repository was particularly daunting task. Mike Killelea commented on my original post, noting that IBM disclaimed support for this scenario.

This time of the year, IBM is preparing version 7 of its BPM stack for release. From what I saw, Alphablox is much better integrated into Business Monitor (BAM). Remember, until now you had to run a separate Alphablox installer (with the exception of non-production-grade standalone profile). Now, ABX install is fully integrated. I specifically inquired about z/OS database support and was told that it is ON. I’ll post an update when I learn more.

October 19, 2009

Eliminate spurious orbtrc files on WebSphere client when using HTTPS tunneling

Filed under: Uncategorized — Tags: , , , , , , , — ivansmirnov @ 8:42 PM

When using WebSphere Application Client (J2EE, thin or pluggable) to access EJBs on WebSphere Application Server, an optional ORB trace file may be created. You can specify trace file location and name, but if you do not, default file name is orbtrc.timestamp.txt (e.g. orbtrc.10112009.1815.37.txt)
Of course, oftentimes you do not want any trace, and you certainly can turn tracing off. Well, with one exception. If you are using HTTP tunneling with SSL (HTTPS tunneling), trace file will be created automatically with the default name. This behavior has been known to affect several versions of WAS. I last confirmed it in WAS 6.1.
This may be annoying or inappropriate in some client environments. As a workaround, redirect trace output to null device by adding the following parameters to your client JVM command line:
for Windows
-Dcom.ibm.CORBA.Debug.Output=nul:
for Unix/Linux, use /dev/null.

October 18, 2009

No driverType in Oracle JDBC driver

Filed under: Uncategorized — Tags: , , , — ivansmirnov @ 9:19 PM

Database access in WebSphere Application Server is performed through JDBC Providers. JDBC Provider is a configuration element specifying JDBC driver class. For actual database access, one creates Data Sources underneath a JDBC Provider.
At runtime, the first time a data source is accessed, corresponding JDBC Provider is activated. At this time, WebSphere logs a series of informational messages detailing JDBC Provider version and configuration. One of the messages you can see in SystemOut log is DSRA8208I, which Infocenter documents this way:

DSRA8208I: JDBC driver type : {0}
Explanation: The JDBC driver type.
User Response: The JDBC driver type is now used by applications.

Driver type is JDBC driver type and nowadays almost universally equals 4 (pure Java).
When DB2 provider is in use, you might see this:
DSRA8208I: JDBC driver type : 4

However, with Oracle provider the message shows an empty driver type, which may cause confusion or concerns :
DSRA8208I: JDBC driver type : ""

What happened here? Has the driver loaded incorrectly or is unrecognized? Don’t worry. There is no reason for alarm – Oracle provider does not have “driverType” parameter and so this value is always empty with Oracle.

September 12, 2009

Stateful Session Bean failover performance in WebSphere Application Server

Filed under: Uncategorized — ivansmirnov @ 10:58 PM

Students of EJB specification may remember that it describes Stateful Session Beans (SFSB), a mechanism to preserve state in EJB container. This feature was not popular, as state is mostly handled in Web container in JEE applications, with EJB container providing stateless services. WebSphere Application Server, being a superb J2EE container, supports SFSB. Beginning with WAS version 6, when deployed to a clustered environment, you can enable SFSB failover, so your valuable state is not lost when an EJB container goes down for any reason. It is a telling indicator of low demand that this feature was not available in WebSphere until version 6 (J2EE 1.4 / J2SE 5), which came out in late 2004. SFSB failover in WAS is implemented through bean passivation. After each method call, bean is passivated, which requires serialization. Serialized object is then distributed to other EJB containers in the same cluster. Unlike HTTP session replication, tuning optimizations, such as time-based writes, are not available for SFSB failover. It is all or nothing: either you have no replication/failover or you incur overhead of inlined passivation on every call. Resulting performance is predictably poor. And I can not really blame IBM for not polishing a feature that is in apparently little demand. Another reason for you to stick with HTTP sessions and avoid SFSB.

July 5, 2009

Coexistence of WebSphere Business Monitor and Process Server 6.2

Filed under: Uncategorized — Tags: , , , , , , — ivansmirnov @ 9:56 PM

If you installed WebSphere Business Monitor (aka BAM) version 6.2 into the same directory as Process Server or WESB 6.2, you may run into problems with overlapping OSGI plugins.
Your WPS/WESB modules and mediations could fail with JXPath error like this:

[5/18/09 19:25:21:744 EDT] 0000005f ExceptionUtil E CNTR0020E: EJB threw an unexpected (non-declared) exception during invocation of method "transactionRequiredActivitySessionNotSupported" on bean "BeanId(TestFanoutApp#TestFanoutEJB.jar#Module, null)". Exception data:
Mediation primitive failure:
Mediation primitive: FanOut1
Component: TestFanout
Module: TestFanout
com.ibm.wsspi.sibx.mediation.MediationBusinessException: CWSXM3752E: Error using XPath expression [Ljava.lang.Object;@7d6e7d6e to locate repeating element: org.apache.commons.jxpath.JXPathException: No value for xpath: /body/print/input/orders. This has been reported by the following entity: ID=FanOut1,Request,print,PrintOrder,http://TestFanout/PrintOrder,TestFanout,TestFanout
at com.ibm.ws.sibx.mediation.primitives.util.ExceptionHelper.newMediationBusinessException(ExceptionHelper.java:128)
at com.ibm.ws.sibx.mediation.primitives.fan.FanOutMediation.locateRepeatingElement(FanOutMediation.java:726)
at com.ibm.ws.sibx.mediation.primitives.fan.FanOutMediation.performNonAggregationMediate(FanOutMediation.java:593)
at com.ibm.ws.sibx.mediation.primitives.fan.FanOutMediation.mediate(FanOutMediation.java:265)
at com.ibm.ws.sibx.scax.mediation.engine.JavaMediationPrimitive.performInvocation(JavaMediationPrimitive.java:630)
at com.ibm.ws.sibx.scax.mediation.engine.JavaMediationPrimitive.invoke(JavaMediationPrimitive.java:352)
at com.ibm.ws.sibx.scax.mediation.engine.MediationPrimitive.invokeConnections(MediationPrimitive.java:318)
at com.ibm.ws.sibx.scax.mediation.engine.JavaMediationPrimitive.fireOutputTerminals(JavaMediationPrimitive.java:728)
at com.ibm.ws.sibx.scax.mediation.engine.JavaMediationPrimitive.performInvocation(JavaMediationPrimitive.java:650)
at com.ibm.ws.sibx.scax.mediation.engine.JavaMediationPrimitive.invoke(JavaMediationPrimitive.java:352)
at com.ibm.ws.sibx.scax.mediation.engine.MediationPrimitive.invokeConnections(MediationPrimitive.java:318)
at com.ibm.ws.sibx.scax.mediation.engine.Input.invoke(Input.java:138)
at com.ibm.ws.sibx.scax.mediation.engine.RequestFlow.invokeFlow(RequestFlow.java:132)
at com.ibm.ws.sibx.scax.mediation.engine.MediationFlow.invokeRequestFlow(MediationFlow.java:145)
at com.ibm.wsspi.sibx.mediation.flow.ejb.MediationFlowBean.invokeRequestFlow(MediationFlowBean.java:231)
at com.ibm.wsspi.sibx.mediation.flow.ejb.EJSLocalStatelessTestFanout_c53bef64.invokeRequestFlow(EJSLocalStatelessTestFanout_c53bef64.java:127)
at com.ibm.ws.sibx.scax.mediation.component.ejb.EJBMediationFlowComponentImpl.invokeRequestFlow(EJBMediationFlowComponentImpl.java:223)
at com.ibm.ws.sibx.scax.runtime.handler.MFCImplementationHandler.processMessage(MFCImplementationHandler.java:199)
at com.ibm.ws.sca.internal.message.impl.MessageDispatcherImpl.processMessageWithPCI(MessageDispatcherImpl.java:715)
at com.ibm.ws.sca.internal.message.impl.MessageDispatcherImpl.processMessage(MessageDispatcherImpl.java:1167)
at com.ibm.ws.sca.internal.message.impl.ManagedMessageImpl.process(ManagedMessageImpl.java:843)
at com.ibm.wsspi.sca.ejb.module.impl.ModuleSessionBean.processUOWMessage(ModuleSessionBean.java:336)
at com.ibm.wsspi.sca.ejb.module.impl.ModuleSessionBean.transactionRequiredActivitySessionNotSupported(ModuleSessionBean.java:315)
at com.ibm.wsspi.sca.ejb.module.EJSLocalStatelessModule_43132892.transactionRequiredActivitySessionNotSupported(EJSLocalStatelessModule_43132892.java:233)
at com.ibm.ws.sca.internal.uow.handler.UOWStrategyImpl.transactionGlobalActivitySessionFalse(UOWStrategyImpl.java:311)
at com.ibm.ws.sca.internal.uow.handler.JoinUOWHandler.processMessage(JoinUOWHandler.java:165)
[snip]

Or you may have classloading problems when trying to work with monitor models.

Same issues may occur with fixpack 1 of both products (WPS/WESB 6.2.0.1 and WBMonitor 6.2.0.1)
This is happening because WPS/WESB and WBM/BAM each comes with its own version of JXPath libraries. A fix for this issue will soon be publicaly available from the monitor team. It would restrict visibility of JXPath library packaged with WBM to monitor code.
If your symptoms match, please ask IBM support about JR33245.

June 7, 2009

Database creation script for Alphablox install

Filed under: Uncategorized — Tags: , , , , , , — ivansmirnov @ 9:28 PM

Suppose you install Alphablox, say as part of WebSphere Business Monitor product. Alphablox has been and still remians (as of version 6.2) an important integral part of WBM, providing dimensional analysis of monitored data and KPIs. Alphablox requires a number of database objects to function. By default it will attempt to create database tables it needs upon first run. But what if you are using DB2 for z/OS or another restrictive database environment, where programs are not allowed to run DDL. DBAs hold the keys to database structure and you are required to submit any DDL to a DBA for review and execution. Not unreasonable for a structured corporate IT where I’d expect to find WebSphere Business Monitor.
So you want to get your hands on DDL Alphablox would attempt to execute and hand it your DBA. It is possible, even though scripts are not on the surface as they are for the rest of WBM (or othe products in Business Process Management stack).

While scripts do not exist in a form of standalone DDL files, DDL statements are available. Just inspect properties file named $ABX_ROOT/repository/servers/$dbtype.dmlsql, where $ABX_ROOT is the root of Alphablox installation directory and $dbtype is your database type, e.g. db2_zos.dmlsql
Look for properties named DDL.CREATE1-DDL.CREATE6 and DDL.INDEX1-DDL.INDEX10

You will find entries like this:

DDL.CREATE1            = CREATE TABLE ABX_VERSION (DESCRIPTION VARCHAR(32) NOT NULL, VALUE VARCHAR(64) NOT NULL)

This is not a complete script, of course. You will have to add things like tablespaces and permission grants, but all it is exctly what program needs.

DROP statements and a number of updates/inserts round out this file.

May 4, 2009

Cloudburst: My refrigerator runs WebSphere

Filed under: Uncategorized — Tags: , , , , , , — ivansmirnov @ 8:17 PM

IBM has pre-announced WebSphere Application Server Hypervisor Edition and WebSphere Cloudburst appliance. I understand both will be officially made available during SOA Impact this week. WAS HE is application server in a VM image. Cloudburst is even better – it lets you have your application server in an appliance. Remember “my coffee maker runs Java?” Well, now your refrigerator runs WebSphere! WAS ND is pre-installed and you have an option to turn on Feature Packs with a simple checkbox. While at this time there are only 2 publicly available Feature Packs for WAS 7 (SCA and Web 2.0), another one is on its way (XML, which will include XML Schema 2.0, XPath 2.0 and XQuery 1.0). Profile creation is also included – just choose which profile you want. This way, after a few minutes of initial configuration you have a working installation of WAS ready to run.

This is a very interesting move by IBM, building on success of their DataPower line of appliances, which expanded from original 3 models to current 5 with recent addition of B2B gateway (XB60) and low-latency messaging appliance (XM70). Now, this new form factor comes to the application server world. Both WAS HE and Cloudburst will help dramatically reduce environment creation overhead. Now server environment can be stood up in a very short time.

While WAS HE and Cloudburst may be used together, this is not the only way. One could say that they represent opposite ends of the software “hardness” specter. Cloudburst is clearly out there on the “hard” side. But WAS HE is just a VM image, which may be brought online when needed. When no longer necessary, it can be shut down and left to wither on a backup shelf. This gives organizations ability to manage server capacity easier.

Cloudburst, advertised as a “private cloud” solution, can be deployed in more “mundane” implementations having nothing to do with clouds at all.

It would be interesting to see if this move leads to more appliance offerings. I’m thinking next in line will be widely used software running on WAS – Portal and Process Server.

UPDATE 5/6/2009: Feature Pack for XML is now available as an open beta here.

May 1, 2009

Split by delimiter in IBM’s WebSphere adapter for Flat Files or Who owns the fence?

Filed under: Uncategorized — Tags: — ivansmirnov @ 10:03 PM

IBM’s adapter for Flat Files features an ability to split files as they are read in, either by size or by a delimiter. For the sake of completeness, I should mention that splitting is also possible in outbound adapter (when writing files). But today I’d like to focus on more interesting case of inbound adapter. In general, splitting feature deals with a situation when your incoming files might be a concatenation of units you’d like to process one at a time.

When splitting inbound files at a delimiter, Flat File adapter provides an option to include the delimiter in resulting objects. This is akin to looking at land lots separated by fences and asking whether someone owns the land under the fence. Decision on including separators depends on their nature. If input combined file includes artificial separators between individual units (e.g. “***SPLITMEHERE***”), you should not include separators. On the other hand, if you use a distinct start- or end-of-file signature as a separator (such as “<?xml version=”1.0”?>), separator is an integral part of each unit and must be included.

And so you decided that you want to include the separator.

Split by delimiter in Flat File adapter Export

But how do you specify whether the separator should be included at the end of the previous unit or at the beginning of the next? Assume your separator is “<?xml “, look at this section of the file:

</Widget>

<?xml version=”1.0”?>

<Widget xmlns…..

In which unit do you think this “<?xml” separator belongs? In other words, which is right: this

</Widget>

<?xml

[split]

version=”1.0”?>

<Widget xmlns…..

Or this

</Widget>

[split]

<?xml version=”1.0”?>

<Widget xmlns…..

The answer is obvious to you from context, but how will the Flat File adapter answer the same question? From Flat File adapter’s perspective, who owns the fence between land plots?

Answer: it depends on whether there is a fence BEFORE the first plot. If the file starts with delimiter, the Flat File adapter will decide that delimiter belongs at the start of each segment. If the file does NOT start with the delimiter, the Flat File adapter will reason that delimiter belongs at the end of each segment.

This is reasonable assumption, although I did not see it documented anywhere. In our example, Flat File adapter will correctly split he file before “<?xml “ prolog, because the file begins (hopefully) with this string. But please keep this rule in mind when configuring your file splitting. For example, setting splitter to “\n<?xml” (line break followed by <?xml) will NOT work, because it is almost certain that your file does not begin with line break.

Happy splitting!

December 10, 2008

WESB listening on multiple IDoc basic types from SAP

Filed under: Uncategorized — Tags: , , , — ivansmirnov @ 10:12 PM

IBM redbook named “Connect WebSphereService-Oriented Middleware to SAP” covers steps necessary for receiving IDocs from SAP using WebSphere adapter. But what if your ESB solution requires receiving and processing several IDocs basic types, such as Orders02 and Invoice01? Do you simply create another adapter module? That’s correct, but you will also need to make the following changes.

1) Each mediation modules should listen on a single IDoc basic type. Configure each module to use separate RFC Program ID. If you neglect this, SAP will have no way of determining which module to send each IDoc to and IDocs will be routed to random modules. This is certainly not the behavior you desired

2) Configure destinations in SAP for these RFC Program IDs. Please note that additional configuration is required on SAP side. Use the redbook as your guide

3) Each of the mediation modules you created in step 1 will use SAP adapter in inbound mode. Adapter should be deployed with the module.

Practitioner’s note: I had trouble getting this configuration to work correctly when SAP adapter is also installed at node level (“deployed on the server”) in WESB 6.1.2. SystemOut log entries showed that each IDoc was processed by correct adapter instance (deployed with module), but adapter behaved as if it were server-wide instance. It was unable to find method binding to process inbound IDocs in many cases. It is probably a bug, but you don’t have to wait for a fix. Simple workaround is not to mix up server- and module-packaged SAP adapter instances. In other words, when you need to listen on multiple IDoc basic types from SAP, DO NOT deploy adapter on the server level.

November 25, 2008

WID tips: Use Unicode in SAP Connection

Filed under: Uncategorized — Tags: , , , — ivansmirnov @ 3:41 AM

Here’s another error scenario in integration development using WID.
Problem: You set up your WebSphere ESB, Process Server or WID Test Environment to communicate with SAP using WebSphere adapter for SAP software. You prepare connection on SAP side, enter all connectivity parameters, but when you actually attempt to send or receive data, connection fails. You receive an interesting error message referring to a server function, but function name appears to be garbage:
JCO.Server could not find server function '剆䍟偉乇'
Solution: You forgot to configure SAP connection to use Unicode. This is how your connection is configured (WRONG):

WRONG

WRONG

Just change connection type to Unicode (RIGHT):

RIGHT

RIGHT

JCO library underpinning the adapter requires use of Unicode connection.

If you want to learn more about using SAP adapter, this developerWorks article is very hepful.

Older Posts »

Blog at WordPress.com.