我在WSO2中登录时遇到了一些问题。 我想在wso2中创建日志并尝试但是获得如下的输出..
TID: [-1234] [] [2017-08-01 18:40:53,094] INFO
{org.apache.synapse.mediators.builtin.LogMediator} -To:, WSAction:urn:mediate, SOAPAction: urn:mediate,
MessageID: ID:D-113090917-60191-1500010242277-4:28:1:1:1,Direction: request,
Date and Time=2017-08-01 18:40:53.009 IST, Event Name=demo Event, APPLICATION_IDENTIFIER = 0.0.0-RC1,
APPLICATION_ADDRESS = 10.113.175.116, GEO_LOCATION = India, CODE_LOCATION = Demo_process_seq,
USER_IDENTITY = xyz, DESTINATION = abc, MESSAGE_IDENTIFIER = FMP-3335197,
MESSAGE_TYPE = MT564, DESCRIPTION = messages received... {org.apache.synapse.mediators.builtin.LogMediator}
我不想打印像-To:到MessageID ..
的字段之类的初始字段因为对我来说没必要
另外,我只想打印值而非键值对,就像我正在
日期和时间= 2017-08-01 18:40:53.009 IST但我只想要该字段的值。
如果有人知道,请帮助我获得正确的输出。 提前致谢
我使用的代码如下:
<call-template target="gov:/cs_as/common/utils/template/cs_as_standard_logging_st.xml">
<with-param xmlns:ns="http://org.apache.synapse/xsd"
name="WST_Date"
value="{get-property('WST_Date_Time')}"/>
<with-param xmlns:ns="http://org.apache.synapse/xsd"
name="WST_Event_Name"
value="{get-property('WST_Event_Name')}"/>
<with-param xmlns:ns="http://org.apache.synapse/xsd"
name="WST_APPLICATION_IDENTIFIER"
value="{get-property('WST_APPLICATION_IDENTIFIER')}"/>
<with-param xmlns:ns="http://org.apache.synapse/xsd"
name="WST_APPLICATION_ADDRESS "
value="{get-property('WST_APPLICATION_ADDRESS')}"/>
<with-param xmlns:ns="http://org.apache.synapse/xsd"
name="WST_GEO_LOCATION"
value="{get-property('WST_GEO_LOCATION')}"/>
<with-param xmlns:ns="http://org.apache.synapse/xsd"
name="WST_CODE_LOCATION"
value="{get-property('WST_CODE_LOCATION')}"/>
<with-param xmlns:ns="http://org.apache.synapse/xsd"
name="WST_USER_IDENTITY"
value="{get-property('WST_USER_IDENTITY')}"/>
<with-param xmlns:ns="http://org.apache.synapse/xsd"
name="WST_DESTINATION"
value="{get-property('WST_DESTINATION')}"/>
<with-param xmlns:ns="http://org.apache.synapse/xsd"
name="WST_MESSAGE_IDENTIFIER"
value="{get-property('WST_MESSAGE_IDENTIFIER')}"/>
<with-param xmlns:ns="http://org.apache.synapse/xsd"
name="WST_MESSAGE_TYPE"
value="{get-property('WST_MESSAGE_TYPE')}"/>
<with-param xmlns:ns="http://org.apache.synapse/xsd"
name="WST_DESCRIPTION"
value="{get-property('WST_DESCRIPTION')}"/>
<with-param name="WST_CATEGORY" value="INFO"/>
<with-param name="WST_LEVEL" value="Full"/>
<with-param name="WST_DROP_YN" value="N"/>
</call-template>