简体   繁体   English

如何使用curl从命令行界面(CLI)调用Mule的文件入站端点?

[英]How to invoke Mule's file-inbound endpoint from Command Line Interface (CLI) using curl?

I am trying to move/upload multiple files from source to destination (can be anything eg FTP or File outbound etc..) by using the below flow 我试图通过使用以下流程从源到目的地(可以是任何东西,例如FTP或文件出站等)移动/上传多个文件

<flow name="flow1" doc:name="f1">
            <file:inbound-endpoint path="C:\input" responseTimeout="10000" doc:name="File"/>
    </flow>

<flow name="flow2" doc:name="f2">
  <http:inbound-endpoint address="http://localhost:8080" doc:name="HTTP" exchange-pattern="request-response"/>

  <flow-ref name="flow1" doc:name="Flow Reference"/>
        <file:outbound-endpoint path="C:\outputfile" responseTimeout="10000" doc:name="File"/>

</flow>

The reason for doing in this way is that I want to invoke the job from CLI(Command Line Interface) using CURL. 这样做的原因是我想使用CURL从CLI(命令行界面)调用作业。

But I am receiving the below error 但我收到以下错误

Error: 错误:

Exception in thread "main" org.mule.module.launcher.DeploymentInitException: SAXParseException: cvc-complex-type.2.4.b: The content of element 'flow' is not complete. 线程“main”中的异常org.mule.module.launcher.DeploymentInitException:SAXParseException:cvc-complex-type.2.4.b:元素“flow”的内容不完整。 One of '{" http://www.mulesoft.org/schema/mule/core ":abstract-message-processor, " http://www.mulesoft.org/schema/mule/core ":abstract-outbound-endpoint, " http://www.mulesoft.org/schema/mule/core ":abstract-mixed-content-message-processor, " http://www.mulesoft.org/schema/mule/core ":response}' is expected. '{“ http://www.mulesoft.org/schema/mule/core ”之一:abstract-message-processor,“ http://www.mulesoft.org/schema/mule/core ”:abstract-outbound-端点,“ http://www.mulesoft.org/schema/mule/core ”:抽象混合内容消息处理器,“ http://www.mulesoft.org/schema/mule/core ”:响应} ' 是期待。 at org.mule.module.launcher.application.DefaultMuleApplication.init(DefaultMuleApplication.java:220) at org.mule.module.launcher.application.ApplicationWrapper.init(ApplicationWrapper.java:64) at org.mule.module.launcher.DefaultMuleDeployer.deploy(DefaultMuleDeployer.java:46) at org.mule.tooling.server.application.ApplicationDeployer.run(ApplicationDeployer.java:56) at org.mule.tooling.server.application.ApplicationDeployer.main(ApplicationDeployer.java:88) Caused by: org.mule.api.config.ConfigurationException: Line 11 in XML document from URL [file:/D:/MuleStudioExperiment/FileTransferUsingHTTP/.mule/apps/test/test.xml] is invalid; org.mule.module.launcher.application.DefaultMuleApplication.init(DefaultMuleApplication.java:220)位于org.mule.module.launcher的org.mule.module.launcher.application.ApplicationWrapper.init(ApplicationWrapper.java:64) .defaultMuleDeployer.deploy(DefaultMuleDeployer.java:46)org.mule.tooling.server.application.ApplicationDeployer.run(ApplicationDeployer.java:56)org.mule.tooling.server.application.ApplicationDeployer.main(ApplicationDeployer.java) :88)引起:org.mule.api.config.ConfigurationException:来自URL [文件:/ D:/MuleStudioExperiment/FileTransferUsingHTTP/.mule/apps/test/test.xml]的XML文档中的第11行无效; nested exception is org.xml.sax.SAXParseException; 嵌套异常是org.xml.sax.SAXParseException; lineNumber: 11; lineNumber:11; columnNumber: 8; columnNumber:8; cvc-complex-type.2.4.b: The content of element 'flow' is not complete. cvc-complex-type.2.4.b:元素'flow'的内容不完整。 One of '{" http://www.mulesoft.org/schema/mule/core ":abstract-message-processor, " http://www.mulesoft.org/schema/mule/core ":abstract-outbound-endpoint, " http://www.mulesoft.org/schema/mule/core ":abstract-mixed-content-message-processor, " http://www.mulesoft.org/schema/mule/core ":response}' is expected. '{“ http://www.mulesoft.org/schema/mule/core ”之一:abstract-message-processor,“ http://www.mulesoft.org/schema/mule/core ”:abstract-outbound-端点,“ http://www.mulesoft.org/schema/mule/core ”:抽象混合内容消息处理器,“ http://www.mulesoft.org/schema/mule/core ”:响应} ' 是期待。 (org.mule.api.lifecycle.InitialisationException) (org.mule.api.config.ConfigurationException) at org.mule.config.builders.AbstractConfigurationBuilder.configure(AbstractConfigurationBuilder.java:52) at org.mule.config.builders.AbstractResourceConfigurationBuilder.configure(AbstractResourceConfigurationBuilder.java:78) at org.mule.context.DefaultMuleContextFactory.createMuleContext(DefaultMuleContextFactory.java:80) at org.mule.module.launcher.application.DefaultMuleApplication.init(DefaultMuleApplication.java:208) ... 4 more Caused by: org.mule.api.config.ConfigurationException: Line 11 in XML document from URL [file:/D:/MuleStudioExperiment/FileTransferUsingHTTP/.mule/apps/test/test.xml] is invalid; (org.mule.api.lifecycle.InitialisationException)(org.mule.api.config.ConfigurationException)位于org.mule.config.builders的org.mule.config.builders.AbstractConfigurationBuilder.configure(AbstractConfigurationBuilder.java:52)。 AbstractResourceConfigurationBuilder.configure(AbstractResourceConfigurationBuilder.java:78)org.mule.context.DefaultMuleContextFactory.createMuleContext(DefaultMuleContextFactory.java:80)atg.mule.module.launcher.application.DefaultMuleApplication.init(DefaultMuleApplication.java:208).. .4更多引起:org.mule.api.config.ConfigurationException:来自URL [文件:/ D:/MuleStudioExperiment/FileTransferUsingHTTP/.mule/apps/test/test.xml]的XML文档中的第11行无效; nested exception is org.xml.sax.SAXParseException; 嵌套异常是org.xml.sax.SAXParseException; lineNumber: 11; lineNumber:11; columnNumber: 8; columnNumber:8; cvc-complex-type.2.4.b: The content of element 'flow' is not complete. cvc-complex-type.2.4.b:元素'flow'的内容不完整。 One of '{" http://www.mulesoft.org/schema/mule/core ":abstract-message-processor, " http://www.mulesoft.org/schema/mule/core ":abstract-outbound-endpoint, " http://www.mulesoft.org/schema/mule/core ":abstract-mixed-content-message-processor, " http://www.mulesoft.org/schema/mule/core ":response}' is expected. '{“ http://www.mulesoft.org/schema/mule/core ”之一:abstract-message-processor,“ http://www.mulesoft.org/schema/mule/core ”:abstract-outbound-端点,“ http://www.mulesoft.org/schema/mule/core ”:抽象混合内容消息处理器,“ http://www.mulesoft.org/schema/mule/core ”:响应} ' 是期待。 (org.mule.api.lifecycle.InitialisationException) at org.mule.config.builders.AbstractConfigurationBuilder.configure(AbstractConfigurationBuilder.java:52) at org.mule.config.builders.AbstractResourceConfigurationBuilder.configure(AbstractResourceConfigurationBuilder.java:78) at org.mule.config.builders.AutoConfigurationBuilder.autoConfigure(AutoConfigurationBuilder.java:101) at org.mule.config.builders.AutoConfigurationBuilder.doConfigure(AutoConfigurationBuilder.java:57) at org.mule.config.builders.AbstractConfigurationBuilder.configure(AbstractConfigurationBuilder.java:46) ... 7 more Caused by: org.mule.api.lifecycle.InitialisationException: Line 11 in XML document from URL [file:/D:/MuleStudioExperiment/FileTransferUsingHTTP/.mule/apps/test/test.xml] is invalid; org.mule.config.config.builders.AbstractConfigurationBuilder.configure(AbstractConfigurationBuilder.java:52)中的org.mule.config.builders.AbstractResourceConfigurationBuilder.configure(AbstractResourceConfigurationBuilder.java:78)atg的org.mule.api.lifecycle.InitialisationException Org.mule.config.builders.AutoConfigurationBuilder.autoConfigure(AutoConfigurationBuilder.java:101)org.mule.config.builders.AutoConfigurationBuilder.doConfigure(AutoConfigurationBuilder.java:57)org.mule.config.builders.AbstractConfigurationBuilder.configure( AbstractConfigurationBuilder.java:46)... 7更多引起:org.mule.api.lifecycle.InitialisationException:来自URL的XML文档中的第11行[file:/ D:/MuleStudioExperiment/FileTransferUsingHTTP/.mule/apps/test/test .xml]无效; nested exception is org.xml.sax.SAXParseException; 嵌套异常是org.xml.sax.SAXParseException; lineNumber: 11; lineNumber:11; columnNumber: 8; columnNumber:8; cvc-complex-type.2.4.b: The content of element 'flow' is not complete. cvc-complex-type.2.4.b:元素'flow'的内容不完整。 One of '{" http://www.mulesoft.org/schema/mule/core ":abstract-message-processor, " http://www.mulesoft.org/schema/mule/core ":abstract-outbound-endpoint, " http://www.mulesoft.org/schema/mule/core ":abstract-mixed-content-message-processor, " http://www.mulesoft.org/schema/mule/core ":response}' is expected. '{“ http://www.mulesoft.org/schema/mule/core ”之一:abstract-message-processor,“ http://www.mulesoft.org/schema/mule/core ”:abstract-outbound-端点,“ http://www.mulesoft.org/schema/mule/core ”:抽象混合内容消息处理器,“ http://www.mulesoft.org/schema/mule/core ”:响应} ' 是期待。 at org.mule.registry.AbstractRegistry.initialise(AbstractRegistry.java:117) at org.mule.config.spring.SpringXmlConfigurationBuilder.createSpringRegistry(SpringXmlConfigurationBuilder.java:116) at org.mule.config.spring.SpringXmlConfigurationBuilder.doConfigure(SpringXmlConfigurationBuilder.java:73) at org.mule.config.builders.AbstractConfigurationBuilder.configure(AbstractConfigurationBuilder.java:46) ... 11 more Caused by: org.springframework.beans.factory.xml.XmlBeanDefinitionStoreException: Line 11 in XML document from URL [file:/D:/MuleStudioExperiment/FileTransferUsingHTTP/.mule/apps/test/test.xml] is invalid; org.mule.registry.AbstractRegistry.initialise(AbstractRegistry.java:117)org.mule.config.spring.SpringXmlConfigurationBuilder.createSpringRegistry(SpringXmlConfigurationBuilder.java:116)org.mule.config.spring.SpringXmlConfigurationBuilder.doConfigure(SpringXmlConfigurationBuilder) .java:73)at org.mule.config.builders.AbstractConfigurationBuilder.configure(AbstractConfigurationBuilder.java:46)... 11更多引起:org.springframework.beans.factory.xml.XmlBeanDefinitionStoreException:来自XML文档的第11行URL [file:/ D:/MuleStudioExperiment/FileTransferUsingHTTP/.mule/apps/test/test.xml]无效; nested exception is org.xml.sax.SAXParseException; 嵌套异常是org.xml.sax.SAXParseException; lineNumber: 11; lineNumber:11; columnNumber: 8; columnNumber:8; cvc-complex-type.2.4.b: The content of element 'flow' is not complete. cvc-complex-type.2.4.b:元素'flow'的内容不完整。 One of '{" http://www.mulesoft.org/schema/mule/core ":abstract-message-processor, " http://www.mulesoft.org/schema/mule/core ":abstract-outbound-endpoint, " http://www.mulesoft.org/schema/mule/core ":abstract-mixed-content-message-processor, " http://www.mulesoft.org/schema/mule/core ":response}' is expected. '{“ http://www.mulesoft.org/schema/mule/core ”之一:abstract-message-processor,“ http://www.mulesoft.org/schema/mule/core ”:abstract-outbound-端点,“ http://www.mulesoft.org/schema/mule/core ”:抽象混合内容消息处理器,“ http://www.mulesoft.org/schema/mule/core ”:响应} ' 是期待。 at org.springframework.beans.factory.xml.XmlBeanDefinitionReader.doLoadBeanDefinitions(XmlBeanDefinitionReader.java:396) at org.springframework.beans.factory.xml.XmlBeanDefinitionReader.loadBeanDefinitions(XmlBeanDefinitionReader.java:334) at org.springframework.beans.factory.xml.XmlBeanDefinitionReader.loadBeanDefinitions(XmlBeanDefinitionReader.java:302) at org.springframework.beans.factory.support.AbstractBeanDefinitionReader.loadBeanDefinitions(AbstractBeanDefinitionReader.java:174) at org.mule.config.spring.MuleApplicationContext.loadBeanDefinitions(MuleApplicationContext.java:112) at org.springframework.context.support.AbstractRefreshableApplicationContext.refreshBeanFactory(AbstractRefreshableApplicationContext.java:131) at org.springframework.context.support.AbstractApplicationContext.obtainFreshBeanFactory(AbstractApplicationContext.java:522) at org.springframework.context.support.AbstractApplicationContext.refresh(AbstractApplicationContext.java:436) at org.mule.config.spring 位于org.springframework.beans.factory的org.springframework.beans.factory.xml.XmlBeanDefinitionReader.doLoadBeanDefinitions(XmlBeanDefinitionReader.java:396)org.springframework.beans.factory.xml.XmlBeanDefinitionReader.loadBeanDefinitions(XmlBeanDefinitionReader.java:334)org.springframework.beans.factory位于org.mule.config.spring.MuleApplicationContext.loadBeanDefinitions(MuleApplicationContext.java)的org.springframework.beans.factory.support.AbstractBeanDefinitionReader.loadBeanDefinitions(AbstractBeanDefinitionReader.java:174)中的.xml.XmlBeanDefinitionReader.loadBeanDefinitions(XmlBeanDefinitionReader.java:302) :112)org.springframework.context.support.AbstractRefreshableApplicationContext.refreshBeanFactory(AbstractRefreshableApplicationContext.java:131)org.springframework.context.support.AbstractApplicationContext.obtainFreshBeanFactory(AbstractApplicationContext.java:522)org.springframework.context.support。 org.mule.config.spring中的AbstractApplicationContext.refresh(AbstractApplicationContext.java:436) .SpringRegistry.doInitialise(SpringRegistry.java:89) at org.mule.registry.AbstractRegistry.initialise(AbstractRegistry.java:109) ... 14 more Caused by: org.xml.sax.SAXParseException; .SpringRegistry.doInitialise(SpringRegistry.java:89)at org.mule.registry.AbstractRegistry.initialise(AbstractRegistry.java:109)... 14更多引起:org.xml.sax.SAXParseException; lineNumber: 11; lineNumber:11; columnNumber: 8; columnNumber:8; cvc-complex-type.2.4.b: The content of element 'flow' is not complete. cvc-complex-type.2.4.b:元素'flow'的内容不完整。 One of '{" http://www.mulesoft.org/schema/mule/core ":abstract-message-processor, " http://www.mulesoft.org/schema/mule/core ":abstract-outbound-endpoint, " http://www.mulesoft.org/schema/mule/core ":abstract-mixed-content-message-processor, " http://www.mulesoft.org/schema/mule/core ":response}' is expected. '{“ http://www.mulesoft.org/schema/mule/core ”之一:abstract-message-processor,“ http://www.mulesoft.org/schema/mule/core ”:abstract-outbound-端点,“ http://www.mulesoft.org/schema/mule/core ”:抽象混合内容消息处理器,“ http://www.mulesoft.org/schema/mule/core ”:响应} ' 是期待。 at org.apache.xerces.util.ErrorHandlerWrapper.createSAXParseException(Unknown Source) at org.apache.xerces.util.ErrorHandlerWrapper.error(Unknown Source) at org.apache.xerces.impl.XMLErrorReporter.reportError(Unknown Source) at org.apache.xerces.impl.XMLErrorReporter.reportError(Unknown Source) at org.apache.xerces.impl.XMLErrorReporter.reportError(Unknown Source) at org.apache.xerces.impl.xs.XMLSchemaValidator$XSIErrorReporter.reportError(Unknown Source) at org.apache.xerces.impl.xs.XMLSchemaValidator.reportSchemaError(Unknown Source) at org.apache.xerces.impl.xs.XMLSchemaValidator.elementLocallyValidComplexType(Unknown Source) at org.apache.xerces.impl.xs.XMLSchemaValidator.elementLocallyValidType(Unknown Source) at org.apache.xerces.impl.xs.XMLSchemaValidator.processElementContent(Unknown Source) at org.apache.xerces.impl.xs.XMLSchemaValidator.handleEndElement(Unknown Source) at org.apache.xerces.impl.xs.XMLSchemaValidator.endElement(Unknown Source) at org.apache.xerces.impl.XMLNSDo 位于org.apache.xerces.util.ErrorHandlerWrapper.error(未知来源)的org.apache.xerces.util.ErrorHandlerWrapper.createSAXParseException(未知来源)org.apache.xerces.impl.XMLErrorReporter.reportError(未知来源)org位于org.apache.xerces.impl.xs.XMLSchemaValidator的org.apache.xerces.impl.XMLErrorReporter.reportError(未知来源)的.apache.xerces.impl.XMLErrorReporter.reportError(未知来源)$ XSIErrorReporter.reportError(未知来源)位于org.apache.xerces.impl.xs.XMLSchemaValidator.elementLocallyValidType的org.apache.xerces.impl.xs.XMLSchemaValidator.reportSchemaError(未知来源)org.apache.xerces.impl.xs.XMLSchemaValidator.elementLocallyValidComplexType(未知来源)位于org.apache.xerces.impl.xs上的org.apache.xerces.impl.xs.XMLSchemaValidator.processElementContent(未知来源)org.apache.xerces.impl.xs.XMLSchemaValidator.handleEndElement(未知来源)的(未知来源) org.apache.xerces.impl.XMLNSDo上的.XMLSchemaValidator.endElement(未知来源) cumentScannerImpl.scanEndElement(Unknown Source) at org.apache.xerces.impl.XMLDocumentFragmentScannerImpl$FragmentContentDispatcher.dispatch(Unknown Source) at org.apache.xerces.impl.XMLDocumentFragmentScannerImpl.scanDocument(Unknown Source) at org.apache.xerces.parsers.XML11Configuration.parse(Unknown Source) at org.apache.xerces.parsers.XML11Configuration.parse(Unknown Source) at org.apache.xerces.parsers.XMLParser.parse(Unknown Source) at org.apache.xerces.parsers.DOMParser.parse(Unknown Source) at org.apache.xerces.jaxp.DocumentBuilderImpl.parse(Unknown Source) at org.springframework.beans.factory.xml.DefaultDocumentLoader.loadDocument(DefaultDocumentLoader.java:75) at org.springframework.beans.factory.xml.XmlBeanDefinitionReader.doLoadBeanDefinitions(XmlBeanDefinitionReader.java:388) 来自org.apache.xerces.parsers上org.apache.xerces.impl.XMLDocumentFragmentScannerImpl.scanDocument(未知来源)的org.apache.xerces.impl.XMLDocumentFragmentScannerImpl $ FragmentContentDispatcher.dispatch(未知来源)中的cumentScannerImpl.scanEndElement(未知来源)。位于org.apache.xerces.parsers.Xars上的org.apache.xerces.parsers.XML11Configuration.parse(未知来源)的XML11Configuration.parse(未知来源)org.apache.xerces.parsers.DOMParser。在org.apringframework.beans.factory上的org.apache.xerces.jaxp.DocumentBuilderImpl.parse(未知来源)org.springframework.beans.factory.xml.DefaultDocumentLoader.loadDocument(DefaultDocumentLoader.java:75)中解析(未知来源) .xml.XmlBeanDefinitionReader.doLoadBeanDefinitions(XmlBeanDefinitionReader.java:388)

