Details

  • Type: Bug Bug
  • Status: Closed Closed
  • Priority: Major Major
  • Resolution: Fixed
  • Affects Version/s: 1.2
  • Fix Version/s: 1.3-rc2
  • Component/s: Transport: JMS
  • Labels:
    None
  • Environment:

    Java 1.4.2
    Oracle 9.0.4.7

  • Configuration:
    Hide

    JMS Connector.

    <connector name="oracleJmsConnector" className="org.mule.providers.oracle.jms.OracleJmsConnector">
    <properties>
    <property name="url" value="jdbc:oracle:thin:@localhost:1521:orcal240" />
    <property name="username" value="orca_ll_data_owner" />
    <property name="password" value="orca_ll_data_owner" />
    </properties>
    </connector>

    <mule-descriptor name="timeJump"
    implementation="com.truston.orca.mule.RSBTimeJump"
    inboundEndpoint="oaq://distribution"
    inboundTransformer="TextMessageToString XmlToDomDocument"
    >
    <outbound-router matchAll="true">
    <router className="org.mule.routing.outbound.FilteringOutboundRouter">
    <endpoint address="oaq://future" transformers="DomDocumentToXml StringToTextMessage Delay"/>
    <filter className="com.truston.orca.mule.DelayFilter"/>
    </router>
    <router className="org.mule.routing.outbound.FilteringOutboundRouter">
    <endpoint address="Now" transformers="DomDocumentToXml StringToTextMessage" />
    </router>
    </outbound-router>

    <properties>
    <property name="delayEvaluatorImplentation" value="com.truston.orca.rsb.distribute.impl.RSBDelayEvaluator"/>
    </properties>

    </mule-descriptor>

    Show
    JMS Connector. <connector name="oracleJmsConnector" className="org.mule.providers.oracle.jms.OracleJmsConnector"> <properties> <property name="url" value="jdbc:oracle:thin:@localhost:1521:orcal240" /> <property name="username" value="orca_ll_data_owner" /> <property name="password" value="orca_ll_data_owner" /> </properties> </connector> <mule-descriptor name="timeJump" implementation="com.truston.orca.mule.RSBTimeJump" inboundEndpoint="oaq://distribution" inboundTransformer="TextMessageToString XmlToDomDocument" > <outbound-router matchAll="true"> <router className="org.mule.routing.outbound.FilteringOutboundRouter"> <endpoint address="oaq://future" transformers="DomDocumentToXml StringToTextMessage Delay"/> <filter className="com.truston.orca.mule.DelayFilter"/> </router> <router className="org.mule.routing.outbound.FilteringOutboundRouter"> <endpoint address="Now" transformers="DomDocumentToXml StringToTextMessage" /> </router> </outbound-router> <properties> <property name="delayEvaluatorImplentation" value="com.truston.orca.rsb.distribute.impl.RSBDelayEvaluator"/> </properties> </mule-descriptor>
  • Similar Issues:
    None

Description

To consume a new JMS message the connector creates a new JMS Session. For this session a new JDBC Connection is created. The session is closed, but not the jdbc connection. In effect each message adds a jdbc connection.

  1. OracleJmsMessageDispatcher.java
    02/Mar/06 09:54 AM
    13 kB
    ${attachment.displayAuthor}

Activity

Hide
Klaas Eikelboom added a comment -

I made a hotfix for this solution to get it working for our production situation. I attach the file to this issue.

Show
Klaas Eikelboom added a comment - I made a hotfix for this solution to get it working for our production situation. I attach the file to this issue.
Hide
Klaas Eikelboom added a comment -

The hotfix I made is not a very clean solution. I just made a copy of a lot of code. And I am pretty sure that it does not work when the multipleSessionsPerConnection property is set. My preferred solution would be:

  • Make the close session an seperate method in JmsMessageDispatcher.
  • Overide this method in OracleJmsMessageDispatcher.

Because al lot of Oracle connections are openen and closed it is better to use a connection pool. The Oracle JDBC driver has an internal connection pool that can be used as follows.

import oracle.jdbc.pool.OracleDataSource;

ods = new OracleDataSource();
ods.setDataSourceName("mule-ods");
ods.setURL(this.url);
ods.setPassword(this.password);
ods.setUser(this.user);
Connection conn = ods.getConnection();

Show
Klaas Eikelboom added a comment - The hotfix I made is not a very clean solution. I just made a copy of a lot of code. And I am pretty sure that it does not work when the multipleSessionsPerConnection property is set. My preferred solution would be:
  • Make the close session an seperate method in JmsMessageDispatcher.
  • Overide this method in OracleJmsMessageDispatcher.
Because al lot of Oracle connections are openen and closed it is better to use a connection pool. The Oracle JDBC driver has an internal connection pool that can be used as follows. import oracle.jdbc.pool.OracleDataSource; ods = new OracleDataSource(); ods.setDataSourceName("mule-ods"); ods.setURL(this.url); ods.setPassword(this.password); ods.setUser(this.user); Connection conn = ods.getConnection();
Hide
Travis Carlson added a comment -

Thanks for the suggestions, Klaas!

Show
Travis Carlson added a comment - Thanks for the suggestions, Klaas!

People

Vote (0)
Watch (0)

Dates

  • Created:
    Updated:
    Resolved: