Blog post about Copying Azure files to SharePoint, comparing Logic App and Power Automate Flow for this, and Trust No One
(2021-May-31) Recently, I created a prototype solution for one of the projects, that would copy data files from Azure to SharePoint location. The task is trivial, doesn't require a lot of effort to build such a workflow with the help of the Azure Logic App. However, SharePoint itself is like another ecosystem and it may throw a curveball to me and slow down my solution development timeline dramatically. This post is a reminder to myself on how I had spent 5% of my time to develop this solution and then the other 95% to understand why it wasn't working initially to later resolve it.
- Retrieve folder name and Azure file location from an HTTP request and save them in variables
- Retrieve a content of the Azure located file
- Create a new folder in SharePoint if it doesn't exist
- The final step is to save the extracted Azure file content into my SharePoint folder
Recent SharePoint problems and ways to resolve them:
Here is how a Logic App SharePoint (Create file) task looks like:
A similar visual layout is portrayed for the same task in Power Automate Flow:
However codewise, there are different.
Share Point (Create file) task code in Azure Logic App
Share Point (Create file) task code in Power Automate Flow
I understand that hosting platforms for Azure Logic Apps and Power Automate Flows are different, but the core code structure could still be similar. This also reminded me of the line from the "Solo" Star Wars movie, where the Backett character shared his advice, "Assume everyone will betray you. And you will never be disappointed".
I didn't want to spend more time trying to understand why the codebase was different, nor did I seek a friendly relationship with Azure Logic Apps or Power Automate Flows. I just needed to get this job done. I'm still positive, but less emotional, and perhaps this will explain the title of the blog post.