Please help 请帮忙

Try this 试试这个

<flow name="flow1" doc:name="flow1" initialState="stopped">
  <file:inbound-endpoint path="C:\Input" responseTimeout="10000" doc:name="File"/>

  <file:outbound-endpoint path="C:\outputfile" responseTimeout="10000" doc:name="File"/>
</flow>

<flow name="flow2" doc:name="flow2">
  <http:inbound-endpoint address="http://localhost:8080/start" doc:name="HTTP" exchange-pattern="request-response"/>

  <expression-component>
    app.registry.filePickupFlow.start();
  </expression-component>

  <set-payload value="File successfully copied" />

</flow>

The file endpoints are resource based endpoints (such as ftp and sftp endpoints) as opposed to event based endpoints (ie jms and vm) or tcp based endpoints (ie tcp, http, udp, etc) 文件端点是基于资源的端点(例如ftp和sftp端点),而不是基于事件的端点(即jms和vm)或基于tcp的端点(即tcp,http,udp等)

For this reason the approach you are implementing won't fit your use case. 因此,您实施的方法不适合您的使用案例。 If you need to load a file on demand (ie when you hit an http endpoint) you should refactor your flow and use the mule-module-file-utils . 如果您需要按需加载文件(即当您点击http端点时),您应该重构您的流并使用mule-module-file-utils This module need to be added as a maven dependency or installed in Studio. 此模块需要作为maven依赖项添加或安装在Studio中。 You can do that by cloning the git repo and then you can install the generated update site zip file following these instructions 您可以通过克隆git repo来实现 ,然后按照这些说明安装生成的更新站点zip文件

