Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.
Section
Column

The Filesystem Connector saves  submissions to local or remote file systems (Windows, Linux). You can:

  • Save each submission to it’s own folder
  • Save all submissions to the same folder
  • Choose to keep file names or generate a file name
  • Generate metadata for import into your Enterprise Content Management system.

Submission form/flow XML document(s), attachments that are added by the user and the PDF snapshot of your form/flow can be saved in the configured submissions directory.

Note
Signatures are not saved as they are a different content type than attachments.

Submission from  are posted using the DOC action URL in the POST data to your web application wizard. This creates files for any XML document and/or snapshot in the submission in the root folder configured for the connector.

Saving submissions to a shared directory might be an alternative if your forms/flows contain sensitive/secure information that you would rather not send via email or if you want to import the submissions into your Enterprise Content Management system.  

The Filesystem Connector is only available for in-house customers at this timeConnector is a web application and can be deployed under any Servlet container. The Servlet Container must be compatible with the Servlet 2.5 specification. For instance, Tomcat (6 or higher) or Jetty (6 or higher). If you have installed the tomcat  In-house bundle you already have what you need.

Column
width240px

On This Page:

Table of Contents
maxLevel2

...

  1. Create a file named filesystem.xml. Move it to <frevvo-home>\frevvo\tomcat\conf\Catalina\localhost directory when it is completed. Refer to the table below for the configurable parameters that can be included in the filesystem.xml content:
Configuration ParameterDescription
 connector.file.root.dirThis is the location in your file system where the submission docs will be saved. If not explicitly configured, it defaults to the user home directory. Change the value to reflect the location of your file system.
connector.file.name.keepThis parameter determines whether the original files names will be retained. If this is set to true, then you either have to make sure that all your files have unique names or else save the documents of each submission under a separate uniquely named folder. If this parameter is not included, or is set to false, submission files will be named with a generated identifier as the prefix suffixed by '_' and a sequence number to make the file name unique. The original filename extension is retained. This is the default behavior. Ex: e454fa08-9a6e-4c54-9743-18f4ba0ad0b4_1.xml instead of form.xml.
connector.file.dir.submission   This parameter allows you to create a unique new sub-folder for documents of every submission if true.
connector.file.ignore.attachmentsThis parameter determines whether attachments will be saved or not. If the value is false, attachments will be saved. Change the value to true and attachments will not be saved.
The submission XML does not store the names of uploaded attachments, instead it points to unique ID that is assigned to each attachment when that submission in created in . This is the as-designed.
connector.file.metadata.prefixThe default is "md". Change the value to the desired prefix. Field names preceded by this prefix in the Doc Url will be included in the generated metadata file. You will have to change it if the control names in your forms/flows are prefixed with "md" as a company standard.
connector.file.descriptor.suffixWhen generating metadata, the descriptor filename is the identifier, followed by a configurable suffix. The default suffix is '.xml'. Use this parameter to change the suffix.The suffix can make identifying the metadata file easier, particularly if you save the files from all submissions into the same folder.

