<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Re: User Data Function: 'NotFound' Error (WorkloadException) after Publishing, but Success in Develop in Activator</title>
    <link>https://community.fabric.microsoft.com/t5/Activator/User-Data-Function-NotFound-Error-WorkloadException-after/m-p/5140947#M995</link>
    <description>&lt;P&gt;Hi&amp;nbsp;&lt;a href="javascript:void(0)" data-lia-user-mentions="" data-lia-user-uid="1570257" data-lia-user-login="Izyaan_sc" class="lia-mention lia-mention-user"&gt;Izyaan_sc&lt;/a&gt;,&lt;/P&gt;
&lt;P&gt;The function is working correctly in Develop mode, which confirms that the KQL query and Python logic are valid.&lt;/P&gt;
&lt;P&gt;The failure in Run (Published) mode is due to Microsoft Fabric runtime limitations. In the published environment, User Data Functions run in a managed backend with restricted capabilities. Specifically, outbound network calls and certain custom dependencies are not fully supported or guaranteed to work.&lt;/P&gt;
&lt;P&gt;Because the function attempts to push data to an external Mimir endpoint, the backend is unable to execute the request, resulting in a generic “WorkloadException: NotFound” error. This error indicates a runtime execution failure rather than a missing function.&lt;/P&gt;
&lt;P&gt;As per Microsoft Fabric design guidance, User Data Functions should be used for lightweight, in-platform processing. For external integrations such as pushing metrics to external systems, it is recommended to use Fabric pipelines, notebooks, or external services (e.g., Azure Functions) instead of UDFs.&lt;/P&gt;
&lt;P&gt;We recommend redesigning the solution so that Activator triggers a Fabric-native output (such as a pipeline or table), and the external call to Mimir is handled outside the UDF.&lt;/P&gt;
&lt;P&gt;&lt;A href="https://learn.microsoft.com/en-us/fabric/data-engineering/user-data-functions/user-data-functions-service-limits" target="_blank"&gt;Service details and limitations - Microsoft Fabric | Microsoft Learn&lt;/A&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Thank you.&lt;/P&gt;
&lt;P&gt;&lt;LI-WRAPPER&gt;&lt;/LI-WRAPPER&gt;&lt;/P&gt;</description>
    <pubDate>Mon, 30 Mar 2026 08:54:47 GMT</pubDate>
    <dc:creator>v-saisrao-msft</dc:creator>
    <dc:date>2026-03-30T08:54:47Z</dc:date>
    <item>
      <title>User Data Function: 'NotFound' Error (WorkloadException) after Publishing, but Success in Develop</title>
      <link>https://community.fabric.microsoft.com/t5/Activator/User-Data-Function-NotFound-Error-WorkloadException-after/m-p/5137556#M987</link>
      <description>&lt;P&gt;I am setting up a monitoring workflow in Microsoft Fabric using Fabric Activator. I have created an &lt;STRONG&gt;alert based on a KQL query&lt;/STRONG&gt; that monitors row ingestion. kql query -&amp;nbsp;&lt;/P&gt;&lt;DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;table1&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;|&lt;/SPAN&gt; &lt;SPAN&gt;where&lt;/SPAN&gt; &lt;SPAN&gt;ingestion_time&lt;/SPAN&gt;&lt;SPAN&gt;()&lt;/SPAN&gt; &lt;SPAN&gt;&amp;gt;&lt;/SPAN&gt; &lt;SPAN&gt;ago&lt;/SPAN&gt;&lt;SPAN&gt;(&lt;/SPAN&gt;&lt;SPAN&gt;10m&lt;/SPAN&gt;&lt;SPAN&gt;)&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;|&lt;/SPAN&gt; &lt;SPAN&gt;summarize&lt;/SPAN&gt; &lt;SPAN&gt;RowsIngested&lt;/SPAN&gt; &lt;SPAN&gt;=&lt;/SPAN&gt; &lt;SPAN&gt;count&lt;/SPAN&gt;&lt;SPAN&gt;&lt;SPAN&gt;()&lt;BR /&gt;I am calling a &lt;STRONG&gt;User Data Function (UDF)&lt;/STRONG&gt; as the &lt;STRONG&gt;action&lt;/STRONG&gt; to push this data to an external Mimir endpoint via Remote Write.&lt;BR /&gt;&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/DIV&gt;&lt;/DIV&gt;&lt;LI-CODE lang="python"&gt;@udf.function()