Once you did that your flow will look like the following: 完成后,您的流程将如下所示:

<?xml version="1.0" encoding="UTF-8"?>
<mule xmlns:fileutils="http://www.mulesoft.org/schema/mule/fileutils" xmlns:tracking="http://www.mulesoft.org/schema/mule/ee/tracking" xmlns:scripting="http://www.mulesoft.org/schema/mule/scripting" xmlns:http="http://www.mulesoft.org/schema/mule/http" xmlns:file="http://www.mulesoft.org/schema/mule/file"
    xmlns:mulexml="http://www.mulesoft.org/schema/mule/xml" xmlns="http://www.mulesoft.org/schema/mule/core" xmlns:doc="http://www.mulesoft.org/schema/mule/documentation"
    xmlns:spring="http://www.springframework.org/schema/beans" version="EE-3.3.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
    xsi:schemaLocation="
http://www.mulesoft.org/schema/mule/http http://www.mulesoft.org/schema/mule/http/current/mule-http.xsd 
http://www.mulesoft.org/schema/mule/fileutils http://www.mulesoft.org/schema/mule/fileutils/3.3/mule-fileutils.xsd 
http://www.mulesoft.org/schema/mule/ee/tracking http://www.mulesoft.org/schema/mule/ee/tracking/current/mule-tracking-ee.xsd 
http://www.mulesoft.org/schema/mule/scripting http://www.mulesoft.org/schema/mule/scripting/current/mule-scripting.xsd 
http://www.springframework.org/schema/beans http://www.springframework.org/schema/beans/spring-beans-current.xsd 
http://www.mulesoft.org/schema/mule/core http://www.mulesoft.org/schema/mule/core/current/mule.xsd 
http://www.mulesoft.org/schema/mule/file http://www.mulesoft.org/schema/mule/file/current/mule-file.xsd 
http://www.mulesoft.org/schema/mule/xml http://www.mulesoft.org/schema/mule/xml/current/mule-xml.xsd ">
    <fileutils:config name="Fileutils" doc:name="Fileutils"/>
    <flow name="FileCopier" doc:name="FileCopier">
        <http:inbound-endpoint exchange-pattern="request-response" host="localhost" port="8081" path="copy-file" doc:name="HTTP"/>
        <scripting:transformer doc:name="Script">
            <scripting:script engine="Groovy">
                <scripting:text><![CDATA[def dir = new File("/" + message.getInboundProperty('http.relative.path'))
log.info(dir.getPath())
return Arrays.asList(dir.listFiles())]]></scripting:text>
            </scripting:script>
        </scripting:transformer>
        <logger level="INFO" doc:name="Logger"/>
        <set-variable variableName="fileNumber" value="#[payload.size()]" doc:name="Variable"/>
        <foreach doc:name="Foreach">
            <fileutils:copy-file config-ref="Fileutils" destinationName="#[message.payload.getName()]" destinationPath="/tmp/out/" fileName="#[message.payload.getName()]" filePath="#[message.payload.getParentFile().getPath()]" fileAge="0" doc:name="Fileutils"/>
        </foreach>
        <set-payload value="#[flowVars['fileNumber'] + ' file copied']" doc:name="Set Payload"/>
        <http:response-builder status="200" contentType="text/plain" doc:name="HTTP Response Builder"/>
        </flow>
      </mule>

If you don't want to use the fileutils module you can replace it with a scripting component that implements the file copy logic 如果您不想使用fileutils模块,可以将其替换为实现文件复制逻辑的脚本组件

Now this flow can be invoked using the following curl command 现在可以使用以下curl命令调用此流程

curl http://${hostname}:8081/copy-file/${path_to_directory_to_copy} curl http:// $ {hostname}:8081 / copy-file / $ {path_to_directory_to_copy}

The documentation about curl is available here 有关curl的文档可在此处获得

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM