<?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 Databricks Connect - Will I ever have to Stop clean up Spark session when creating new per request in Data Engineering</title>
    <link>https://community.databricks.com/t5/data-engineering/databricks-connect-will-i-ever-have-to-stop-clean-up-spark/m-p/159094#M54789</link>
    <description>&lt;P&gt;I have API that triggers Spark calculations - with API hosted by Python 3.12 pod in AKS and connects to Databricks cluster using Databricks 18.1.1.&lt;/P&gt;&lt;P&gt;Initially I was using getOrCreate call on my API requests and all works.&lt;/P&gt;&lt;P&gt;But problem is - as Spark session is shared.. after a while when new API request comes in, it fails with "INVALID SESSION" - this is because Cluster expired the Spark session after waiting enough due to inactivity - looks like.&lt;/P&gt;&lt;P&gt;I also felt like sharing same Spark session is not my intention as I was to isolate each API call/request and create NEW Spark session per request.&lt;/P&gt;&lt;P&gt;So now I am using create NEW Spark session per API request and dont have any issues.&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;But do I need to do any clean up?&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;If I am creating NEW session , I feel tempted to call Stop session or do any clean up once I am done.&lt;/P&gt;&lt;P&gt;But documentation seems to suggest never explicitly call STOP Session.&lt;/P&gt;&lt;P&gt;I am not seeing any issues so far by not calling STOP but not sure if this causes any resource leaks and want to do what is right?&lt;/P&gt;&lt;P&gt;What is right way to clean up Spark Session in this&amp;nbsp; case when its created explicitly per API request? Do nothing like what I am doing OR call STOP - please suggest&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
    <pubDate>Mon, 15 Jun 2026 23:35:16 GMT</pubDate>
    <dc:creator>JTBS</dc:creator>
    <dc:date>2026-06-15T23:35:16Z</dc:date>
    <item>
      <title>Databricks Connect - Will I ever have to Stop clean up Spark session when creating new per request</title>
      <link>https://community.databricks.com/t5/data-engineering/databricks-connect-will-i-ever-have-to-stop-clean-up-spark/m-p/159094#M54789</link>
      <description>&lt;P&gt;I have API that triggers Spark calculations - with API hosted by Python 3.12 pod in AKS and connects to Databricks cluster using Databricks 18.1.1.&lt;/P&gt;&lt;P&gt;Initially I was using getOrCreate call on my API requests and all works.&lt;/P&gt;&lt;P&gt;But problem is - as Spark session is shared.. after a while when new API request comes in, it fails with "INVALID SESSION" - this is because Cluster expired the Spark session after waiting enough due to inactivity - looks like.&lt;/P&gt;&lt;P&gt;I also felt like sharing same Spark session is not my intention as I was to isolate each API call/request and create NEW Spark session per request.&lt;/P&gt;&lt;P&gt;So now I am using create NEW Spark session per API request and dont have any issues.&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;But do I need to do any clean up?&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;If I am creating NEW session , I feel tempted to call Stop session or do any clean up once I am done.&lt;/P&gt;&lt;P&gt;But documentation seems to suggest never explicitly call STOP Session.&lt;/P&gt;&lt;P&gt;I am not seeing any issues so far by not calling STOP but not sure if this causes any resource leaks and want to do what is right?&lt;/P&gt;&lt;P&gt;What is right way to clean up Spark Session in this&amp;nbsp; case when its created explicitly per API request? Do nothing like what I am doing OR call STOP - please suggest&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Mon, 15 Jun 2026 23:35:16 GMT</pubDate>
      <guid>https://community.databricks.com/t5/data-engineering/databricks-connect-will-i-ever-have-to-stop-clean-up-spark/m-p/159094#M54789</guid>
      <dc:creator>JTBS</dc:creator>
      <dc:date>2026-06-15T23:35:16Z</dc:date>
    </item>
    <item>
      <title>Re: Databricks Connect - Will I ever have to Stop clean up Spark session when creating new per reque</title>
      <link>https://community.databricks.com/t5/data-engineering/databricks-connect-will-i-ever-have-to-stop-clean-up-spark/m-p/159140#M54791</link>
      <description>&lt;P&gt;Hi,&amp;nbsp;&lt;/P&gt;&lt;P&gt;You can use Databricks SQL Connector for the activities instead of Databricks Connect if you require simple setup &amp;amp; easier management (session etc) with features below&lt;/P&gt;&lt;UL&gt;&lt;LI&gt;SQL queries (&lt;SPAN class=""&gt;SELECT&lt;/SPAN&gt;,&lt;SPAN&gt;&amp;nbsp;&lt;/SPAN&gt;&lt;SPAN class=""&gt;INSERT&lt;/SPAN&gt;,&lt;SPAN&gt;&amp;nbsp;&lt;/SPAN&gt;&lt;SPAN class=""&gt;UPDATE&lt;/SPAN&gt;)&lt;/LI&gt;&lt;LI&gt;Executing parameterized SQL statements&lt;/LI&gt;&lt;LI&gt;Fetching data and doing transformations in Python after retrieval&lt;/LI&gt;&lt;/UL&gt;&lt;P&gt;More details &lt;A href="https://docs.databricks.com/aws/en/dev-tools/python-sql-connector" target="_self"&gt;here&lt;/A&gt;&lt;/P&gt;&lt;P&gt;Apache Spark generally requires you to explicitly declare that they are complete by using commands such as&amp;nbsp;&lt;SPAN class=""&gt;sys.exit()&lt;/SPAN&gt;&amp;nbsp;or&amp;nbsp;&lt;STRONG&gt;&lt;SPAN class=""&gt;sc.stop()&lt;/SPAN&gt;&lt;/STRONG&gt;. Databricks &lt;STRONG&gt;automatically&lt;/STRONG&gt; &lt;STRONG&gt;terminates&lt;/STRONG&gt; and cleans up jobs as they reach completion, so these commands are not necessary and should be removed.&amp;nbsp;&lt;SPAN&gt;The automatic cleanup occurs when the request completes.&lt;/SPAN&gt;&lt;/P&gt;</description>
      <pubDate>Tue, 16 Jun 2026 09:45:16 GMT</pubDate>
      <guid>https://community.databricks.com/t5/data-engineering/databricks-connect-will-i-ever-have-to-stop-clean-up-spark/m-p/159140#M54791</guid>
      <dc:creator>balajij8</dc:creator>
      <dc:date>2026-06-16T09:45:16Z</dc:date>
    </item>
    <item>
      <title>Re: Databricks Connect - Will I ever have to Stop clean up Spark session when creating new per reque</title>
      <link>https://community.databricks.com/t5/data-engineering/databricks-connect-will-i-ever-have-to-stop-clean-up-spark/m-p/159142#M54792</link>
      <description>&lt;P&gt;Hi there,&lt;/P&gt;
