Wednesday, December 22, 2010

Modelling in WebSphere Lombardi: parallel paths and tokens

When modelling a process in the Lombardi authoring environment, it is possible that different paths are executed in parallel.
You can implement this using a gateway, as done here:

Running this process, will result in three process threads. In Lombardi they call these threads "tokens".
Using the inspector, the different tokens are visualized with red markers:
  (there is a bug here, activity 3 has no red marker, while it should have).

And you can see the different tokens in the execution state view:

 A process will end, when all tokens have finished an End Event, or when one token reaches a Terminate Event.

There are other ways to create and finish tokens. Using Intermediate Message Events you can start a new token somewhere else in your process, while releasing or not releasing previous tokens.

In this next example, an Intermediate Message Event will create an extra thread. If the "Close Attached Activity" property is not checked, the token in activity 1 will not move to activity 2 when the message arrives, but a second token will be created. This second token will move along the wire to activity 2.
If the "Close Attached Activity" is checked, the token will move along the wire. No new tokens will be created.

This is the result when testing this process in the Inspector:
When in activity 1, the message was sent. A new token moved to activity 2, the token that was at activity one stayed there. Again, there should be another red marker for the token in activity 1.

Thursday, October 21, 2010

Install IBM Installation Manager without internet connection or connection with proxy

When you try to install the IBM Installation Manager, and you have no internet connection, or there is a proxy standing in your way, it is possible that you cannot enter any repositories, because the installer does not get launched. It seems to get stuck at trying to connect to public.dhe.ibm.com.

We encountered this when  we tried to install WebSphere Business Monitor. After installing WebSphere Application Server 7, the installer tries to merge the was7 it just installed into a new installation manager installation (if it was not yet installed). 
This IBM document describes the problem : http://www-01.ibm.com/support/docview.wss?uid=swg21420545#NoInternet , here in combination with Process Server 7. The suggested workaround (pre-installing the ibm installation manager with the -input parameter after editing the install.xml file) did not work. Somehow, he still had a reference to the online repository.

Luckily we found a workaround (by accident). When giving an invalid -input parameter (that is, to a file that does not exist), the installation manager installer gets launched without trying to connect to a repository! Now you can unflag the online repositories using the gui, add the repository.config file of the installation manager disk, and install the installation manager.

Thursday, July 22, 2010

Workflow job in jahia 6.1 fails on WebSphere

My jahia 6.1 site running on a WebSphere Application Server 6.1.0.29 was giving the following errors when workflowing a page:


[22/07/10 11:59:28:392 CEST] 0000004b SystemOut     O 2010-07-22 11:59:28,391: INFO  [BackgroundJob] - execute Background job BackgroundJob-a62d9921-ec0b-4f31-9256-ca716c3f2bb8
 started @ Thu Jul 22 11:59:28 CEST 2010
[22/07/10 11:59:28:395 CEST] 0000004b SystemOut     O 2010-07-22 11:59:28,394: ERROR [BackgroundJob] - Cannot execute job
java.lang.NullPointerException
 at org.jahia.services.usermanager.JahiaUserManagerDBProvider.lookupUserByKey(JahiaUserManagerDBProvider.java:462)
 at org.jahia.services.usermanager.JahiaUserManagerRoutingService$7.execute(JahiaUserManagerRoutingService.java:301)
 at org.jahia.services.usermanager.JahiaUserManagerRoutingService$7.execute(JahiaUserManagerRoutingService.java:300)
 at org.jahia.services.usermanager.JahiaUserManagerRoutingService.routeCallAllUntilSuccess(JahiaUserManagerRoutingService.java:433)
 at org.jahia.services.usermanager.JahiaUserManagerRoutingService.lookupUserByKey(JahiaUserManagerRoutingService.java:299)
 at org.jahia.services.usermanager.JahiaUserManagerRoutingService$$FastClassByCGLIB$$d7ce26b5.invoke()
 at net.sf.cglib.proxy.MethodProxy.invoke(MethodProxy.java:149)
 at org.springframework.aop.framework.Cglib2AopProxy$CglibMethodInvocation.invokeJoinpoint(Cglib2AopProxy.java:700)
 at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:149)
 at org.springframework.aop.interceptor.AbstractTraceInterceptor.invoke(AbstractTraceInterceptor.java:113)
 at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:171)
 at org.springframework.aop.framework.Cglib2AopProxy$DynamicAdvisedInterceptor.intercept(Cglib2AopProxy.java:635)
 at org.jahia.services.usermanager.JahiaUserManagerRoutingService$$EnhancerByCGLIB$$be1b2945.lookupUserByKey()
 at org.jahia.services.scheduler.BackgroundJob.getProcessingContextFromBackgroundJobDataMap(BackgroundJob.java:228)
 at org.jahia.services.scheduler.BackgroundJob.execute(BackgroundJob.java:147)
 at org.quartz.core.JobRunShell.run(JobRunShell.java:202)
 at org.quartz.simpl.SimpleThreadPool$WorkerThread.run(SimpleThreadPool.java:525)
