Page 1 of 1

Find Files

Posted: Thu Jun 19, 2025 11:49 am
by graham728
Hi,

I have built a Python App that can search a directory for files. It works well and has a function to copy files to a particular location.

The copy function uses the local client laptop which can have a slow VPN connection.

I'm wondering if there's a way I can get FFASTRANS to do the copy?

Something as simple as the Python app drops the name of the file in a watch folder as a stub file - for example - TESTFILE.MXF

FFASTRANS searches a chosen directory for the file and it copies it to a specified location.

Does FFASTRANS have a function to search for files in this manner?

Re: Find Files

Posted: Fri Jun 20, 2025 8:30 pm
by FranceBB
Out of curiosity: if you've already built the search function and it's running as intended, but it's just the copy of the file that is slow and you would like FFAStrans to do it, why don't you just call the FFAStrans APIs to trigger the copy?

I mean, you can create a very simple workflow in which there's only one node, the delivery node.
Then, when your search function runs on the laptop, it will search the file, it will retrieve the path and once it finds it, instead of triggering the copy, it just has to call the FFAStrans workflow by passing the path (in a json format, so each \ becomes \\ in the path) of the input file and this way it will make FFAStrans trigger the copy.

Re: Find Files

Posted: Fri Jun 27, 2025 9:24 am
by emcodem
We have the files find plugin but you'd still need to find a way how to trigger a job, one way to do it is to trigger the job periodically which you most likely do with your python script. Another one is to run in a loop where the job spawns itself over and over but there is no smart way to ensure the job stays running.