&lt;P&gt;I&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;H3 class="du-bois-light-typography css-1bc5il7" data-genai-markdown-block="true"&gt;Short answer&lt;/H3&gt;
&lt;DIV class="du-bois-light-typography css-5lgemp" data-genai-markdown-block="true"&gt;You should call&lt;SPAN&gt;&amp;nbsp;&lt;/SPAN&gt;&lt;SPAN class="du-bois-light-typography css-1ifq98"&gt;&lt;CODE&gt;spark.stop()&lt;/CODE&gt;&lt;/SPAN&gt;&lt;SPAN&gt;&amp;nbsp;&lt;/SPAN&gt;when you're done with each session. What you're doing now (not calling it) works, but it's not ideal — you're relying on the server-side idle timeout to clean up after you, and in the meantime each orphaned session consumes memory on the cluster for its SQLConf and SessionState. On a busy API with many requests, that can accumulate until the cluster eventually reclaims them.&lt;/DIV&gt;
&lt;H3 class="du-bois-light-typography css-1bc5il7" data-genai-markdown-block="true"&gt;Why the docs say "don't call stop"&lt;/H3&gt;
&lt;DIV class="du-bois-light-typography css-5lgemp" data-genai-markdown-block="true"&gt;The documentation warning about not calling&lt;SPAN&gt;&amp;nbsp;&lt;/SPAN&gt;&lt;SPAN class="du-bois-light-typography css-1ifq98"&gt;&lt;CODE&gt;stop()&lt;/CODE&gt;&lt;/SPAN&gt;&lt;SPAN&gt;&amp;nbsp;&lt;/SPAN&gt;is aimed at a different scenario — specifically, when you're running inside a Databricks notebook or workspace environment where the session lifecycle is managed for you. In that context, calling&lt;SPAN&gt;&amp;nbsp;&lt;/SPAN&gt;&lt;SPAN class="du-bois-light-typography css-1ifq98"&gt;&lt;CODE&gt;stop()&lt;/CODE&gt;&lt;/SPAN&gt;&lt;SPAN&gt;&amp;nbsp;&lt;/SPAN&gt;can tear down shared infrastructure you didn't create. It doesn't apply to your situation, where you're an external client creating sessions explicitly via Databricks Connect from an AKS pod. (&lt;A class="du-bois-light-typography css-1zhnxz" role="link" href="https://docs.databricks.com/aws/en/dev-tools/databricks-connect/notebooks" rel="noopener noreferrer" data-component-type="typography_link" data-component-id="codegen_webapp_js_genai_util_markdown.tsx_71" aria-disabled="false" target="_blank"&gt;Databricks Connect in notebooks&lt;/A&gt;)&lt;/DIV&gt;
&lt;H3 class="du-bois-light-typography css-1bc5il7" data-genai-markdown-block="true"&gt;What about automatic cleanup?&lt;/H3&gt;
&lt;DIV class="du-bois-light-typography css-5lgemp" data-genai-markdown-block="true"&gt;You may have read that Databricks Connect handles session cleanup automatically — and that's partially true. There are two mechanisms:&lt;/DIV&gt;
&lt;UL class="css-0"&gt;
&lt;LI&gt;
&lt;DIV class="du-bois-light-typography css-5lgemp" data-genai-markdown-block="true"&gt;&lt;STRONG&gt;Process exit / shutdown hooks&lt;/STRONG&gt;: PySpark registers an&lt;SPAN&gt;&amp;nbsp;&lt;/SPAN&gt;&lt;SPAN class="du-bois-light-typography css-1ifq98"&gt;&lt;CODE&gt;atexit&lt;/CODE&gt;&lt;/SPAN&gt;&lt;SPAN&gt;&amp;nbsp;&lt;/SPAN&gt;handler that calls&lt;SPAN&gt;&amp;nbsp;&lt;/SPAN&gt;&lt;SPAN class="du-bois-light-typography css-1ifq98"&gt;&lt;CODE&gt;stop()&lt;/CODE&gt;&lt;/SPAN&gt;&lt;SPAN&gt;&amp;nbsp;&lt;/SPAN&gt;on active sessions when the Python process terminates. If you were running a short-lived script (start, do work, exit), this would clean things up for you automatically. However, your API is a long-lived server process — it doesn't exit between requests. The shutdown hook only fires when the pod itself restarts or scales down, not after each request completes.&lt;/DIV&gt;
&lt;/LI&gt;
&lt;LI&gt;
&lt;DIV class="du-bois-light-typography css-5lgemp" data-genai-markdown-block="true"&gt;&lt;STRONG&gt;Server-side idle timeout&lt;/STRONG&gt;: The Spark Connect server passively cleans up idle sessions after a period of inactivity. The release notes confirm: "Databricks Connect now automatically closes expired sessions on the client side." So sessions do eventually get reclaimed — but in the meantime they're sitting there consuming driver memory. (&lt;A class="du-bois-light-typography css-1zhnxz" role="link" href="https://docs.databricks.com/aws/en/release-notes/dbconnect/" rel="noopener noreferrer" data-component-type="typography_link" data-component-id="codegen_webapp_js_genai_util_markdown.tsx_71" aria-disabled="false" target="_blank"&gt;Databricks Connect release notes&lt;/A&gt;)&lt;/DIV&gt;
&lt;/LI&gt;
&lt;/UL&gt;
&lt;DIV class="du-bois-light-typography css-5lgemp" data-genai-markdown-block="true"&gt;For a long-running API server creating a new session per request, neither mechanism gives you prompt cleanup. You'd accumulate sessions until the timeout kicks in.&lt;/DIV&gt;
&lt;H3 class="du-bois-light-typography css-1bc5il7" data-genai-markdown-block="true"&gt;What&lt;SPAN&gt;&amp;nbsp;&lt;/SPAN&gt;&lt;SPAN class="du-bois-light-typography css-1ifq98"&gt;&lt;CODE&gt;spark.stop()&lt;/CODE&gt;&lt;/SPAN&gt;&lt;SPAN&gt;&amp;nbsp;&lt;/SPAN&gt;actually does in Databricks Connect&lt;/H3&gt;
&lt;DIV class="du-bois-light-typography css-5lgemp" data-genai-markdown-block="true"&gt;Since version 14.2.0, calling&lt;SPAN&gt;&amp;nbsp;&lt;/SPAN&gt;&lt;SPAN class="du-bois-light-typography css-1ifq98"&gt;&lt;CODE&gt;stop()&lt;/CODE&gt;&lt;/SPAN&gt;&lt;SPAN&gt;&amp;nbsp;&lt;/SPAN&gt;on a Databricks Connect session sends a&lt;SPAN&gt;&amp;nbsp;&lt;/SPAN&gt;&lt;SPAN class="du-bois-light-typography css-1ifq98"&gt;&lt;CODE&gt;ReleaseSession&lt;/CODE&gt;&lt;/SPAN&gt;&lt;SPAN&gt;&amp;nbsp;&lt;/SPAN&gt;RPC to the server, which:&lt;/DIV&gt;
&lt;UL class="css-0"&gt;
&lt;LI&gt;Interrupts any running operations tied to that session&lt;/LI&gt;
&lt;LI&gt;Releases server-side resources (memory, cached state)&lt;/LI&gt;
&lt;LI&gt;Closes the gRPC channel on the client side&lt;/LI&gt;
&lt;/UL&gt;
&lt;DIV class="du-bois-light-typography css-5lgemp" data-genai-markdown-block="true"&gt;Since version 15.1.0,&lt;SPAN&gt;&amp;nbsp;&lt;/SPAN&gt;&lt;SPAN class="du-bois-light-typography css-1ifq98"&gt;&lt;CODE&gt;stop()&lt;/CODE&gt;&lt;/SPAN&gt;&lt;SPAN&gt;&amp;nbsp;&lt;/SPAN&gt;is also idempotent — calling it on an already-closed or expired session won't throw an error. So it's safe to call in a&lt;SPAN&gt;&amp;nbsp;&lt;/SPAN&gt;&lt;SPAN class="du-bois-light-typography css-1ifq98"&gt;&lt;CODE&gt;finally&lt;/CODE&gt;&lt;/SPAN&gt;&lt;SPAN&gt;&amp;nbsp;&lt;/SPAN&gt;block without worrying about race conditions with the idle timeout. (&lt;A class="du-bois-light-typography css-1zhnxz" role="link" href="https://docs.databricks.com/aws/en/release-notes/dbconnect/" rel="noopener noreferrer" data-component-type="typography_link" data-component-id="codegen_webapp_js_genai_util_markdown.tsx_71" aria-disabled="false" target="_blank"&gt;Databricks Connect release notes&lt;/A&gt;)&lt;/DIV&gt;
&lt;H3 class="du-bois-light-typography css-1bc5il7" data-genai-markdown-block="true"&gt;Recommended pattern&lt;/H3&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;DIV class="css-79elbk"&gt;
&lt;DIV class="css-agp2v7"&gt;&amp;nbsp;&lt;/DIV&gt;
&lt;PRE&gt;&lt;CODE&gt;&lt;SPAN class="token token"&gt;from&lt;/SPAN&gt;&lt;SPAN&gt; databricks&lt;/SPAN&gt;&lt;SPAN class="token token"&gt;.&lt;/SPAN&gt;&lt;SPAN&gt;connect &lt;/SPAN&gt;&lt;SPAN class="token token"&gt;import&lt;/SPAN&gt;&lt;SPAN&gt; DatabricksSession
&lt;/SPAN&gt;
&lt;SPAN class="token token"&gt;def&lt;/SPAN&gt; &lt;SPAN class="token token"&gt;handle_request&lt;/SPAN&gt;&lt;SPAN class="token token"&gt;(&lt;/SPAN&gt;&lt;SPAN class="token token"&gt;)&lt;/SPAN&gt;&lt;SPAN class="token token"&gt;:&lt;/SPAN&gt;
&lt;SPAN&gt;    spark &lt;/SPAN&gt;&lt;SPAN class="token token"&gt;=&lt;/SPAN&gt;&lt;SPAN&gt; DatabricksSession&lt;/SPAN&gt;&lt;SPAN class="token token"&gt;.&lt;/SPAN&gt;&lt;SPAN&gt;builder&lt;/SPAN&gt;&lt;SPAN class="token token"&gt;.&lt;/SPAN&gt;&lt;SPAN&gt;create&lt;/SPAN&gt;&lt;SPAN class="token token"&gt;(&lt;/SPAN&gt;&lt;SPAN class="token token"&gt;)&lt;/SPAN&gt;  &lt;SPAN class="token token"&gt;# new session per request&lt;/SPAN&gt;
    &lt;SPAN class="token token"&gt;try&lt;/SPAN&gt;&lt;SPAN class="token token"&gt;:&lt;/SPAN&gt;
        &lt;SPAN class="token token"&gt;# your Spark work here&lt;/SPAN&gt;
