microsoft / Dynamics-365-FastTrack-Implementation-Assets

Dynamics 365 FastTrack Implementation guides
MIT License
312 stars 196 forks source link

Can read manifest data in CDMUtil_ConsoleApp, but not CDMUtil_AzureFunction #134

Open princeton-lau opened 2 years ago

princeton-lau commented 2 years ago

Folks,

Thanks so much for building this utility!

I'm able to use the console app to connect to our storage account and read manifests, however, I'm not able to do the same with the AzureFunction.

We are not using the EventGrid_CDMToSynapseView function, as we are connecting to a private endpoint, so as suggested by Microsoft, we are using a Service Bus Trigger instead (https://docs.microsoft.com/en-us/azure/event-grid/consume-private-endpoints#deliver-events-to-service-bus-using-managed-identity).

I've created a custom function, ServiceBusQueueTriggerPL, in my fork (https://github.com/princeton-lau/Dynamics-365-FastTrack-Implementation-Assets) that essentially does the same thing as the EventGrid one... it deploys fine and runs up until it attempts to read the manifest, and that is when it throws these errors:

image

I ran the console app with the same tenantid, accesskey, manifestURL and DB connection string and it reads the manifest just fine. I dumped out the parameters to the ManifestReader constructor and the values for both apps were the same: image

I've added log statements to troubleshoot the exact line of code, 136, that fails in the ManifestHandler.cs class: image

Is there a procedure I need to follow to get the AzureFunction to work?

Thanks!

Princeton

princeton-lau commented 2 years ago

Folks,

Turns out it was a configuration issue, we added a private endpoint and the Azure function started working.

Thanks!

Princeton