Hello Asankha,

I am working with Gregg on this issue.  I have modified the axis2.xml file
as follows

...
                <parameter
name="transport.jms.ConnectionFactoryJNDIName">java:comp/resource/OEMSJMSDReference/ConnectionFactories/CF</parameter>
   ...

This should directly lookup and connect to physical source by means of
resource provider (OEMSJMSDReference).  The resource provider is defined as
follows in orion-application.xml file

    <resource-provider class="oracle.jms.OjmsContext"
name="OEMSJMSDReference">
        <property name="datasource"
value="jdbc/xa/MyChannelDemoDataSource"></property>
    </resource-provider>

and the datasource is the actual JDBC data base connection.  Ok so far?

Now, when I tried to start the Synapse, I am getting the below error

ConnectionFactory Connected to the JMS connection factory :
java:comp/resource/O
EMSJMSDReference/ConnectionFactories/CF
java.lang.ClassCastException: oracle.jms.AQjmsConnectionFactory
        at
org.apache.synapse.transport.jms.JMSConnectionFactory.connectAndListe
n(JMSConnectionFactory.java:226)
        at org.apache.synapse.transport.jms.JMSListener.start(
JMSListener.java:9
9)
        at org.apache.axis2.engine.ListenerManager.addListener(
ListenerManager.j
ava:205)
        at org.apache.synapse.ServerManager.start(ServerManager.java:103)
        at org.apache.synapse.SynapseServer.main(SynapseServer.java:49)
        at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
        at sun.reflect.NativeMethodAccessorImpl.invoke
(NativeMethodAccessorImpl.
java:39)
        at sun.reflect.DelegatingMethodAccessorImpl.invoke
(DelegatingMethodAcces
sorImpl.java:25)
        at java.lang.reflect.Method.invoke(Method.java:585)
        at org.tanukisoftware.wrapper.WrapperSimpleApp.run(
WrapperSimpleApp.java
:240)
        at java.lang.Thread.run(Thread.java:595)

Mustafa




On Feb 11, 2008 11:12 PM, Asankha C. Perera <[EMAIL PROTECTED]> wrote:

> Can you post the body of a sample messages put on the OUT_QUEUE by your
> MDB.. is it a JMS TextMessage?.. any specific headers you use etc? Also,
> do you think Synapse encounters a fault processing it? If so, the log
> should show more information.. and to re-check, you are stating that
> this works fine with ActiveMQ? One option is to put a <log
> level="full"/> mediator as the first mediator on the inSequence of the
> JMS Proxy and get a log...
>
> asankha
>
> [EMAIL PROTECTED] wrote:
> > Yes, it still only picks up a single message off the OUT_QUEUE at
> > startup.
> >
> > -Gregg
> >
> > -----Original Message-----
> > From: Asankha C. Perera [mailto:[EMAIL PROTECTED]
> > Sent: Monday, February 11, 2008 2:22 PM
> > To: [email protected]
> > Subject: Re: Switching transports - JMS to http using AQ
> >
> > Greg
> >
> > So.. I am not sure.. do you still have a problem with the attached
> > config ?
> >
> > asankha
> >
> > [EMAIL PROTECTED] wrote:
> >
> >> Ahh, I forgot that I only showed the JMS->HTTP side in my original
> >> email.  Here's the synapse.xml I'm using:
> >>
> >> <!--
> >>   ~  Licensed to the Apache Software Foundation (ASF) under one
> >>   ~  or more contributor license agreements.  See the NOTICE file
> >>   ~  distributed with this work for additional information
> >>   ~  regarding copyright ownership.  The ASF licenses this file
> >>   ~  to you under the Apache License, Version 2.0 (the
> >>   ~  "License"); you may not use this file except in compliance
> >>   ~  with the License.  You may obtain a copy of the License at
> >>   ~
> >>   ~   http://www.apache.org/licenses/LICENSE-2.0
> >>   ~
> >>   ~  Unless required by applicable law or agreed to in writing,
> >>   ~  software distributed under the License is distributed on an
> >>   ~   * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
> >>   ~  KIND, either express or implied.  See the License for the
> >>   ~  specific language governing permissions and limitations
> >>   ~  under the License.
> >>   -->
> >>
> >> <!-- Introduction to switching transports - JMS to http/s -->
> >> <definitions xmlns="http://ws.apache.org/ns/synapse";>
> >> <proxy name="StockQuoteProxy" transports="http">
> >>         <target>
> >>             <endpoint>
> >>                  <address
> >>
> >>
> > uri="jms:/java:comp/env/jms/PlayerCommandDestination?transport.jms.Conne
> >
> > ctionFactoryJNDIName=java:comp/env/jms/PlayerConnectionFactory&amp;java.
> >
> > naming.factory.initial=oracle.j2ee.naming.ApplicationClientInitialContex
> >
> > tFactory&amp;java.naming.provider.url=ormi://localhost:23791/how-to-conn
> >
> > ect-to-oemsjmsd&amp;java.naming.security.principal=MyChannelDemoUser&amp
> >
> > ;java.naming.security.credentials=MyChannelDemoPassword&amp;transport.jm
> >
> >> s.DestinationType=queue">
> >>                       <enableAddressing/>
> >>                  </address>
> >>             </endpoint>
> >>             <inSequence>
> >>                 <property action="set" name="OUT_ONLY" value="true"/>
> >>             </inSequence>
> >>             <outSequence>
> >>                 <send/>
> >>             </outSequence>
> >>         </target>
> >>         <publishWSDL
> >>
> >>
> > uri="file:repository/conf/sample/resources/proxy/sample_proxy_1.wsdl"/>
> >
> >>     </proxy>
> >>     <proxy name="JMSProxy" transports="jms">
> >>         <target>
> >>             <inSequence>
> >>                 <property action="set" name="OUT_ONLY" value="true"/>
> >>             </inSequence>
> >>             <endpoint>
> >>                 <address
> >> uri="http://localhost:9000/soap/SimpleStockQuoteService";>
> >>                      <enableAddressing/>
> >>                 </address>
> >>             </endpoint>
> >>             <outSequence>
> >>                 <property action="set" name="Action"
> >> value="urn:placeOrder"/>
> >>                 <send/>
> >>             </outSequence>
> >>         </target>
> >>         <parameter
> >>
> >>
> > name="transport.jms.Destination">java:comp/env/jms/OutQueue</parameter>
> >
> >>         <publishWSDL
> >>
> >>
> > uri="file:repository/conf/sample/resources/proxy/sample_proxy_1.wsdl"/>
> >
> >>     </proxy>
> >> </definitions>
> >>
> >> -----Original Message-----
> >> From: Asankha C. Perera [mailto:[EMAIL PROTECTED]
> >> Sent: Monday, February 11, 2008 1:57 PM
> >> To: [email protected]
> >> Subject: Re: Switching transports - JMS to http using AQ
> >>
> >> Greg
> >>
> >>
> >>> Thanks for all your help so far Ashanka.  Sorry for my confusion.
> >>>
> >>>
> >> Np! .. thats what this user list is for :-)
> >>
> >>
> >>>  Is the scenario you describe below possible using just configuration
> >>>
> >>>
> >> via
> >>
> >>
> >>> the synapse.xml file, or is this something that I'm going to need to
> >>> write custom services for?
> >>>
> >>>
> >>>
> >> This is possible via just configuring the synapse.xml.. its actually
> >> trivial, instead of just one proxy service, you just define two proxy
> >> services.. one to convert from http->jms and the other for jms->http..
> >>
> >> If you still have any issues on this, do let us know and one of us
> >>
> > will
> >
> >> help you more
> >>
> >> asankha
> >>
> >>
> >>
> >> This message is for the designated recipient only and may contain
> >>
> > privileged, proprietary, or otherwise private information.  If you have
> > received it in error, please notify the sender immediately and delete
> > the original.  Any other use of the email by you is prohibited.
> >
> >>
> >>
> >
> >
> > This message is for the designated recipient only and may contain
> privileged, proprietary, or otherwise private information.  If you have
> received it in error, please notify the sender immediately and delete the
> original.  Any other use of the email by you is prohibited.
> >
> >
>

Reply via email to