Difference between revisions of "Filemanager-call"
(Created page with "==Definition== This plug-in allows you to perform a sequence of file operations on the local filesystem. The operations allowed are: #Deletion of one or more file whose name corr...") |
(→{{VULCON}} / {{GVCONSOLE}} Configuration) |
||
Line 13: | Line 13: | ||
=={{VULCON}} / {{GVCONSOLE}} Configuration== | =={{VULCON}} / {{GVCONSOLE}} Configuration== | ||
− | '' | + | ''filemanager-call'' is the operation that must be configured into {{L_VULCON}} or {{L_GVCONSOLE}} [[System section]], to executefile operation on local filesystem. |
− | In order to add an operation '' | + | In order to add an operation ''filemanager-call'' you must define the following fields: |
* ''class'': it.greenvulcano.gvesb.virtual.excel.reader.GVExcelReaderCallOperation (java class that manage ''ExcelReaderCall'' invocation). | * ''class'': it.greenvulcano.gvesb.virtual.excel.reader.GVExcelReaderCallOperation (java class that manage ''ExcelReaderCall'' invocation). | ||
− | * ''name'': this field identify the operation name | + | * ''name'': this field identify the operation name used in the 'Flow' section to associate workflow nodes to VCL operations. |
− | |||
− | |||
− | |||
− | |||
The following example shows the configuration generated from {{L_VULCON}} or {{L_GVCONSOLE}} when you configure an ''excelreader-call'' operation: | The following example shows the configuration generated from {{L_VULCON}} or {{L_GVCONSOLE}} when you configure an ''excelreader-call'' operation: | ||
Line 77: | Line 73: | ||
At this point you have configured a service with an ''excelreader-call'' operation. | At this point you have configured a service with an ''excelreader-call'' operation. | ||
− | |||
==Example== | ==Example== |
Revision as of 11:52, 20 January 2012
Definition
This plug-in allows you to perform a sequence of file operations on the local filesystem. The operations allowed are:
- Deletion of one or more file whose name corresponds to a regular expression
- Rename a file
- Moving of one or more files, whose name corresponds to a regular expression,from a directory source to a destination directory
- Copy of one or more files, whose name corresponds to a regular expression,from source directory to a destination directory
- ZIP compress of one or more files, whose name corresponds to a regular expression,from a source directory to a ZIP file in a destination directory
- Decompression of ZIP file from a directory source to a target directory
- Check existence of one or more files whose name corresponds to a given regular expression
GreenVulcano® ESB provides two different tools, GV Console® and VulCon®, to configure all supported plug-ins in GV services.
VulCon / GV Console Configuration
filemanager-call is the operation that must be configured into VulCon® or GV Console® System section, to executefile operation on local filesystem. In order to add an operation filemanager-call you must define the following fields:
- class: it.greenvulcano.gvesb.virtual.excel.reader.GVExcelReaderCallOperation (java class that manage ExcelReaderCall invocation).
- name: this field identify the operation name used in the 'Flow' section to associate workflow nodes to VCL operations.
The following example shows the configuration generated from VulCon® or GV Console® when you configure an excelreader-call operation:
<?xml version="1.0" encoding="UTF-8"?>
<GVSystems name="SYSTEMS" type="module">
<Systems>
<System id-system="system-name" system-activation="on">
<Channel id-channel="CHANNEL_NAME">
<excelreader-call class="it.greenvulcano.gvesb.virtual.excel.reader.GVExcelReaderCallOperation"
name="ReadExcelInput" type="call" onlyData="true"/>
</Channel>
</System>
</Systems>
</GVSystems>
To use an excelreader-call in a GreenVulcano® ESB service, you need to define a node of type GVOperationNode in Service section and define in the field operation-name the name defined in excelreader-call operation.
The following example shows the configuration generated from VulCon® or GV Console® when you configure an excelreader-call operation in GreenVulcano® ESB service:
<?xml version="1.0" encoding="UTF-8"?>
<GVServices name="SERVICES" type="module">
<Groups>
<Group group-activation="on" id-group="DEFAULT_GRP"/>
</Groups>
<Services>
<Service group-name="DEFAULT_GRP" id-service="SERVICE-NAME"
service-activation="on">
<Client id-system="SYSTEM-NAME" statistics="off" system-activation="on">
<Operation name="RequestReply" operation-activation="on"
out-check-type="none" type="operation">
<Participant id-channel="CHANNEL-NAME" id-system="SYSTEM-NAME"/>
<Flow first-node="excel_reader" point-x="20" point-y="112">
<GVOperationNode class="it.greenvulcano.gvesb.core.flow.GVOperationNode"
id="excel_reader" id-system="DAMA"
input="input" next-node-id="end"
op-type="call"
operation-name="ReadExcelInput"
output="excel_xml" point-x="158"
point-y="112" type="flow-node"/>
<GVEndNode class="it.greenvulcano.gvesb.core.flow.GVEndNode"
end-business-process="yes" id="end" op-type="end"
output="excel_xml" point-x="358" point-y="112"
type="flow-node"/>
</Flow>
</Operation>
</Client>
</Service>
</Services>
</GVServices>
At this point you have configured a service with an excelreader-call operation.
Example
This example shows an XML document generated by a simple Excel sheet (without cols and rows grouping). Given an Excel sheet with the following structure:
ID1 | ID2 | ID3 | ID4 | ID5 | ID6 | ID7 |
---|---|---|---|---|---|---|
23 | 23232 | 23 | 23333 | 1 | 2 | 3 |
24 | 24444 | 23 | 23332 | 1 | 2 | 3 |
excelreader-call generates the following XML:
<?xml version="1.0" encoding="UTF-8"?>
<workbook>
<sheet number="0">
<name><![CDATA[Foglio1]]></name>
<row number="0">
<col number="0">
<data><![CDATA[ID1]]></data>
</col>
<col number="1">
<data><![CDATA[ID2]]></data>
</col>
<col number="2">
<data><![CDATA[ID3]]></data>
</col>
<col number="3">
<data><![CDATA[ID4]]></data>
</col>
<col number="4">
<data><![CDATA[ID5]]></data>
</col>
<col number="5">
<data><![CDATA[ID6]]></data>
</col>
<col number="6">
<data><![CDATA[ID7]]></data>
</col>
</row>
<row number="1">
<col number="0">
<data><![CDATA[23]]></data>
</col>
<col number="1">
<data><![CDATA[23232]]></data>
</col>
<col number="2">
<data><![CDATA[23]]></data>
</col>
<col number="3">
<data><![CDATA[711]]></data>
</col>
<col number="4">
<data><![CDATA[1]]></data>
</col>
<col number="5">
<data><![CDATA[1]]></data>
</col>
<col number="6">
<data><![CDATA[1]]></data>
</col>
</row>
<row number="2">
<col number="0">
<data><![CDATA[23]]></data>
</col>
<col number="1">
<data><![CDATA[711]]></data>
</col>
<col number="2">
<data><![CDATA[23]]></data>
</col>
<col number="3">
<data><![CDATA[23232]]></data>
</col>
<col number="4">
<data><![CDATA[1]]></data>
</col>
<col number="5">
<data><![CDATA[1]]></data>
</col>
<col number="6">
<data><![CDATA[1]]></data>
</col>
</row>
</sheet>
</workbook>
With a ChangeGvBufferNode is possible parsing XML and retrieve any tag and value.
--A.sicignano 16:30, 19 January 2012 (CET)