【问题标题】:WSO2 ESB XSLT Mediator creates temp files (never cleaned)WSO2 ESB XSLT Mediator 创建临时文件(从不清理)
【发布时间】:2013-09-10 13:46:19
【问题描述】:

我在 Windows 上使用 WSO2 ESB 4.5.1。 我的问题是临时文件夹WSO2_HOME/tmp 正在长大并且从未清理过。

我发现问题来自 xslt 中介,每次它转换一个大的 xml 文件 (~15kb) 时都会创建一个新的临时文件。

有人知道为什么这些 tmp 文件没有被清理吗?

代理:

<?xml version="1.0" encoding="UTF-8"?>
<proxy xmlns="http://ws.apache.org/ns/synapse" name="input" transports="vfs" startOnLoad="true" trace="disable">
    <parameter name="transport.PollInterval">5</parameter>
    <parameter name="transport.vfs.FileURI">vfs:file://C:/WSO2/Test/From</parameter>
    <parameter name="transport.vfs.FileNamePattern">.*[.].*</parameter>
    <parameter name="transport.vfs.ContentType">application/xml</parameter>
    <target faultSequence="errorSequence">
        <inSequence>
            <log level="full"/>
            <property name="ClientApiNonBlocking" scope="axis2" action="remove"/>
            <property name="OUT_ONLY" value="true"/>   
            <xslt key="avintis_xml_indent"/>
            <property name="transport.vfs.ReplyFileName" expression="fn:concat('out_', $trp:FILE_NAME, '.xml')" scope="transport"/>
            <send>
                <endpoint>
                    <address uri="vfs:file://C:/WSO2/Test/To"/>
                </endpoint>
            </send>
        </inSequence>
    </target>
</proxy>

XSLT:

<xsl:stylesheet xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
  xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/"
  xmlns:xs="http://www.w3.org/2001/XMLSchema" xmlns:avintis="http://www.avintis.com/esb"
  xmlns:urn="urn:hl7-org:v2xml" version="2.0"
  xmlns:payload="http://ws.apache.org/commons/ns/payload">
  <xsl:output method="xml" encoding="UTF-8" indent="yes"/>

  <xsl:template match="*|text()|@*">
    <xsl:copy>
      <xsl:apply-templates select="*|text()|@*"/>
    </xsl:copy>
  </xsl:template>

</xsl:stylesheet>

输入文件:

any xml file bigger than ~15kb

【问题讨论】:

    标签: xslt wso2 esb wso2esb synapse


    【解决方案1】:

    HouseKeeping 任务似乎没有清理临时文件。要使用管家任务清理它们,您可以在 Carbon.xml 中配置它,如下所示。

    ${carbon.home}/tmp/worktrue自动启动> 10间隔> 30家政>

    【讨论】:

      猜你喜欢
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 2013-11-14
      相关资源
      最近更新 更多