Getting CallBackUrl for container throws nullreference exception
See original GitHub issueWhen i try to get the callbackUrl according this step in the wiki by doing this
POST /runtime/webhooks/flow/api/management/workflows/{workflowName}/triggers/{triggerName}/ listCallbackUrl?api-version=2019-10-01-edge-preview&code=<MASTER_KEY>
it results in a 500 error
Docker logs is showing this
fail: Host.Triggers.Workflows[22] Error message: subscriptionId='myedgeenvironment', correlationId='dc9f60f8-4c8b-40e7-a0c3-06e94c5f7ac6', principalOid='', principalPuid='(null)', tenantId='myedgeenvironment-tenantId', operationName='POST/RUNTIME/FLOW/MANAGEMENT/DEMOLOGICAPP/MANUAL/', message='Http request failed with unhandled exception of type 'NullReferenceException' and message: 'System.NullReferenceException: Object reference not set to an instance of an object. at Microsoft.Azure.Workflows.Data.Engines.FlowUriTemplateEngine.GetRelativePathTriggerDirectApiUri(Uri endpoint, String apiVersion, String scaleUnit, String flowId, String flowName, String triggerName) at Microsoft.Azure.Workflows.Data.Definitions.CallbackUrlDefinition.GetTriggerCallbackUrlDefinition(Uri endpoint, String apiVersion, FlowAccessKey flowAccessKey, AccessKeyType keyType, Flow flow, String triggerName, String relativePath, FlowHttpMethod triggerHttpMethod, Nullable
1 expirationTime, String flowSequenceId)
at Microsoft.Azure.Workflows.Web.Common.RequestHandlers.FlowTriggerApiRequestHandler.GetCallbackUrl(FlowContext context, String flowVersion, String triggerName)
at Microsoft.Azure.Workflows.Web.Controllers.EdgeFlowTriggerController.ListCallbackUrl(String flowName, String triggerName, CancellationToken cancellationToken)
at Microsoft.Azure.Workflows.Web.FlowExtensionRouteInitializer.Invoke(HttpRequestMessage request, CancellationToken cancellationToken)
at Microsoft.Azure.Workflows.Web.Handlers.FlowExtensionHttpRequestHandler.HandleRequest(HttpRequestMessage request, CancellationToken cancellationToken)
at Microsoft.Azure.Workflows.Web.Handlers.FlowExtensionRequestCancellationHandler.HandleRequest(HttpRequestMessage request, CancellationToken cancellationToken)
at Microsoft.Azure.Workflows.Web.Handlers.FlowExtensionAuthorizationHandler.HandleRequest(HttpRequestMessage request, CancellationToken cancellationToken)
at Microsoft.Azure.Workflows.Web.Handlers.FlowExtensionErrorResponseHandler.HandleRequest(HttpRequestMessage request, CancellationToken cancellationToken)‘.’, exception='System.NullReferenceException: Object reference not set to an instance of an object.
at Microsoft.Azure.Workflows.Data.Engines.FlowUriTemplateEngine.GetRelativePathTriggerDirectApiUri(Uri endpoint, String apiVersion, String scaleUnit, String flowId, String flowName, String triggerName)
at Microsoft.Azure.Workflows.Data.Definitions.CallbackUrlDefinition.GetTriggerCallbackUrlDefinition(Uri endpoint, String apiVersion, FlowAccessKey flowAccessKey, AccessKeyType keyType, Flow flow, String triggerName, String relativePath, FlowHttpMethod triggerHttpMethod, Nullable1 expirationTime, String flowSequenceId) at Microsoft.Azure.Workflows.Web.Common.RequestHandlers.FlowTriggerApiRequestHandler.GetCallbackUrl(FlowContext context, String flowVersion, String triggerName) at Microsoft.Azure.Workflows.Web.Controllers.EdgeFlowTriggerController.ListCallbackUrl(String flowName, String triggerName, CancellationToken cancellationToken) at Microsoft.Azure.Workflows.Web.FlowExtensionRouteInitializer.Invoke(HttpRequestMessage request, CancellationToken cancellationToken) at Microsoft.Azure.Workflows.Web.Handlers.FlowExtensionHttpRequestHandler.HandleRequest(HttpRequestMessage request, CancellationToken cancellationToken) at Microsoft.Azure.Workflows.Web.Handlers.FlowExtensionRequestCancellationHandler.HandleRequest(HttpRequestMessage request, CancellationToken cancellationToken) at Microsoft.Azure.Workflows.Web.Handlers.FlowExtensionAuthorizationHandler.HandleRequest(HttpRequestMessage request, CancellationToken cancellationToken) at Microsoft.Azure.Workflows.Web.Handlers.FlowExtensionErrorResponseHandler.HandleRequest(HttpRequestMessage request, CancellationToken cancellationToken)', organizationId='(null)', activityVector='IN.04', realPuid='', altSecId='', additionalProperties='(null)'.
Issue Analytics
- State:
- Created 3 years ago
- Comments:17 (14 by maintainers)
Top GitHub Comments
Ok I’ve managed to figure it out!
When calling following URL (which requires a POST instead of GET?):
The result gave me all the info to call it:
Once that info was mapped to my container it was working, for example:
@rohithah Can you please update the wiki to reflect this along with the
ENV AZURE_FUNCTIONS_ENVIRONMENT Development
for others to avoid this issue please?Or let us help with PRs 😃 (#140)