user3385500
user3385500

Reputation: 171

WSO2 ESB on Carbon 4.2 - Did not find the desired phase 'Transport' while deploying handler 'POXSecurityHandler'

I'm new to WSO2 ESB and would like to try it out for some external integrations. I've installed the WSO2 Carbon 4.2 server and installed the ESB feature 4.8.1. After a restart, I'm getting some errors as below. Any tips or suggestions would be gratefully accepted.

Thanks.

[2014-03-06 10:01:08,521]  INFO {org.wso2.carbon.mediation.initializer.ServiceBusInitializer} -  Initializing Apache Synapse...
[2014-03-06 10:01:08,525] FATAL {org.wso2.carbon.mediation.initializer.ServiceBusInitializer} -  Couldn't initialize the ESB...
org.apache.synapse.SynapseException: The synapse.xml location ././
        ./repository/deployment/server/synapse-configs
    /default doesn't exist
    at org.apache.synapse.SynapseControllerFactory.handleFatal(SynapseControllerFactory.java:121)
    at org.apache.synapse.SynapseControllerFactory.validatePath(SynapseControllerFactory.java:113)
    at org.apache.synapse.SynapseControllerFactory.validate(SynapseControllerFactory.java:88)
    at org.apache.synapse.SynapseControllerFactory.createSynapseController(SynapseControllerFactory.java:44)
    at org.apache.synapse.ServerManager.init(ServerManager.java:102)
    at org.wso2.carbon.mediation.initializer.ServiceBusInitializer.initESB(ServiceBusInitializer.java:423)
    at org.wso2.carbon.mediation.initializer.ServiceBusInitializer.activate(ServiceBusInitializer.java:182)
    at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
    at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
    at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
    at java.lang.reflect.Method.invoke(Method.java:597)
...
...
...
[2014-03-06 10:01:08,531]  INFO {org.wso2.carbon.rule.kernel.internal.ds.RuleEngineConfigDS} -  Successfully registered the Rule Config service
[2014-03-06 10:01:08,553] ERROR {org.wso2.carbon.security.internal.SecurityMgtServiceComponent} -  Failed to activate SecurityMgtServiceComponent
org.apache.axis2.phaseresolver.PhaseException: Did not find the desired phase 'Transport' while deploying handler 'POXSecurityHandler'.
    at org.apache.axis2.phaseresolver.PhaseHolder.addHandler(PhaseHolder.java:75)
    at org.apache.axis2.phaseresolver.PhaseResolver.engageModuleToFlow(PhaseResolver.java:68)
    at org.apache.axis2.phaseresolver.PhaseResolver.engageModuleToOperation(PhaseResolver.java:104)
    at org.apache.axis2.phaseresolver.PhaseResolver.engageModuleToOperation(PhaseResolver.java:110)
    at org.apache.axis2.description.AxisOperation.onEngage(AxisOperation.java:152)
    at org.apache.axis2.description.AxisDescription.engageModule(AxisDescription.java:478)
    at org.apache.axis2.description.AxisService.onEngage(AxisService.java:827)
    at org.apache.axis2.description.AxisDescription.engageModule(AxisDescription.java:478)
    at org.apache.axis2.description.AxisServiceGroup.onEngage(AxisServiceGroup.java:134)

Upvotes: 5

Views: 1508

Answers (3)

Dave
Dave

Reputation: 1

For the first exception see the bug resolution comment at https://wso2.org/jira/browse/ESBJAVA-776

I also copied in the synapsis.xml file from the ESB distribution given by Isuru

Upvotes: 0

Kasun Gajasinghe
Kasun Gajasinghe

Reputation: 2776

For the second exception -

"org.apache.axis2.phaseresolver.PhaseException: Did not find the desired phase 'Transport' while deploying handler 'POXSecurityHandler'."

This is because the 'Transport' phase is missing in the 'OutFaultFlow' of the axis2.xml. This is a recent addition hence it's missing when you did the feature installation. To fix this issue,

  • Search for the OutFaultFlow in the repository/conf/axis2/axis2.xml
  • In there, just after the 'Security' phase add the new entry 'Transport' as follows

.

<phase name="Transport"/>
  • Restart the server

Upvotes: 3

Isuru Perera
Isuru Perera

Reputation: 1905

Even though, WSO2 Carbon supports any feature installation via P2, there are some configurations not coming via the feature installation.

If you compare the ESB product with the customized product you have, you will see there are many differences in the config files. Please take a look at how ESB distribution is created.

There are two errors in your case.

  1. org.apache.synapse.SynapseException: The synapse.xml location ././ ./repository/deployment/server/synapse-configs/default doesn't exist

This means that it cannot find the synapse.xml in /repository/deployment/server/synapse-configs/default. This is missing as it comes via the product distribution.

  1. org.apache.axis2.phaseresolver.PhaseException: Did not find the desired phase 'Transport' while deploying handler 'POXSecurityHandler'.

This probably means that Axis2 to cannot find the "Transport" phase required by a security component. The "Transport" phase is available in ESB 4.8.1 axis2.xml.

In summary, my personal opinion is that you should not try to install ESB features on WSO2 Carbon. If I need a product with multiple features, I would start with ESB first.

While feature installation provides you more flexibility, it will not always work smoothly. However there are many useful cases that we can install features on top of WSO2 Products.

I hope this helps.

Upvotes: 1

Related Questions