<?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 Accessing unity catalog volumes from a databricks web application in Data Governance</title>
    <link>https://community.databricks.com/t5/data-governance/accessing-unity-catalog-volumes-from-a-databricks-web/m-p/122325#M2507</link>
    <description>&lt;P&gt;Hello,&lt;/P&gt;&lt;P&gt;I am trying to deploy a gradio app (app.py) in databricks, but I am having problem accessing data stored in a volume in unity catalog. It seems like that I cannot access the data using path like "&lt;SPAN&gt;/Volumes/catalog/schema.../my_data&lt;/SPAN&gt;", which works fine while running in a notebook in workspace with unity catalog enabled.&amp;nbsp;I have also tried using path like "dbfs:/..." and added the volume as a resource, but none of them is working.&lt;/P&gt;&lt;P&gt;I would like to ask if I am doing it correctly, or is there other way to reach the data (They are model weights saved as .pt).&lt;/P&gt;&lt;P&gt;One method that comes to my mind is using delta sharing to share the volume. However, it seems like that delta sharing is only available for tabular data.&lt;/P&gt;&lt;P&gt;Thanks.&lt;/P&gt;</description>
    <pubDate>Fri, 20 Jun 2025 09:07:00 GMT</pubDate>
    <dc:creator>kktim</dc:creator>
    <dc:date>2025-06-20T09:07:00Z</dc:date>
    <item>
      <title>Accessing unity catalog volumes from a databricks web application</title>
      <link>https://community.databricks.com/t5/data-governance/accessing-unity-catalog-volumes-from-a-databricks-web/m-p/122325#M2507</link>
      <description>&lt;P&gt;Hello,&lt;/P&gt;&lt;P&gt;I am trying to deploy a gradio app (app.py) in databricks, but I am having problem accessing data stored in a volume in unity catalog. It seems like that I cannot access the data using path like "&lt;SPAN&gt;/Volumes/catalog/schema.../my_data&lt;/SPAN&gt;", which works fine while running in a notebook in workspace with unity catalog enabled.&amp;nbsp;I have also tried using path like "dbfs:/..." and added the volume as a resource, but none of them is working.&lt;/P&gt;&lt;P&gt;I would like to ask if I am doing it correctly, or is there other way to reach the data (They are model weights saved as .pt).&lt;/P&gt;&lt;P&gt;One method that comes to my mind is using delta sharing to share the volume. However, it seems like that delta sharing is only available for tabular data.&lt;/P&gt;&lt;P&gt;Thanks.&lt;/P&gt;</description>
      <pubDate>Fri, 20 Jun 2025 09:07:00 GMT</pubDate>
      <guid>https://community.databricks.com/t5/data-governance/accessing-unity-catalog-volumes-from-a-databricks-web/m-p/122325#M2507</guid>
      <dc:creator>kktim</dc:creator>
      <dc:date>2025-06-20T09:07:00Z</dc:date>
    </item>
    <item>
      <title>Re: Accessing unity catalog volumes from a databricks web application</title>
      <link>https://community.databricks.com/t5/data-governance/accessing-unity-catalog-volumes-from-a-databricks-web/m-p/122468#M2508</link>
      <description>&lt;P&gt;Hi&amp;nbsp;&lt;a href="https://community.databricks.com/t5/user/viewprofilepage/user-id/170936"&gt;@kktim&lt;/a&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;You're facing a common challenge with Gradio apps in Databricks.&lt;BR /&gt;The issue is that Gradio apps run in a different execution context than notebooks,&lt;BR /&gt;so they don't have the same access to Unity Catalog volumes.&lt;/P&gt;&lt;P&gt;&lt;BR /&gt;Here are several approaches to solve this:&lt;BR /&gt;&lt;STRONG&gt;Solution 1: Copy Files to DBFS During App Initialization&lt;/STRONG&gt;&lt;BR /&gt;This is often the most reliable approach:&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;Solution 2: Use Databricks File System API&lt;/STRONG&gt;&lt;BR /&gt;Access files programmatically using the Databricks API:&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;Solution 3: Mount Volume to DBFS&lt;/STRONG&gt;&lt;BR /&gt;If you have admin access, you can mount the volume:&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;Solution 4: Environment Variables and Startup Script&lt;/STRONG&gt;&lt;BR /&gt;Create a startup script that sets up the environment:&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;Solution 5: Use MLflow Model Registry&lt;/STRONG&gt;&lt;BR /&gt;If these are ML models, consider using MLflow:&lt;/P&gt;&lt;P&gt;The key insight is that Gradio apps run in a containerized environment that doesn't have the same direct access to Unity Catalog volumes as notebooks do.&lt;BR /&gt;By copying the files during app initialization, you ensure they're available in the app's execution context.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Sun, 22 Jun 2025 16:49:17 GMT</pubDate>
      <guid>https://community.databricks.com/t5/data-governance/accessing-unity-catalog-volumes-from-a-databricks-web/m-p/122468#M2508</guid>
      <dc:creator>lingareddy_Alva</dc:creator>
      <dc:date>2025-06-22T16:49:17Z</dc:date>
    </item>
    <item>
      <title>Re: Accessing unity catalog volumes from a databricks web application</title>
      <link>https://community.databricks.com/t5/data-governance/accessing-unity-catalog-volumes-from-a-databricks-web/m-p/132713#M2609</link>
      <description>&lt;P&gt;&lt;SPAN&gt;Unlike notebooks, Databricks Apps does not support mounting Unity Catalog volumes and directly reading and writing files. As this code snippet demonstrates, each file needs to be downloaded to the app compute before being able to manipulate it.&lt;/SPAN&gt;&lt;/P&gt;</description>
      <pubDate>Mon, 22 Sep 2025 16:04:09 GMT</pubDate>
      <guid>https://community.databricks.com/t5/data-governance/accessing-unity-catalog-volumes-from-a-databricks-web/m-p/132713#M2609</guid>
      <dc:creator>MMRDUS</dc:creator>
      <dc:date>2025-09-22T16:04:09Z</dc:date>
    </item>
  </channel>
</rss>

