<?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 Mongodb connection in GCP Databricks in Data Engineering</title>
    <link>https://community.databricks.com/t5/data-engineering/mongodb-connection-in-gcp-databricks/m-p/130275#M48740</link>
    <description>I am trying to connect with Mongodb from databricks which is UC enabled, and both the mongodb and databricks are in same VPC, I am using the below code, df = ( spark.read.format("mongodb") .option( "connection.uri", f'''mongodb://{username}:{password}@{cluster_uri}:27017/{database}?authSource={database}&amp;amp;directConnection=true''' ) .option("database", database) .option("collection", table_name) .load() ) 1. when trying with shared cluster, I am getting this error "[UC_COMMAND_NOT_SUPPORTED.WITHOUT_RECOMMENDATION] The command(s): Data source v2 are not supported in Unity Catalog. SQLSTATE: 0AKUC". 2. when trying with legacy cluster, I am getting different error, 3. when trying with pandas with shared cluster it's working, but for larger datasets it's failing, 4. when trying with single user dedicated cluster the same code works. What is the difference between shared cluster and single user dedicated cluster, why it is not working with shared cluster where uc enabled, and why it is working with single user dedicated cluster with uc enabled.</description>
    <pubDate>Sun, 31 Aug 2025 16:33:38 GMT</pubDate>
    <dc:creator>xavier_db</dc:creator>
    <dc:date>2025-08-31T16:33:38Z</dc:date>
    <item>
      <title>Mongodb connection in GCP Databricks</title>
      <link>https://community.databricks.com/t5/data-engineering/mongodb-connection-in-gcp-databricks/m-p/130275#M48740</link>
      <description>I am trying to connect with Mongodb from databricks which is UC enabled, and both the mongodb and databricks are in same VPC, I am using the below code, df = ( spark.read.format("mongodb") .option( "connection.uri", f'''mongodb://{username}:{password}@{cluster_uri}:27017/{database}?authSource={database}&amp;amp;directConnection=true''' ) .option("database", database) .option("collection", table_name) .load() ) 1. when trying with shared cluster, I am getting this error "[UC_COMMAND_NOT_SUPPORTED.WITHOUT_RECOMMENDATION] The command(s): Data source v2 are not supported in Unity Catalog. SQLSTATE: 0AKUC". 2. when trying with legacy cluster, I am getting different error, 3. when trying with pandas with shared cluster it's working, but for larger datasets it's failing, 4. when trying with single user dedicated cluster the same code works. What is the difference between shared cluster and single user dedicated cluster, why it is not working with shared cluster where uc enabled, and why it is working with single user dedicated cluster with uc enabled.</description>
      <pubDate>Sun, 31 Aug 2025 16:33:38 GMT</pubDate>
      <guid>https://community.databricks.com/t5/data-engineering/mongodb-connection-in-gcp-databricks/m-p/130275#M48740</guid>
      <dc:creator>xavier_db</dc:creator>
      <dc:date>2025-08-31T16:33:38Z</dc:date>
    </item>
    <item>
      <title>Re: Mongodb connection in GCP Databricks</title>
      <link>https://community.databricks.com/t5/data-engineering/mongodb-connection-in-gcp-databricks/m-p/130288#M48742</link>
      <description>&lt;P&gt;Hi&amp;nbsp;&lt;a href="https://community.databricks.com/t5/user/viewprofilepage/user-id/110683"&gt;@xavier_db&lt;/a&gt;&amp;nbsp;,&lt;/P&gt;&lt;P&gt;Standard access mode has more limitations compared to dedicate access mode. For example, look at the limitations list of standard access mode:&lt;/P&gt;&lt;P&gt;&lt;A href="https://docs.databricks.com/aws/en/compute/standard-limitations" target="_blank" rel="noopener"&gt;Standard compute requirements and limitations | Databricks on AWS&lt;/A&gt;&lt;/P&gt;&lt;P&gt;Now, compare it to dedicated access mode:&lt;/P&gt;&lt;P&gt;&lt;A href="https://docs.databricks.com/aws/en/compute/dedicated-limitations" target="_blank" rel="noopener"&gt;Dedicated compute requirements and limitations | Databricks on AWS&lt;/A&gt;&lt;/P&gt;&lt;P&gt;As you can see, in dedicated access mode you can do much more things. Probably mongodb connector requires access to some API which is blocked in standard access mode (maybe RDD API), but is allowed in dedicated access mode.&amp;nbsp;&lt;/P&gt;&lt;P&gt;That's why it works on dedicated access mode.&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Sun, 31 Aug 2025 19:38:10 GMT</pubDate>
      <guid>https://community.databricks.com/t5/data-engineering/mongodb-connection-in-gcp-databricks/m-p/130288#M48742</guid>
      <dc:creator>szymon_dybczak</dc:creator>
      <dc:date>2025-08-31T19:38:10Z</dc:date>
    </item>
  </channel>
</rss>