...

    • Saved on the local drive in a directory called Submissions.
    • Individual file names will be retained.
    • Attachments in the submisison will be saved.
    • Documents of each submission will be saved under a separate folder
    • Add any form fields preceded by the prefix mmk. in the Doc Action Url to the generated metadata file.
    • Add the suffix "_desc.txt" to the metadata file for each submission.

      Code Block
      <Context unpackWAR="false" path="/filesystem" swallowOutput="true" unloadDelay="40000">
      <Parameter name="connector.file.root.dir" value="C:\Submissions" override="false"/>
      <Parameter name="connector.file.name.keep" value="true" override="false"/>
      <Parameter name="connector.file.ignore.attachments" value="false" override="false"/>
      <Parameter name="connector.file.dir.submission" value="true" override="false"/>
      <Parameter name="connector.file.metadata.prefix" value="mmk." override="false"/>
      <Parameter name="connector.file.descriptor.suffix" value="_desc.txt" override="false"/>
      </Context>


  1. Start .
  2. Make sure the directory where you plan to save the submissions is created and and has the appropriate access for the OS you are using. For example:

    1. If you are using Windows, you can map a drive to a server directory, or you could use the UNC path i.e. //host-name

    2. If you are using a Unix operating system you could mount a remote filesystem as a directory and use it as your destination directory

      Warning

      To ensure interoperability across file systems, it is recommended that you follow a good naming standard such as POSIX when creating files and folders. For example, folder names can't contain slashes so a folder named '1/2/15' would not be valid.

  3. Browse http://localhost:8082/filesystem/health (replace localhost:8082 with your frevvo server host:port) to check the status of the connector. If the connector is up and running, you will see { "status" : "UP" }.

  4. Modify your form/flow to use the File Connector via the Doc Action wizard:

    1. Edit your form/flow in the appropriate designer.

    2. Click on the what happens to my data? icon.

    3. Click to open the POST data to your web application wizard
    4. Add  http://localhost:8082/filesystem/submission (replace localhost:8082 with your frevvo server host:port) in the URL property.

    5. Select PDF in the Send Snapshot dropdown. 

    6. The Send Data checkbox is checked by default. Uncheck it if you do not want to save the .xml file
    7. Save your form/flow.


  5. Test and submit the form/flow.
  6. The submission documents will be found in the directory specified by the connector.file.root.dir parameter or in uniquely named folders under that depending on your configuration.

Tip

If you are using  v6.1.1+, it is possible to name the PDF Snapshot dynamically based on controls in your form.

How to Customize the Submission Folder Name

...

  1. Provide the submission metadata as name-value query parameters to the Doc Action URL.
  2. Create a descriptor file named file-descriptor.ftl in your <frevvo-home>\tomcat\lib directory. The file MUST be named file-descriptor.ftl

Submission Metadata as name-value query parameters to the Doc Action URL.

...

  1. Create a file descriptor template file and name it file-descriptor.ftl.

  2. The file-descriptor.ftl should be located in the classpath  - if you are using the tomcat bundle, it should be located in the <frevvo-home>\tomcat\lib directory.

  3. The content of the file-descriptor-.ftl file uses freemarker template language v2.3.23. syntax. The input to the template is identified by the variable 'params'. This contains a map of parameter name and parameter value(s). The value is a sequence/array since a parameter can be multi-valued. If there is metadata that remains constant it should be added to the file-descriptor.ftl template.

    Here is one example that can be used with Docushare Enterpise Content System:

    Code Block
    <#compress>
    <#escape x as x?xml>
    <?xml version="1.0" encoding="UTF-8"?>
    <Records>tomcat bundle
      <Record>
        <Field id="LF__User" length="-1" type="string">
          <Value>administrator</Value>
        </Field>
      <#list params?keys as key>
      <#assign values = (params[key]?size > 1)>
      <#assign doc = key?switch('submission.file.name',true,false)>
        <Field id="${doc?then('LF__Document',key)}" length="-1" type="${doc?then('document','string')}">
          <#if values><Values></#if>
          <#list params[key] as value><Value>${value}</Value></#list>
          <#if values></Values></#if>
        </Field>
      </#list>
      </Record>
    </Records>
    </#escape>
    </#compress>

    In the above sample:

    1. LF-User is an example of metadata that is constant for all submissions
    2. Full paths to all the submission files will be included in the metadata file if you put the submission.file.name parameter in the template.
    3. Value refers to a single parameter while Values designates a multi-valued parameter

  4. The descriptor filename in the submission directory is the identifier, followed by a configurable suffix. The suffix plays an important part in isolating the file. The default suffix is '.xml'. The suffix can be changed using the connector.file.descriptor.suffix context parameter. Here is what the file looks like in the submission directory when the file suffix is configured to be _desc.txt:



  5. The values from the specified query parameters will be included in the generated metadata file. For Example; if you have fields called Name and state in your form/flow that you want to include in your metadata file and have configured the connector.file.descriptor.suffix context parameter to have a value of mmk, your Doc Action Url should look like this:

    Code Block
    http://localhost:8082/filesystem/submission?submission.dir={Name}&mmk.name={Name}&mmk.state={State}

    The metadata file would look like this:

...