Forum Discussion
I agree with Chayce's approach. One word of caution from recent experience is that the system might not recognize the new folder being created for 10-15 minutes. I was using Box instead of Google Drive, but I imagine the refresh rates are similar across the systems. I spent hours trying to figure out why my Pipeline kept saying the folder I just created didn't exist until I finally realized it was a timing issue.
I'd suggest keeping your folder creation and document upload Pipelines separate and running your folder creation one well in advance to ensure it sees the new folders where the documents are to be uploaded. This can be frustrating from a user perspective though, so I'd love to hear if anyone has found a way around the delay.
------------------------------
Oana Whalen
------------------------------
In reference to Oana's point - for sure they will need to be separate pipelines. One remedy to the above is to have a Pipeline that is triggered on new files being updated and then a batch job Pipeline that does a sweep nightly for anything that might have failed. This would cover any latency where Google doesn't recognize the file as well as any other errors that might occur naturally as errors do. This would include just running through all the files where the Folder ID is populated but the file hasn't been processed. As part of this - I would recommend when you upload a file you tag that actual file with the Google File ID so you can build a URL to the Google Drive location as well as know it was processed.
------------------------------
Chayce Duncan
------------------------------