KAS Monitor: Folder Monitoring and Conversion Tool |
Scroll | |
Extensions are only available from version 2023.x. |
Current Version: 1.0.3.0
Overview
The Folder Monitoring and Conversion Tool is a Windows service that monitors a designated input directory for newly created files and converts them using the KAS application. The tool supports parallel processing, logging, and conversion of specific file formats. It also includes a special case handling the extraction and conversion of files from ZIP archives.
Settings
The settings are defined in an appsettings.json file next to the KAS monitor.
The tool is configured with the following settings:
▪kas: Path to the KAS executable file.
▪settings: Path to the configuration settings file for KAS.
▪input: Path to the directory where incoming files are monitored.
▪output: Path to the directory where successfully converted files are stored.
▪done: Path to the directory in which the original data is stored after a successful conversion.
▪failed: Path to the directory where files that encountered conversion errors are moved.
▪log file location: Path to the directory where log files are stored.
▪format: The target format for conversion (e.g., "3DVS").
▪include file filter: Expression pattern to filter files for conversion.
▪number of processes: The maximum number of parallel conversion processes.
▪kas logging enabled: Defines whether the KAS should write a separate log file.
▪xml api file path: Applies XML commands during the conversion process
Conversion Process
The tool performs the following steps:
▪Continuously monitors the input directory for new files.
▪Upon detecting a new file, it initiates the conversion process using the KAS application.
▪If conversion is successful:
▪Moves the original file to the done folder and maintains the structure.
▪Moves the converted file to the output directory.
▪In case of a conversion error:
▪Moves the original file to the failed directory.
▪In case of file is ignored due to filter:
▪Move the original file to the output directory.
Special Case (ZIP Archive)
▪If a ZIP archive is detected in the input directory:
▪Extracts the contents of the ZIP archive.
▪Creates a directory in the output directory with the ZIP archive's name (excluding ".zip").
▪If the directory already exists through a previous process, the converted data will be stored within that folder accordingly.
▪Recursively processes each file within the extracted directory:
▪Converts the file using the KAS application.
▪Places the converted file in the corresponding directory within the output directory.
▪Moves the original file to the done folder and maintains the structure.
Conclusion
The Folder Monitoring and Conversion Tool streamlines file conversion tasks by monitoring the input directory, performing conversions using KAS, and managing successful and failed conversions. With parallel processing, logging, and customizable settings, the tool enhances workflow efficiency. It also handles the special case of ZIP archive extraction and conversion while managing import settings for PLMXML assemblies.