[22/07/10 11:59:28:397 CEST] 0000004b SystemOut     O 2010-07-22 11:59:28,397: ERROR [JobRunShell] - Job ActivationJob.BackgroundJob-a62d9921-ec0b-4f31-9256-ca716c3f2bb8 threw an unhandled Exception: 
java.lang.NullPointerException
 at org.jahia.services.scheduler.BackgroundJob.execute(BackgroundJob.java:166)
 at org.quartz.core.JobRunShell.run(JobRunShell.java:202)
 at org.quartz.simpl.SimpleThreadPool$WorkerThread.run(SimpleThreadPool.java:525)
[22/07/10 11:59:28:397 CEST] 0000004b SystemOut     O 2010-07-22 11:59:28,397: ERROR [ErrorLogger] - Job (ActivationJob.BackgroundJob-a62d9921-ec0b-4f31-9256-ca716c3f2bb8 threw an exception.
org.quartz.SchedulerException: Job threw an unhandled exception. [See nested exception: java.lang.NullPointerException]
 at org.quartz.core.JobRunShell.run(JobRunShell.java:213)
 at org.quartz.simpl.SimpleThreadPool$WorkerThread.run(SimpleThreadPool.java:525)
Caused by: java.lang.NullPointerException
 at org.jahia.services.scheduler.BackgroundJob.execute(BackgroundJob.java:166)
 at org.quartz.core.JobRunShell.run(JobRunShell.java:202)

After some debugging I found the cause:

the quartz jobstore driverDelegateClass was set to 'MSSQLDelegate' (as MS SQLServer is the database I used when installing, so I assume th jahia installer put this value in automatically). When changing this driver to the standard delegate 'StdJDBCDelegate', the quartz job executed without problems.

The driveDelegateClass can be set in WEB-INF/etc/config/quartz.properties using the property "org.quartz.jobStore.driverDelegateClass".

The userkey (stored in the JobDataMap of quartz) was null when the job got executed, but was set correctly when defining the job. Because the mssql driver does not seem to work correctly on WAS, the JobExecutionContext did no longer hold these values in its JobDataMap when the job got executed.

Friday, July 16, 2010

Jahia 6.1 in RAD 7.5 on WAS 6.1 - connecting to CVS

When you run a jahia 6.1 project in RAD 7.5, and publish this project directly to a websphere application server 6.1 test server, it gives errors when your project is connected to CVS.

It starts with a trace like this:


[16/07/10 10:26:14:219 CEST] 0000001d SystemOut     O 2010-07-16 10:26:14,218: INFO  [GroovyEventListener] - Listener initialized with listener file name 'EventListener.groovy' and default listener file path 'events/EventListener.groovy'
[16/07/10 10:26:14:607 CEST] 0000001d SystemOut     O 2010-07-16 10:26:14,605: ERROR [NodeTypeRegistry] - Array index out of range: 1
java.lang.ArrayIndexOutOfBoundsException: Array index out of range: 1
at org.jahia.services.content.nodetypes.NodeTypeRegistry.(NodeTypeRegistry.java:66)

then, jahia goes on initializing, a few pages later you get this:

[16/07/10 10:26:23:737 CEST] 0000001d SystemOut     O 2010-07-16 10:26:23,736: ERROR [ContextLoader] - Context initialization failed

org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'VersionService' defined in ServletContext resource [/WEB-INF/etc/spring/applicationcontext-services.xml]: Invocation of init method failed; nested exception is java.lang.StringIndexOutOfBoundsException

at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.initializeBean(AbstractAutowireCapableBeanFactory.java:1337)

Then the beautiful jahia ascii art shows up, to finish with this fatal message:


[16/07/10 10:26:25:076 CEST] 0000001d SystemOut     O 2010-07-16 10:26:25,075: ERROR [JCRStoreProvider] - Repository init error

java.lang.IllegalStateException: repository instance has been shut down



The solution to these errors was to disconnect the project from CVS


and to make sure the cvs resources were deleted



Thursday, May 27, 2010

Does a USB Boat float?



There was probably too much data on it.

Wednesday, February 10, 2010

Dates in AS400 using jtopen datasource driver

If you are using Toolbox jdbc driver for your as400 db2 datasource connection, it is possible you can only give dates between 1940 and 2039. Dates later then 2039 will give 01-01-2001.

Solution:

Set the property "dateFormat" to "iso".

Source:

Tuesday, February 2, 2010

Integrating Process Server V7 with WebSphere Portal 6.1.5

Currently, it seems impossible to configure Process Integration between WebSphere Portal 6.1.5 and Process Server 7 when this portal is running on WebSphere 7 (7.0.0.7)

The remote client for Process Server 7 does not run on portal 6.1
source :

The remote client for Process Server 6.2 does not install on WebSphere 7 (I tried, it doesn't work)
The WebSphere Process Server Client 6.2.0 can be installed on WebSphere Application Server 6.1 and supported on the same set of platforms supported by WebSphere Process Server 6.2.0. Customer applications using or based on the WebSphere Process Server Client 6.0.2, 6.1 or 6.1.2 and higher will work against WebSphere Process Server 6.2.0

Remote client for Process Server 6.2 requires WAS 6.1 with webservices feature pack.
Overview of the available feature packs: