The downloaded files first land in the working folder on the computer (usually C:\orders). The machines normally do not read from it: they need a network folder or a mapped drive. Copying there is what synchronisation does.
When it starts
- after every order check — that is, every scheduled cycle;
- after the program has finished converting the files;
- manually — with the «Check now» button on the «Home» tab, which runs the whole cycle together with the copying.
There is no separate «synchronise only» button.
What exactly is copied
The program goes through the rules from the synchronize_folders.txt file. Every rule is a pair of «from where» and «to where». How it is built is described in the article Route rules: the line format and the two modes.
Inside a rule the program walks the source folder in full, including the nested folders, and for each file decides whether to copy it or not:
- A file without the order number in its path is skipped. The number is looked for in the folder structure; if it is not there, the file is considered an outsider and synchronisation does not touch it.
- An SVG that is still being converted is skipped. Otherwise a blank would go to the machine instead of the finished file. When the conversion ends, the EMF will already be on the disk — and that is what the next cycle will copy.
- A file that is already in the destination and of the same size is not copied again. That is why an ordinary cycle passes quickly even on a large folder: only the new and the changed files are moved again.
Cleaning up outdated SVG files in the destination
If name.svg and name.emf lie side by side in the destination folder, the SVG is deleted: it is outdated, the EMF has replaced it. This works only for rules of the folder type.
If the destination folder is unavailable
The program writes an error to the log and moves on to the next rule. The downloading of orders and the conversion do not stop because of it — the files stay in the working folder and will go to the machine as soon as the network folder appears again.
Orders that are not in the program database
If the working folder contains files of orders that this program did not download (left over from a previous installation, for example), a line like «orders skipped (not in database)» will appear in the log, with the order numbers and a sample path. Such files are neither copied nor deleted by themselves — how to free up space taken by them is written in the article How many orders to keep and how to clean the disk.
The other side of it
The program remembers which files it copied and where. So when an order is deleted, it removes not only the working folder but also the copied files in the destinations — see Delete an order and download it again.
How to check that everything got there
The «Folder comparison» window is there for that: it shows for every order how many files are in the source and how many in the destination.