You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@ode.apache.org by Grant McDonald <gm...@infocomp.com> on 2006/08/08 13:50:22 UTC

Commented code in StartCatchAction

Hi,

My colleagues and I have been using the BPE subproject from Apache ODE
integrated with ServiceMix for some time now.  During the development of our
BPEL flows it became obvious that the contents of fault messages is not
properly available to faultHandlers and results in the following stacktrace:

java.lang.UnsupportedOperationException: Unable to retrieve value
        at
org.apache.servicemix.bpe.external.JbiInvokeAction.getSourceFromPayload(JbiI
nvokeAction.java:276)
        at
org.apache.servicemix.bpe.external.JbiInvokeAction.execute(JbiInvokeAction.j
ava:179)
        at
org.apache.ode.bpe.action.bpel.ExternalServiceAction.execute(ExternalService
Action.java:230)
        at
org.apache.servicemix.bpe.external.JbiExternalAction.execute(JbiExternalActi
on.java:129)
        at
org.apache.ode.bpe.engine.ProcessInstance.executeActions(ProcessInstance.jav
a:359)
        at
org.apache.ode.bpe.engine.ProcessInstance.evaluate(ProcessInstance.java:325)
        at
org.apache.ode.bpe.engine.ProcessInstance.evaluate(ProcessInstance.java:414)
        at
org.apache.ode.bpe.engine.ProcessInstance.processInternalEvent(ProcessInstan
ce.java:254)
        at
org.apache.ode.bpe.engine.ProcessInstance.processEvent(ProcessInstance.java:
209)
        at
org.apache.ode.bpe.scope.service.impl.FCScopeInstanceImpl.executeProcess(FCS
copeInstanceImpl.java:392)
        at
org.apache.ode.bpe.scope.service.impl.FCScopeInstanceImpl.handleFault(FCScop
eInstanceImpl.java:531)
        at
org.apache.ode.bpe.engine.ProcessInstance.processInternalEvent(ProcessInstan
ce.java:287)
        at
org.apache.ode.bpe.engine.ProcessInstance.processEvent(ProcessInstance.java:
209)
        at
org.apache.ode.bpe.correlation.CorrelationService.createInstanceAndRoute(Cor
relationService.java:231)
        at
org.apache.ode.bpe.correlation.CorrelationService.correlateEvent(Correlation
Service.java:338)
        at
org.apache.ode.bpe.bped.unmanaged.EventDirectorSLImpl.sendEvent(EventDirecto
rSLImpl.java:116)
        at
org.apache.servicemix.bpe.BPEEndpoint.process(BPEEndpoint.java:146)

<snip>

After do some code diving I came across areas of the code I'd like to ask
about:

1) FScopeInstanceImpl - the HashMap which contains the faultHandlers keyed
by faultType is never actually populated by fault type since the
addFaultHandler method is only called from StartScopeAction which populates
the faultType as "" (and hence the ServiceMix integration layer does not
populate the faultType on the BPRuntimeException). Was this a planned
implementation that never got finished?

2) StartCatchAction - this class has commented out code that deals with
faultTypes created on the faultHandler and the creation of an Interaction to
hold the faultMessage contents instead of using the straight data object.
Was this also an area that was yet to be fully implemented? What was the
intention of the commented out code and was there some caveat with the
approach that was previously being taken?

I am aware that the majority of work is being done in trunk now as PXE and
BPE have been subsumed into ODE now. Any help would be appreciated in this
area.

Kind regards,

Grant McDonald

Re: Commented code in StartCatchAction

Posted by cory <co...@gmail.com>.
It's a bug that the catch by fault type was never fully implemented.
I think the commented out code in the StartCatchAction is a remnant
from an attempt to implement the catch by fault type.  Do you think
the exception your are seeing is related to the catch by fault type
bug?  Is your invoke in the fault handler trying to access a variable
that is not initialized or out of scope?

-cory

On 8/8/06, Grant McDonald <gm...@infocomp.com> wrote:
> Hi,
>
> My colleagues and I have been using the BPE subproject from Apache ODE
> integrated with ServiceMix for some time now.  During the development of our
> BPEL flows it became obvious that the contents of fault messages is not
> properly available to faultHandlers and results in the following stacktrace:
>
> java.lang.UnsupportedOperationException: Unable to retrieve value
>         at
> org.apache.servicemix.bpe.external.JbiInvokeAction.getSourceFromPayload(JbiI
> nvokeAction.java:276)
>         at
> org.apache.servicemix.bpe.external.JbiInvokeAction.execute(JbiInvokeAction.j
> ava:179)
>         at
> org.apache.ode.bpe.action.bpel.ExternalServiceAction.execute(ExternalService
> Action.java:230)
>         at
> org.apache.servicemix.bpe.external.JbiExternalAction.execute(JbiExternalActi
> on.java:129)
>         at
> org.apache.ode.bpe.engine.ProcessInstance.executeActions(ProcessInstance.jav
> a:359)
>         at
> org.apache.ode.bpe.engine.ProcessInstance.evaluate(ProcessInstance.java:325)
>         at
> org.apache.ode.bpe.engine.ProcessInstance.evaluate(ProcessInstance.java:414)
>         at
> org.apache.ode.bpe.engine.ProcessInstance.processInternalEvent(ProcessInstan
> ce.java:254)
>         at
> org.apache.ode.bpe.engine.ProcessInstance.processEvent(ProcessInstance.java:
> 209)
>         at
> org.apache.ode.bpe.scope.service.impl.FCScopeInstanceImpl.executeProcess(FCS
> copeInstanceImpl.java:392)
>         at
> org.apache.ode.bpe.scope.service.impl.FCScopeInstanceImpl.handleFault(FCScop
> eInstanceImpl.java:531)
>         at
> org.apache.ode.bpe.engine.ProcessInstance.processInternalEvent(ProcessInstan
> ce.java:287)
>         at
> org.apache.ode.bpe.engine.ProcessInstance.processEvent(ProcessInstance.java:
> 209)
>         at
> org.apache.ode.bpe.correlation.CorrelationService.createInstanceAndRoute(Cor
> relationService.java:231)
>         at
> org.apache.ode.bpe.correlation.CorrelationService.correlateEvent(Correlation
> Service.java:338)
>         at
> org.apache.ode.bpe.bped.unmanaged.EventDirectorSLImpl.sendEvent(EventDirecto
> rSLImpl.java:116)
>         at
> org.apache.servicemix.bpe.BPEEndpoint.process(BPEEndpoint.java:146)
>
> <snip>
>
> After do some code diving I came across areas of the code I'd like to ask
> about:
>
> 1) FScopeInstanceImpl - the HashMap which contains the faultHandlers keyed
> by faultType is never actually populated by fault type since the
> addFaultHandler method is only called from StartScopeAction which populates
> the faultType as "" (and hence the ServiceMix integration layer does not
> populate the faultType on the BPRuntimeException). Was this a planned
> implementation that never got finished?
>
> 2) StartCatchAction - this class has commented out code that deals with
> faultTypes created on the faultHandler and the creation of an Interaction to
> hold the faultMessage contents instead of using the straight data object.
> Was this also an area that was yet to be fully implemented? What was the
> intention of the commented out code and was there some caveat with the
> approach that was previously being taken?
>
> I am aware that the majority of work is being done in trunk now as PXE and
> BPE have been subsumed into ODE now. Any help would be appreciated in this
> area.
>
> Kind regards,
>
> Grant McDonald
>
>