def testFunction(metricName: str, metricValue: float, labels: dict) -&amp;gt; str:
    logging.info(f"Starting Prometheus Remote Write push for: {metricName}")

    try:
        writer = RemoteWriter(
            url=MIMIR_URL,
            auth={
                "username": MIMIR_USERNAME,
                "password": MIMIR_PASSWORD
            }
        )

        if not isinstance(labels, dict):
            logging.error("Input 'labels' was not provided as a dictionary/object.")
            return "Push failed: labels must be a JSON object"

        timestamp_ms = int(datetime.datetime.now().timestamp() * 1000)

        metric_definition = labels.copy()
        metric_definition["__name__"] = metricName

        series = [
            {
                "metric": metric_definition,
                "values": [float(metricValue)],
                "timestamps": [timestamp_ms]
            }
        ]

        writer.send(series)

        logging.info(f"Successfully pushed {metricName} to Mimir.")
        return f"Metric pushed successfully at {datetime.datetime.now()}"

    except Exception as e:
        logging.error(f"Remote Write failed: {str(e)}")
        return f"Push failed: {str(e)}"&lt;/LI-CODE&gt;&lt;H4&gt;&lt;STRONG&gt;1. Develop Mode (Success)&lt;/STRONG&gt;&lt;/H4&gt;&lt;P&gt;When testing the function in &lt;STRONG&gt;Develop Mode&lt;/STRONG&gt; using the Test Panel with the following parameters:&lt;/P&gt;&lt;UL&gt;&lt;LI&gt;&lt;P&gt;metricName: "fabric_rows_ingested_test"&lt;/P&gt;&lt;/LI&gt;&lt;LI&gt;&lt;P&gt;metricValue: 111&lt;/P&gt;&lt;/LI&gt;&lt;LI&gt;&lt;P&gt;metricLabels: {"workspace": "dev", "table": "table1"}&lt;/P&gt;&lt;/LI&gt;&lt;/UL&gt;&lt;P&gt;&lt;STRONG&gt;Output:&lt;/STRONG&gt; "Metric pushed successfully at 2026-03-23 06:53:51" &lt;STRONG&gt;Logs:&lt;/STRONG&gt; Successfully pushed fabric_rows_ingested_test to Mimir.&lt;/P&gt;&lt;P&gt;above exposed metric can be accessed in grafana.&lt;/P&gt;&lt;H4&gt;&lt;STRONG&gt;2. Run/Published Mode (Failure)&lt;/STRONG&gt;&lt;/H4&gt;&lt;H4&gt;After clicking &lt;STRONG&gt;Publish&lt;/STRONG&gt; and ensuring all libraries (prometheus-remote-writer, requests) are listed as "Published" in Library Management, I switch to &lt;STRONG&gt;Run only mode&lt;/STRONG&gt; &amp;amp; invoke the function,&amp;nbsp;&lt;/H4&gt;&lt;LI-CODE lang="javascript"&gt;{
  "functionName": "testFunction",
  "invocationId": "00000000-0000-0000-0000-000000000000",
  "status": "Failed",
  "errors": [
    {
      "errorCode": "WorkloadException",
      "subErrorCode": "NotFound",
      "message": "User data function: 'testFunction' invocation failed."
    }
  ]
}&lt;/LI-CODE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Why does the Fabric backend fail to resolve the endpoint in Published mode (returning NotFound) when the same function is fully functional in the Develop sandbox?&lt;/P&gt;</description>
      <pubDate>Mon, 23 Mar 2026 12:54:47 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/Activator/User-Data-Function-NotFound-Error-WorkloadException-after/m-p/5137556#M987</guid>
      <dc:creator>Izyaan_sc</dc:creator>
      <dc:date>2026-03-23T12:54:47Z</dc:date>
    </item>
    <item>
      <title>Re: User Data Function: 'NotFound' Error (WorkloadException) after Publishing, but Success in Develop</title>
      <link>https://community.fabric.microsoft.com/t5/Activator/User-Data-Function-NotFound-Error-WorkloadException-after/m-p/5138170#M989</link>
      <description>&lt;P&gt;Hi&amp;nbsp;&lt;a href="javascript:void(0)" data-lia-user-mentions="" data-lia-user-uid="1570257" data-lia-user-login="Izyaan_sc" class="lia-mention lia-mention-user"&gt;Izyaan_sc&lt;/a&gt;&amp;nbsp;,&lt;/P&gt;
&lt;P&gt;Fabric User Data Functions need to be published before invocation, and only published functions are accessible in Run mode or from other services. In Develop mode, you can test functions without publishing, but Run mode uses only the deployed version. Each function is called through its public REST endpoint, requiring a published function and correct input parameters. If the function isn’t published or the request parameters are incorrect, the invocation will fail. Make sure the function is published and the parameters are correctly structured.&lt;/P&gt;
&lt;P&gt;&lt;A class="" title="https://learn.microsoft.com/en-us/fabric/data-engineering/user-data-functions/create-user-data-functions-portal#what-you-accomplish" href="https://learn.microsoft.com/en-us/fabric/data-engineering/user-data-functions/create-user-data-functions-portal#what-you-accomplish" target="_blank" rel="noreferrer noopener" aria-label="Link Quickstart - Create a Fabric User data functions item - Microsoft Fabric | Microsoft Learn"&gt;Quickstart - Create a Fabric User data functions item - Microsoft Fabric | Microsoft Learn&lt;/A&gt;&lt;/P&gt;
&lt;P&gt;&lt;A class="" title="https://learn.microsoft.com/en-us/fabric/data-engineering/user-data-functions/tutorial-invoke-from-python-app#get-the-function-url-to-invoke" href="https://learn.microsoft.com/en-us/fabric/data-engineering/user-data-functions/tutorial-invoke-from-python-app#get-the-function-url-to-invoke" target="_blank" rel="noreferrer noopener" aria-label="Link Tutorial - Invoke user data functions from a Python application - Microsoft Fabric | Microsoft Learn"&gt;Tutorial - Invoke user data functions from a Python application - Microsoft Fabric | Microsoft Learn&lt;/A&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Thank you.&lt;/P&gt;
&lt;P&gt;&lt;LI-WRAPPER&gt;&lt;/LI-WRAPPER&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Tue, 24 Mar 2026 09:35:38 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/Activator/User-Data-Function-NotFound-Error-WorkloadException-after/m-p/5138170#M989</guid>
      <dc:creator>v-saisrao-msft</dc:creator>
      <dc:date>2026-03-24T09:35:38Z</dc:date>
    </item>
    <item>
      <title>Re: User Data Function: 'NotFound' Error (WorkloadException) after Publishing, but Success in Develop</title>
      <link>https://community.fabric.microsoft.com/t5/Activator/User-Data-Function-NotFound-Error-WorkloadException-after/m-p/5138179#M990</link>
      <description>&lt;P&gt;Hi &lt;a href="javascript:void(0)" data-lia-user-mentions="" data-lia-user-uid="883010" data-lia-user-login="v-saisrao-msft" class="lia-mention lia-mention-user"&gt;v-saisrao-msft&lt;/a&gt;,&amp;nbsp;&lt;BR /&gt;As mentioned in my post, I have already published the function multiple times. The function works as expected in Develop mode, but the invocation issue only persists in Run mode after publishing.&lt;/P&gt;</description>
      <pubDate>Tue, 24 Mar 2026 09:59:09 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/Activator/User-Data-Function-NotFound-Error-WorkloadException-after/m-p/5138179#M990</guid>
      <dc:creator>Izyaan_sc</dc:creator>
      <dc:date>2026-03-24T09:59:09Z</dc:date>
    </item>
    <item>
      <title>Re: User Data Function: 'NotFound' Error (WorkloadException) after Publishing, but Success in Develop</title>
      <link>https://community.fabric.microsoft.com/t5/Activator/User-Data-Function-NotFound-Error-WorkloadException-after/m-p/5140947#M995</link>
      <description>&lt;P&gt;Hi&amp;nbsp;&lt;a href="javascript:void(0)" data-lia-user-mentions="" data-lia-user-uid="1570257" data-lia-user-login="Izyaan_sc" class="lia-mention lia-mention-user"&gt;Izyaan_sc&lt;/a&gt;,&lt;/P&gt;
&lt;P&gt;The function is working correctly in Develop mode, which confirms that the KQL query and Python logic are valid.&lt;/P&gt;
&lt;P&gt;The failure in Run (Published) mode is due to Microsoft Fabric runtime limitations. In the published environment, User Data Functions run in a managed backend with restricted capabilities. Specifically, outbound network calls and certain custom dependencies are not fully supported or guaranteed to work.&lt;/P&gt;
&lt;P&gt;Because the function attempts to push data to an external Mimir endpoint, the backend is unable to execute the request, resulting in a generic “WorkloadException: NotFound” error. This error indicates a runtime execution failure rather than a missing function.&lt;/P&gt;
&lt;P&gt;As per Microsoft Fabric design guidance, User Data Functions should be used for lightweight, in-platform processing. For external integrations such as pushing metrics to external systems, it is recommended to use Fabric pipelines, notebooks, or external services (e.g., Azure Functions) instead of UDFs.&lt;/P&gt;
&lt;P&gt;We recommend redesigning the solution so that Activator triggers a Fabric-native output (such as a pipeline or table), and the external call to Mimir is handled outside the UDF.&lt;/P&gt;
&lt;P&gt;&lt;A href="https://learn.microsoft.com/en-us/fabric/data-engineering/user-data-functions/user-data-functions-service-limits" target="_blank"&gt;Service details and limitations - Microsoft Fabric | Microsoft Learn&lt;/A&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Thank you.&lt;/P&gt;
&lt;P&gt;&lt;LI-WRAPPER&gt;&lt;/LI-WRAPPER&gt;&lt;/P&gt;</description>
      <pubDate>Mon, 30 Mar 2026 08:54:47 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/Activator/User-Data-Function-NotFound-Error-WorkloadException-after/m-p/5140947#M995</guid>
      <dc:creator>v-saisrao-msft</dc:creator>
      <dc:date>2026-03-30T08:54:47Z</dc:date>
    </item>
    <item>
      <title>Re: User Data Function: 'NotFound' Error (WorkloadException) after Publishing, but Success in Develop</title>
      <link>https://community.fabric.microsoft.com/t5/Activator/User-Data-Function-NotFound-Error-WorkloadException-after/m-p/5142775#M997</link>
      <description>&lt;P&gt;Hi&amp;nbsp;&lt;a href="javascript:void(0)" data-lia-user-mentions="" data-lia-user-uid="1570257" data-lia-user-login="Izyaan_sc" class="lia-mention lia-mention-user"&gt;Izyaan_sc&lt;/a&gt;,&lt;/P&gt;
&lt;P&gt;&lt;SPAN data-teams="true"&gt;Have you had a chance to review the solution we shared earlier? If the issue persists, feel free to reply so we can help further.&lt;/SPAN&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&lt;SPAN data-teams="true"&gt;Thank you.&lt;/SPAN&gt;&lt;/P&gt;</description>
      <pubDate>Thu, 02 Apr 2026 04:15:49 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/Activator/User-Data-Function-NotFound-Error-WorkloadException-after/m-p/5142775#M997</guid>
      <dc:creator>v-saisrao-msft</dc:creator>
      <dc:date>2026-04-02T04:15:49Z</dc:date>
    </item>
    <item>
      <title>Re: User Data Function: 'NotFound' Error (WorkloadException) after Publishing, but Success in Develop</title>
      <link>https://community.fabric.microsoft.com/t5/Activator/User-Data-Function-NotFound-Error-WorkloadException-after/m-p/5143851#M998</link>
      <description>&lt;P&gt;Hi&amp;nbsp;&lt;a href="javascript:void(0)" data-lia-user-mentions="" data-lia-user-uid="1570257" data-lia-user-login="Izyaan_sc" class="lia-mention lia-mention-user"&gt;Izyaan_sc&lt;/a&gt;,&lt;/P&gt;
&lt;P&gt;Checking in to see if your issue has been resolved. let us know if you still need any assistance.&lt;/P&gt;
&lt;P&gt;&lt;LI-WRAPPER&gt;&lt;/LI-WRAPPER&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Thank you.&lt;/P&gt;</description>
      <pubDate>Mon, 06 Apr 2026 03:26:36 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/Activator/User-Data-Function-NotFound-Error-WorkloadException-after/m-p/5143851#M998</guid>
      <dc:creator>v-saisrao-msft</dc:creator>
      <dc:date>2026-04-06T03:26:36Z</dc:date>
    </item>
    <item>
      <title>Re: User Data Function: 'NotFound' Error (WorkloadException) after Publishing, but Success in Develop</title>
      <link>https://community.fabric.microsoft.com/t5/Activator/User-Data-Function-NotFound-Error-WorkloadException-after/m-p/5144074#M999</link>
      <description>&lt;P&gt;Actually, connecting to the Mimir endpoint isn't the bottleneck here(tested using another udf and it worked in run mode). The issue appears to be specifically related to the UDF runtime failing to recognize the Prometheus library.&amp;nbsp;I’ll follow your suggestion and move this to a Fabric Notebook, thanks.&lt;/P&gt;</description>
      <pubDate>Mon, 06 Apr 2026 08:59:50 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/Activator/User-Data-Function-NotFound-Error-WorkloadException-after/m-p/5144074#M999</guid>
      <dc:creator>Izyaan_sc</dc:creator>
      <dc:date>2026-04-06T08:59:50Z</dc:date>
    </item>
    <item>
      <title>Re: User Data Function: 'NotFound' Error (WorkloadException) after Publishing, but Success in Develop</title>
      <link>https://community.fabric.microsoft.com/t5/Activator/User-Data-Function-NotFound-Error-WorkloadException-after/m-p/5144920#M1000</link>
      <description>&lt;P&gt;Hi&amp;nbsp;&lt;a href="javascript:void(0)" data-lia-user-mentions="" data-lia-user-uid="1570257" data-lia-user-login="Izyaan_sc" class="lia-mention lia-mention-user"&gt;Izyaan_sc&lt;/a&gt;,&lt;/P&gt;
&lt;P&gt;Thank you for considering the suggestion to use Fabric Notebook. If you encounter any further issues, you can start a new thread in the community.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Wed, 08 Apr 2026 04:45:58 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/Activator/User-Data-Function-NotFound-Error-WorkloadException-after/m-p/5144920#M1000</guid>
      <dc:creator>v-saisrao-msft</dc:creator>
      <dc:date>2026-04-08T04:45:58Z</dc:date>
    </item>
  </channel>
</rss>

