Hi,

I have my TCP Syslog --> JMS proxy up and running (see previous emails), but 
now have encountered another problem.
Up till now I have simply tested by using netstat to send 1-n messages stored 
in a file to the TCP server.
In this case, the messages are being received and processed correctly by 
synapse (sent as JMS
messages to the JMS server). It seems that this is working correctly, because 
the connection to the
synapse TCP server is being closed by netstat after it sends the messages.

In my real world case however, we have 1-n clients writing syslog messages to a
local syslog server. This syslog server has been configured to send the 
messages on
to the (remote) synapse TCP server. In this case the messages are NOT being 
received
and processed by synapse. Only after the syslog server closes it connection to 
the synapse
TCP server, are the messages being received and processed by synapse.

Any ideas what the problem could be?
Attached again my synapse.xml config file.

Thanks,
Peter

===============================================

<definitions xmlns="http://ws.apache.org/ns/synapse";>
    <sequence name="fault">
        <makefault>
            <code xmlns:tns="http://www.w3.org/2003/05/soap-envelope"; 
value="tns:Receiver"/>
            <reason value="Mediation failed."/>
        </makefault>
        <send/>
    </sequence>
    <sequence xmlns="http://ws.apache.org/ns/synapse"; name="main" 
onError="fault">
        <in>
            <log level="full"/>
            <send/>
        </in>
        <out>
            <send/>
        </out>
    </sequence>

    <proxy name="proxyTcp2Jms" transports="tcp">
        <target>
            <inSequence>
                <!-- Define TCP listener expects plain text (syslog) messages 
-->
                <property name="messageType" value="text/plain" scope="axis2"/>
                <property name="OUT_ONLY" value="true"/>
                <property name="TRANSPORT_HEADERS" scope="axis2" 
action="remove"/>
                <log level="full"/>

                <!-- Split any multiple syslog messages for the iterator -->
                <!-- and return as XML with child messages               -->
                <class name="com.sixtelekurs.classMediators.syslogMsgBuilder">
                    <log level="full"/>
                </class>

                <log level="full"/>

                <!-- Iterate over any multiple messages -->
                <iterate id="syslogInterator" preservePayload="false" 
sequential="true" xmlns:m0="http://ws.apache.org/commons/ns/payload"; 
expression="//m0:text">
                    <target>
                        <sequence>
                            <send>
                                <endpoint>
                                    <address 
uri="jms:/cn=sed.finesb.syslog?java.naming.factory.initial=com.sun.jndi.ldap.LdapCtxFactory&amp;java.naming.provider.url=LDAP_URL&amp;transport.jms.ConnectionFactoryJNDIName=MY_TCF&amp;transport.jms.DestinationType=topic&amp;java.naming.security.principal=MY_DN&amp;java.naming.security.credentials=MY_PASSWD"/>
                                </endpoint>
                            </send>
                        </sequence>
                    </target>
                </iterate>
            </inSequence>
            <outSequence/>
            <faultSequence>
                <log level="full" category="ERROR" separator=","/>
            </faultSequence>
        </target>
        <parameter name="transport.tcp.port">6060</parameter>
        <parameter name="transport.tcp.contentType">text/plain</parameter>
    </proxy>

</definitions>

The content of this e-mail is intended only for the confidential use of the 
person addressed. 
If you are not the intended recipient, please notify the sender and delete this 
email immediately.
Thank you.

Reply via email to