&lt;SPAN&gt;        result &lt;/SPAN&gt;&lt;SPAN class="token token"&gt;=&lt;/SPAN&gt;&lt;SPAN&gt; spark&lt;/SPAN&gt;&lt;SPAN class="token token"&gt;.&lt;/SPAN&gt;&lt;SPAN&gt;sql&lt;/SPAN&gt;&lt;SPAN class="token token"&gt;(&lt;/SPAN&gt;&lt;SPAN class="token token"&gt;"SELECT ..."&lt;/SPAN&gt;&lt;SPAN class="token token"&gt;)&lt;/SPAN&gt;
        &lt;SPAN class="token token"&gt;return&lt;/SPAN&gt;&lt;SPAN&gt; result&lt;/SPAN&gt;&lt;SPAN class="token token"&gt;.&lt;/SPAN&gt;&lt;SPAN&gt;collect&lt;/SPAN&gt;&lt;SPAN class="token token"&gt;(&lt;/SPAN&gt;&lt;SPAN class="token token"&gt;)&lt;/SPAN&gt;
    &lt;SPAN class="token token"&gt;finally&lt;/SPAN&gt;&lt;SPAN class="token token"&gt;:&lt;/SPAN&gt;
&lt;SPAN&gt;        spark&lt;/SPAN&gt;&lt;SPAN class="token token"&gt;.&lt;/SPAN&gt;&lt;SPAN&gt;stop&lt;/SPAN&gt;&lt;SPAN class="token token"&gt;(&lt;/SPAN&gt;&lt;SPAN class="token token"&gt;)&lt;/SPAN&gt;  &lt;SPAN class="token token"&gt;# clean up immediately&lt;/SPAN&gt;&lt;/CODE&gt;&lt;/PRE&gt;
&lt;/DIV&gt;
&lt;P&gt;&lt;LI-WRAPPER&gt;&lt;/LI-WRAPPER&gt;&lt;/P&gt;
&lt;PRE&gt;&amp;nbsp;&lt;/PRE&gt;
&lt;DIV class="du-bois-light-typography css-5lgemp" data-genai-markdown-block="true"&gt;A few notes:&lt;/DIV&gt;
&lt;UL class="css-0"&gt;
&lt;LI&gt;Use&lt;SPAN&gt;&amp;nbsp;&lt;/SPAN&gt;&lt;SPAN class="du-bois-light-typography css-1ifq98"&gt;&lt;CODE&gt;.create()&lt;/CODE&gt;&lt;/SPAN&gt;&lt;SPAN&gt;&amp;nbsp;&lt;/SPAN&gt;rather than&lt;SPAN&gt;&amp;nbsp;&lt;/SPAN&gt;&lt;SPAN class="du-bois-light-typography css-1ifq98"&gt;&lt;CODE&gt;.getOrCreate()&lt;/CODE&gt;&lt;/SPAN&gt;&lt;SPAN&gt;&amp;nbsp;&lt;/SPAN&gt;— you've already figured this out. The&lt;SPAN&gt;&amp;nbsp;&lt;/SPAN&gt;&lt;SPAN class="du-bois-light-typography css-1ifq98"&gt;&lt;CODE&gt;create()&lt;/CODE&gt;&lt;/SPAN&gt;&lt;SPAN&gt;&amp;nbsp;&lt;/SPAN&gt;API was introduced in 16.0 specifically for this use case (always creates a fresh session rather than returning an existing one). (&lt;A class="du-bois-light-typography css-1zhnxz" role="link" href="https://docs.databricks.com/aws/en/release-notes/dbconnect/" rel="noopener noreferrer" data-component-type="typography_link" data-component-id="codegen_webapp_js_genai_util_markdown.tsx_71" aria-disabled="false" target="_blank"&gt;Databricks Connect release notes&lt;/A&gt;)&lt;/LI&gt;
&lt;LI&gt;Wrap&lt;SPAN&gt;&amp;nbsp;&lt;/SPAN&gt;&lt;SPAN class="du-bois-light-typography css-1ifq98"&gt;&lt;CODE&gt;stop()&lt;/CODE&gt;&lt;/SPAN&gt;&lt;SPAN&gt;&amp;nbsp;&lt;/SPAN&gt;in a&lt;SPAN&gt;&amp;nbsp;&lt;/SPAN&gt;&lt;SPAN class="du-bois-light-typography css-1ifq98"&gt;&lt;CODE&gt;finally&lt;/CODE&gt;&lt;/SPAN&gt;&lt;SPAN&gt;&amp;nbsp;&lt;/SPAN&gt;block so it runs even if your Spark work throws an exception.&lt;/LI&gt;
&lt;LI&gt;If you're on 18.1.1 as you mentioned, you have all the idempotent-stop and transient-retry improvements, so this is straightforward.&lt;/LI&gt;
&lt;/UL&gt;
&lt;H3 class="du-bois-light-typography css-1bc5il7" data-genai-markdown-block="true"&gt;What happens if you don't call stop&lt;/H3&gt;
&lt;DIV class="du-bois-light-typography css-5lgemp" data-genai-markdown-block="true"&gt;It's not catastrophic — the server will eventually clean up idle sessions via the timeout. But you'll accumulate orphaned sessions in the interim, each holding memory on the driver. Under sustained load this can contribute to driver memory pressure.&lt;/DIV&gt;
&lt;DIV class="du-bois-light-typography css-5lgemp" data-genai-markdown-block="true"&gt;That said, if your request volume is modest and you're not seeing issues, the idle timeout is probably handling things adequately. It's more of a "doing it properly" thing than a "this will definitely break" thing.&lt;/DIV&gt;
&lt;H3 class="du-bois-light-typography css-1bc5il7" data-genai-markdown-block="true"&gt;Relevant docs&lt;/H3&gt;
&lt;UL class="css-0"&gt;
&lt;LI&gt;&lt;A class="du-bois-light-typography css-1zhnxz" role="link" href="https://docs.databricks.com/aws/en/dev-tools/databricks-connect" rel="noopener noreferrer" data-component-type="typography_link" data-component-id="codegen_webapp_js_genai_util_markdown.tsx_71" aria-disabled="false" target="_blank"&gt;Databricks Connect overview&lt;/A&gt;&lt;SPAN&gt;&amp;nbsp;&lt;/SPAN&gt;— general setup and architecture&lt;/LI&gt;
&lt;LI&gt;&lt;A class="du-bois-light-typography css-1zhnxz" role="link" href="https://docs.databricks.com/aws/en/release-notes/dbconnect/" rel="noopener noreferrer" data-component-type="typography_link" data-component-id="codegen_webapp_js_genai_util_markdown.tsx_71" aria-disabled="false" target="_blank"&gt;Databricks Connect release notes&lt;/A&gt;&lt;SPAN&gt;&amp;nbsp;&lt;/SPAN&gt;— where the&lt;SPAN&gt;&amp;nbsp;&lt;/SPAN&gt;&lt;SPAN class="du-bois-light-typography css-1ifq98"&gt;&lt;CODE&gt;create()&lt;/CODE&gt;&lt;/SPAN&gt;&lt;SPAN&gt;&amp;nbsp;&lt;/SPAN&gt;API, idempotent&lt;SPAN&gt;&amp;nbsp;&lt;/SPAN&gt;&lt;SPAN class="du-bois-light-typography css-1ifq98"&gt;&lt;CODE&gt;stop()&lt;/CODE&gt;&lt;/SPAN&gt;, and session expiry handling are documented&lt;/LI&gt;
&lt;LI&gt;&lt;A class="du-bois-light-typography css-1zhnxz" role="link" href="https://docs.databricks.com/aws/en/dev-tools/databricks-connect/cluster-config" rel="noopener noreferrer" data-component-type="typography_link" data-component-id="codegen_webapp_js_genai_util_markdown.tsx_71" aria-disabled="false" target="_blank"&gt;Compute configuration for Databricks Connect&lt;/A&gt;&lt;SPAN&gt;&amp;nbsp;&lt;/SPAN&gt;— session builder configuration options&lt;/LI&gt;
&lt;LI&gt;&lt;A class="du-bois-light-typography css-1zhnxz" role="link" href="https://docs.databricks.com/aws/en/dev-tools/databricks-connect/notebooks" rel="noopener noreferrer" data-component-type="typography_link" data-component-id="codegen_webapp_js_genai_util_markdown.tsx_71" aria-disabled="false" target="_blank"&gt;Databricks Connect in notebooks (workspace behaviour)&lt;/A&gt;&lt;SPAN&gt;&amp;nbsp;&lt;/SPAN&gt;— explains when&lt;SPAN&gt;&amp;nbsp;&lt;/SPAN&gt;&lt;SPAN class="du-bois-light-typography css-1ifq98"&gt;&lt;CODE&gt;stop()&lt;/CODE&gt;&lt;/SPAN&gt;&lt;SPAN&gt;&amp;nbsp;&lt;/SPAN&gt;should not be called (i.e. not your case)&lt;/LI&gt;
&lt;LI&gt;&lt;A class="du-bois-light-typography css-1zhnxz" role="link" href="https://docs.databricks.com/aws/en/spark/connect-vs-classic" rel="noopener noreferrer" data-component-type="typography_link" data-component-id="codegen_webapp_js_genai_util_markdown.tsx_71" aria-disabled="false" target="_blank"&gt;Spark Connect vs Spark Classic&lt;/A&gt;&lt;SPAN&gt;&amp;nbsp;&lt;/SPAN&gt;— best practices for the Spark Connect protocol your client uses&lt;/LI&gt;
&lt;/UL&gt;</description>
      <pubDate>Tue, 16 Jun 2026 10:09:47 GMT</pubDate>
      <guid>https://community.databricks.com/t5/data-engineering/databricks-connect-will-i-ever-have-to-stop-clean-up-spark/m-p/159142#M54792</guid>
      <dc:creator>emma_s</dc:creator>
      <dc:date>2026-06-16T10:09:47Z</dc:date>
    </item>
  </channel>
</rss>

