{"id":373,"date":"2026-02-24T11:37:08","date_gmt":"2026-02-24T10:37:08","guid":{"rendered":"https:\/\/dataguide.tech\/?p=373"},"modified":"2026-02-24T13:04:29","modified_gmt":"2026-02-24T12:04:29","slug":"custom-environment-whats-that-what-is-the-reason","status":"publish","type":"post","link":"https:\/\/dataguide.tech\/index.php\/2026\/02\/24\/custom-environment-whats-that-what-is-the-reason\/","title":{"rendered":"Custom Environment &#8211; what&#8217;s that, what is the reason"},"content":{"rendered":"\n<p>If you&#8217;re working with Microsoft Fabric and running complex workloads &#8211; multiple notebooks executing at the same time, or needing Python libraries that aren&#8217;t built-in &#8211; you&#8217;ve probably asked yourself: &#8220;How do I manage this properly?&#8221;<\/p>\n\n\n\n<p>The answer is <strong>Fabric Environments<\/strong>. In this post, I&#8217;ll walk you through what they are, how to configure them, and how to use them in your notebooks. For the full official reference, you can check the <a href=\"https:\/\/learn.microsoft.com\/en-us\/fabric\/data-engineering\/create-and-use-environment\" target=\"_blank\" rel=\"noopener\">Microsoft documentation on Fabric Environments<\/a>. Let&#8217;s get started.<\/p>\n\n\n\n<h1 class=\"wp-block-heading\">What Is a Fabric Environment?<\/h1>\n\n\n\n<p>An Environment in Microsoft Fabric lets you manage and reconfigure both hardware and software settings for your Spark workloads. Think of it as a centralized configuration layer where you can control:<\/p>\n\n\n\n<ul class=\"wp-block-list\">\n<li><strong>Spark runtimes<\/strong> &#8211; Choose your runtime version<\/li>\n\n\n\n<li><strong>Compute resources<\/strong> &#8211; Adjust driver\/executor cores and memory<\/li>\n\n\n\n<li><strong>Libraries<\/strong> &#8211; Install additional packages (from public repos or your own custom ones)<\/li>\n<\/ul>\n\n\n\n<p>Instead of scattering <code>pip install<\/code> commands across your notebooks, you define everything once in the Environment and it&#8217;s available wherever you need it.<\/p>\n\n\n\n<h1 class=\"wp-block-heading\">Creating and Configuring Your Environment<\/h1>\n\n\n\n<p>The Environment is a standard Fabric item. To create one:<\/p>\n\n\n\n<ol class=\"wp-block-list\">\n<li>Navigate to the workspace where you want to create it<\/li>\n\n\n\n<li>Click <strong>New Item<\/strong> and search for <strong>Environment<\/strong><\/li>\n\n\n\n<li>Give it a meaningful name (e.g., <code>ENV_DataEngineering<\/code>) and hit <strong>Create<\/strong><\/li>\n<\/ol>\n\n\n\n<p>You should see the following screen:<\/p>\n\n\n\n<figure class=\"wp-block-image\"><img decoding=\"async\" src=\"https:\/\/dataguide.tech\/wp-content\/uploads\/2026\/02\/Pasted-image-20251212094035-1.png\" alt=\"Pasted image 20251212094035.png\"\/><\/figure>\n\n\n\n<p>On the top menu, you can choose the <strong>Runtime<\/strong> &#8211; with details about Spark and Delta release versions. Need a newer or older version? You can switch it right there.<\/p>\n\n\n\n<p>On the left pane, you&#8217;ll find three sections: <strong>Libraries<\/strong>, <strong>Spark Compute<\/strong>, and <strong>Storage<\/strong>. Let&#8217;s walk through each one.<\/p>\n\n\n\n<h2 class=\"wp-block-heading\">Libraries<\/h2>\n\n\n\n<p>The Libraries section has three tabs:<\/p>\n\n\n\n<ul class=\"wp-block-list\">\n<li><strong>Built-in<\/strong> &#8211; Check what libraries are installed by default with your runtime<\/li>\n\n\n\n<li><strong>External repositories<\/strong> &#8211; Install libraries from pip or conda repositories (the process is the same for both). You can add them through the UI or via a YML file<\/li>\n\n\n\n<li><strong>Custom<\/strong> &#8211; Upload your own libraries in <code>.jar<\/code>, <code>.whl<\/code>, or <code>.tar.gz<\/code> format<\/li>\n<\/ul>\n\n\n\n<p>Once published, chosen libraries are available during the Spark session in any connected notebook right away &#8211; no more <code>pip install<\/code> cluttering your code.<\/p>\n\n\n\n<h2 class=\"wp-block-heading\">Spark Compute<\/h2>\n\n\n\n<p>Spark Compute contains three tabs:<\/p>\n\n\n\n<ul class=\"wp-block-list\">\n<li><strong>Acceleration<\/strong> &#8211; Enable Spark Native Execution Engine, which is particularly helpful for larger data processing workloads<\/li>\n\n\n\n<li><strong>Compute<\/strong> &#8211; Adjust your Spark compute configuration: driver and executor cores, memory allocation, dynamic allocation, and executor instances<\/li>\n\n\n\n<li><strong>Spark properties<\/strong> &#8211; Customize Spark job definitions and set properties like resource profiles to optimize compute for your workload<\/li>\n<\/ul>\n\n\n\n<h2 class=\"wp-block-heading\">Storage<\/h2>\n\n\n\n<p>Within Storage, you can add <strong>Resources<\/strong> &#8211; additional files you&#8217;d like to have available during a Spark session. Think of it as a shared folder across your team&#8217;s notebooks, unlike the notebook&#8217;s built-in resources folder which is scoped to a single notebook.<\/p>\n\n\n\n<p>To access these files from your notebook code, use the following utility:<\/p>\n\n\n\n<div class=\"wp-block-kevinbatdorf-code-block-pro cbp-has-line-numbers\" data-code-block-pro-font-family=\"Code-Pro-JetBrains-Mono\" style=\"font-size:.875rem;font-family:Code-Pro-JetBrains-Mono,ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,monospace;--cbp-line-number-color:#a6accd;--cbp-line-number-width:calc(1 * 0.6 * .875rem);line-height:1.25rem;--cbp-tab-width:2;tab-size:var(--cbp-tab-width, 2)\"><span style=\"display:flex;align-items:center;padding:10px 0px 10px 16px;margin-bottom:-2px;width:100%;text-align:left;background-color:#252937;color:#969dc4\">Python<\/span><span role=\"button\" tabindex=\"0\" style=\"color:#a6accd;display:none\" aria-label=\"Copy\" class=\"code-block-pro-copy-button\"><pre class=\"code-block-pro-copy-button-pre\" aria-hidden=\"true\"><textarea class=\"code-block-pro-copy-button-textarea\" tabindex=\"-1\" aria-hidden=\"true\" readonly>resource_dir = mssparkutils.env.getResourceDir()\n<\/textarea><\/pre><svg xmlns=\"http:\/\/www.w3.org\/2000\/svg\" style=\"width:24px;height:24px\" fill=\"none\" viewBox=\"0 0 24 24\" stroke=\"currentColor\" stroke-width=\"2\"><path class=\"with-check\" stroke-linecap=\"round\" stroke-linejoin=\"round\" d=\"M4.5 12.75l6 6 9-13.5\"><\/path><path class=\"without-check\" stroke-linecap=\"round\" stroke-linejoin=\"round\" d=\"M16.5 8.25V6a2.25 2.25 0 00-2.25-2.25H6A2.25 2.25 0 003.75 6v8.25A2.25 2.25 0 006 16.5h2.25m8.25-8.25H18a2.25 2.25 0 012.25 2.25V18A2.25 2.25 0 0118 20.25h-7.5A2.25 2.25 0 018.25 18v-1.5m8.25-8.25h-6a2.25 2.25 0 00-2.25 2.25v6\"><\/path><\/svg><\/span><pre class=\"shiki poimandres\" style=\"background-color: #1b1e28\" tabindex=\"0\"><code><span class=\"line\"><span style=\"color: #A6ACCD\">resource_dir <\/span><span style=\"color: #91B4D5\">=<\/span><span style=\"color: #A6ACCD\"> mssparkutils.env.getResourceDir()<\/span><\/span>\n<span class=\"line\"><\/span><\/code><\/pre><\/div>\n\n\n\n<p>This returns the path to the Resources directory, so you can read any uploaded file during the session.<\/p>\n\n\n\n<h1 class=\"wp-block-heading\">Configuration and Publishing<\/h1>\n\n\n\n<p>Now let&#8217;s dive into the details of configuring each section.<\/p>\n\n\n\n<h2 class=\"wp-block-heading\">Libraries Configuration<\/h2>\n\n\n\n<h3 class=\"wp-block-heading\">External Repositories<\/h3>\n\n\n\n<p>To add a library from a public repository:<\/p>\n\n\n\n<ol class=\"wp-block-list\">\n<li>Navigate to <strong>Libraries \u2192 External repositories<\/strong><\/li>\n\n\n\n<li>Click <strong>Add Library<\/strong> on the top bar<\/li>\n\n\n\n<li>Select <strong>Add library from public repository<\/strong><\/li>\n<\/ol>\n\n\n\n<figure class=\"wp-block-image\"><img loading=\"lazy\" decoding=\"async\" width=\"1116\" height=\"871\" src=\"https:\/\/dataguide.tech\/wp-content\/uploads\/2026\/02\/Pasted-image-20260113100159-1-1.png\" alt=\"Pasted image 20260113100159.png\" class=\"wp-image-382\" srcset=\"https:\/\/dataguide.tech\/wp-content\/uploads\/2026\/02\/Pasted-image-20260113100159-1-1.png 1116w, https:\/\/dataguide.tech\/wp-content\/uploads\/2026\/02\/Pasted-image-20260113100159-1-1-300x234.png 300w, https:\/\/dataguide.tech\/wp-content\/uploads\/2026\/02\/Pasted-image-20260113100159-1-1-1024x799.png 1024w, https:\/\/dataguide.tech\/wp-content\/uploads\/2026\/02\/Pasted-image-20260113100159-1-1-768x599.png 768w\" sizes=\"auto, (max-width: 1116px) 100vw, 1116px\" \/><\/figure>\n\n\n\n<p>Once you&#8217;ve set up your environment (I just added a new library, but you can adjust other properties as well), click the <strong>Publish<\/strong> button to apply your changes.<\/p>\n\n\n\n<p><strong>Heads up:<\/strong> Publishing takes several minutes. I&#8217;ve noticed it tends to go a bit faster when you keep the browser window active.<\/p>\n\n\n\n<figure class=\"wp-block-image\"><img loading=\"lazy\" decoding=\"async\" width=\"924\" height=\"274\" src=\"https:\/\/dataguide.tech\/wp-content\/uploads\/2026\/02\/Pasted-image-20260113101129-1-1.png\" alt=\"Pasted image 20260113101129.png\" class=\"wp-image-377\" srcset=\"https:\/\/dataguide.tech\/wp-content\/uploads\/2026\/02\/Pasted-image-20260113101129-1-1.png 924w, https:\/\/dataguide.tech\/wp-content\/uploads\/2026\/02\/Pasted-image-20260113101129-1-1-300x89.png 300w, https:\/\/dataguide.tech\/wp-content\/uploads\/2026\/02\/Pasted-image-20260113101129-1-1-768x228.png 768w\" sizes=\"auto, (max-width: 924px) 100vw, 924px\" \/><\/figure>\n\n\n\n<p>All properties can also be managed through YML files:<\/p>\n\n\n\n<ul class=\"wp-block-list\">\n<li>Libraries configuration:<br><figure><img decoding=\"async\" src=\"https:\/\/dataguide.tech\/wp-content\/uploads\/2026\/02\/Pasted-image-20260113101926-1.png\" alt=\"Pasted image 20260113101926.png\"><\/figure><\/li>\n\n\n\n<li>Spark properties:<br><figure><img decoding=\"async\" src=\"https:\/\/dataguide.tech\/wp-content\/uploads\/2026\/02\/Pasted-image-20260113101945-1.png\" alt=\"Pasted image 20260113101945.png\"><\/figure><\/li>\n<\/ul>\n\n\n\n<p>The Environment is also stored in your GitHub repository (if your workspace is connected to a repo) as a YML file. This means you can maintain it with an &#8220;as code&#8221; approach &#8211; which is great for version control and CI\/CD workflows.<\/p>\n\n\n\n<h3 class=\"wp-block-heading\">Custom Libraries<\/h3>\n\n\n\n<p>In the Custom libraries tab, you can upload your own libraries in supported formats (<code>.jar<\/code>, <code>.whl<\/code>, or <code>.tar.gz<\/code>). I&#8217;ll cover how to create custom libraries in a future post.<\/p>\n\n\n\n<p>To upload your own library:<\/p>\n\n\n\n<ol class=\"wp-block-list\">\n<li>Navigate to <strong>Custom<\/strong> under the <strong>Libraries<\/strong> section<\/li>\n\n\n\n<li>Click <strong>Upload<\/strong> and choose the file from your desktop<\/li>\n\n\n\n<li>Click <strong>Publish<\/strong> to make it available in your notebooks<\/li>\n<\/ol>\n\n\n\n<h2 class=\"wp-block-heading\">Spark Compute Configuration<\/h2>\n\n\n\n<h3 class=\"wp-block-heading\">Acceleration<\/h3>\n\n\n\n<p>The Native Execution Engine for Spark was introduced by Microsoft to boost performance. It&#8217;s really useful when you have larger amounts of data to process &#8211; that&#8217;s where you&#8217;ll see the biggest benefit.<\/p>\n\n\n\n<p>To enable it:<\/p>\n\n\n\n<ol class=\"wp-block-list\">\n<li>Navigate to <strong>Acceleration<\/strong> under <strong>Spark Compute<\/strong><\/li>\n\n\n\n<li>Check the <strong>Enable native execution engine<\/strong> box<\/li>\n\n\n\n<li>Publish the environment to apply the changes<\/li>\n<\/ol>\n\n\n\n<h3 class=\"wp-block-heading\">Compute<\/h3>\n\n\n\n<p>This is where you adjust your Spark compute configuration to match the power your workload actually needs.<\/p>\n\n\n\n<p>Within the Environment itself, you can manage:<\/p>\n\n\n\n<ul class=\"wp-block-list\">\n<li>Driver Cores<\/li>\n\n\n\n<li>Driver Memory<\/li>\n\n\n\n<li>Executor Cores<\/li>\n\n\n\n<li>Executor Memory<\/li>\n\n\n\n<li>Enable\/Disable dynamic allocation<\/li>\n\n\n\n<li>Number of Spark executor instances<\/li>\n<\/ul>\n\n\n\n<p>However, some settings aren&#8217;t configurable at the Environment level:<\/p>\n\n\n\n<ul class=\"wp-block-list\">\n<li>Node family<\/li>\n\n\n\n<li>Node size<\/li>\n\n\n\n<li>Autoscaling<\/li>\n<\/ul>\n\n\n\n<p><strong>These settings are configured at the pool level<\/strong>, defined in workspace settings. To configure a new Spark pool, navigate to <strong>Workspace \u2192 Workspace Settings \u2192 Data Engineering\/Science \u2192 Spark settings<\/strong>. Here you can create a custom Spark pool:<\/p>\n\n\n\n<figure class=\"wp-block-image\"><img loading=\"lazy\" decoding=\"async\" width=\"927\" height=\"842\" src=\"https:\/\/dataguide.tech\/wp-content\/uploads\/2026\/02\/Pasted-image-20260113093943-1-1.png\" alt=\"Pasted image 20260113093943.png\" class=\"wp-image-381\" srcset=\"https:\/\/dataguide.tech\/wp-content\/uploads\/2026\/02\/Pasted-image-20260113093943-1-1.png 927w, https:\/\/dataguide.tech\/wp-content\/uploads\/2026\/02\/Pasted-image-20260113093943-1-1-300x272.png 300w, https:\/\/dataguide.tech\/wp-content\/uploads\/2026\/02\/Pasted-image-20260113093943-1-1-768x698.png 768w\" sizes=\"auto, (max-width: 927px) 100vw, 927px\" \/><\/figure>\n\n\n\n<p>Once you have your custom pool created (or you can adjust the default Starter Pool as well), go back to your Environment, open the <strong>Compute<\/strong> tab under <strong>Spark Compute<\/strong>, and <strong>select the pool you just created<\/strong>. From there, adjust the driver\/executor settings as needed and publish the changes.<\/p>\n\n\n\n<h3 class=\"wp-block-heading\">Spark Properties<\/h3>\n\n\n\n<p>If your workload requires custom adjustment of default Spark properties, this is the place. For example, you can set <code>spark.fabric.resourceProfile<\/code> to switch between predefined optimization profiles like <code>writeHeavy<\/code>, <code>readHeavyForPBI<\/code>, or <code>readHeavyForSpark<\/code>, depending on whether your workload prioritizes ingestion throughput or query performance.<\/p>\n\n\n\n<p>To add a property:<\/p>\n\n\n\n<ol class=\"wp-block-list\">\n<li>Navigate to <strong>Spark properties<\/strong> under <strong>Spark Compute<\/strong><\/li>\n\n\n\n<li>Click <strong>Add properties<\/strong><\/li>\n\n\n\n<li>Select a property from the dropdown and specify its value<\/li>\n<\/ol>\n\n\n\n<p><strong>Heads up:<\/strong> Not all properties appear in the dropdown, but you can still use them by typing the property name directly.<\/p>\n\n\n\n<h2 class=\"wp-block-heading\">Storage Configuration<\/h2>\n\n\n\n<h3 class=\"wp-block-heading\">Resources<\/h3>\n\n\n\n<p>To add files to your Environment&#8217;s shared storage (up to 100MB per file):<\/p>\n\n\n\n<ol class=\"wp-block-list\">\n<li>Go to the <strong>Resources<\/strong> tab in the <strong>Storage<\/strong> section<\/li>\n\n\n\n<li>Click <strong>Upload<\/strong> and choose your file<\/li>\n\n\n\n<li>Publish the environment<\/li>\n<\/ol>\n\n\n\n<h1 class=\"wp-block-heading\">How to Use It in Your Notebooks<\/h1>\n\n\n\n<h3 class=\"wp-block-heading\">Assigning an Environment to a Single Notebook<\/h3>\n\n\n\n<p>To use your custom Environment in a specific notebook:<\/p>\n\n\n\n<ol class=\"wp-block-list\">\n<li>Open the notebook and look for the environment selector:<\/li>\n<\/ol>\n\n\n\n<figure class=\"wp-block-image\"><img loading=\"lazy\" decoding=\"async\" width=\"1163\" height=\"255\" src=\"https:\/\/dataguide.tech\/wp-content\/uploads\/2026\/02\/Pasted-image-20260113110458-1-1.png\" alt=\"Pasted image 20260113110458.png\" class=\"wp-image-378\" srcset=\"https:\/\/dataguide.tech\/wp-content\/uploads\/2026\/02\/Pasted-image-20260113110458-1-1.png 1163w, https:\/\/dataguide.tech\/wp-content\/uploads\/2026\/02\/Pasted-image-20260113110458-1-1-300x66.png 300w, https:\/\/dataguide.tech\/wp-content\/uploads\/2026\/02\/Pasted-image-20260113110458-1-1-1024x225.png 1024w, https:\/\/dataguide.tech\/wp-content\/uploads\/2026\/02\/Pasted-image-20260113110458-1-1-768x168.png 768w\" sizes=\"auto, (max-width: 1163px) 100vw, 1163px\" \/><\/figure>\n\n\n\n<ol start=\"2\" class=\"wp-block-list\">\n<li>You&#8217;ll see all environments you have access to. Select the one you need and hit <strong>Connect<\/strong>:<\/li>\n<\/ol>\n\n\n\n<figure class=\"wp-block-image\"><img loading=\"lazy\" decoding=\"async\" width=\"1278\" height=\"304\" src=\"https:\/\/dataguide.tech\/wp-content\/uploads\/2026\/02\/Pasted-image-20260113110526-1-1.png\" alt=\"Pasted image 20260113110526.png\" class=\"wp-image-380\" srcset=\"https:\/\/dataguide.tech\/wp-content\/uploads\/2026\/02\/Pasted-image-20260113110526-1-1.png 1278w, https:\/\/dataguide.tech\/wp-content\/uploads\/2026\/02\/Pasted-image-20260113110526-1-1-300x71.png 300w, https:\/\/dataguide.tech\/wp-content\/uploads\/2026\/02\/Pasted-image-20260113110526-1-1-1024x244.png 1024w, https:\/\/dataguide.tech\/wp-content\/uploads\/2026\/02\/Pasted-image-20260113110526-1-1-768x183.png 768w\" sizes=\"auto, (max-width: 1278px) 100vw, 1278px\" \/><\/figure>\n\n\n\n<ol start=\"3\" class=\"wp-block-list\">\n<li>Once connected, you&#8217;ll see it displayed at the top:<\/li>\n<\/ol>\n\n\n\n<figure class=\"wp-block-image\"><img decoding=\"async\" src=\"https:\/\/dataguide.tech\/wp-content\/uploads\/2026\/02\/Pasted-image-20260113110615-1.png\" alt=\"Pasted image 20260113110615.png\"\/><\/figure>\n\n\n\n<p>Starting a new session will now include all settings from your Environment.<\/p>\n\n\n\n<p><strong>Please note:<\/strong> Sessions using a custom Environment take a bit longer to start than the default one.<\/p>\n\n\n\n<p>To verify everything works, just try importing a library you configured. In my case, I ran the <code>faker<\/code> library without any prior <code>pip install<\/code>:<\/p>\n\n\n\n<figure class=\"wp-block-image\"><img loading=\"lazy\" decoding=\"async\" width=\"1302\" height=\"428\" src=\"https:\/\/dataguide.tech\/wp-content\/uploads\/2026\/02\/Pasted-image-20260113110929-1-1.png\" alt=\"Pasted image 20260113110929.png\" class=\"wp-image-383\" srcset=\"https:\/\/dataguide.tech\/wp-content\/uploads\/2026\/02\/Pasted-image-20260113110929-1-1.png 1302w, https:\/\/dataguide.tech\/wp-content\/uploads\/2026\/02\/Pasted-image-20260113110929-1-1-300x99.png 300w, https:\/\/dataguide.tech\/wp-content\/uploads\/2026\/02\/Pasted-image-20260113110929-1-1-1024x337.png 1024w, https:\/\/dataguide.tech\/wp-content\/uploads\/2026\/02\/Pasted-image-20260113110929-1-1-768x252.png 768w\" sizes=\"auto, (max-width: 1302px) 100vw, 1302px\" \/><\/figure>\n\n\n\n<h3 class=\"wp-block-heading\">Setting a Default Environment for the Workspace<\/h3>\n\n\n\n<p>You can also make your Environment the default for every notebook in the workspace. Navigate to <strong>Workspace \u2192 Workspace Settings \u2192 Data Engineering\/Science \u2192 Spark settings<\/strong>, then:<\/p>\n\n\n\n<ol class=\"wp-block-list\">\n<li>Select <strong>Environment<\/strong><\/li>\n\n\n\n<li>Enable <strong>Set default environment<\/strong><\/li>\n\n\n\n<li>Choose your Environment from the dropdown<\/li>\n<\/ol>\n\n\n\n<figure class=\"wp-block-image\"><img loading=\"lazy\" decoding=\"async\" width=\"736\" height=\"698\" src=\"https:\/\/dataguide.tech\/wp-content\/uploads\/2026\/02\/Pasted-image-20260224101121-1.png\" alt=\"Pasted image 20260224101121.png\" class=\"wp-image-384\" srcset=\"https:\/\/dataguide.tech\/wp-content\/uploads\/2026\/02\/Pasted-image-20260224101121-1.png 736w, https:\/\/dataguide.tech\/wp-content\/uploads\/2026\/02\/Pasted-image-20260224101121-1-300x285.png 300w\" sizes=\"auto, (max-width: 736px) 100vw, 736px\" \/><\/figure>\n\n\n\n<p>This way, every new notebook created in the workspace will automatically use your custom Environment.<\/p>\n\n\n\n<h3 class=\"wp-block-heading\">Using Environments in Data Pipelines<\/h3>\n\n\n\n<p>Environments aren&#8217;t limited to notebooks. You can also reference them in <strong>Data Pipeline Spark activities<\/strong>. When configuring a Spark notebook activity in a pipeline, you&#8217;ll find an option to select the Environment &#8211; so your pipelines can benefit from the same centralized configuration.<\/p>\n\n\n\n<h1 class=\"wp-block-heading\">Things to Keep in Mind<\/h1>\n\n\n\n<p>Before you go all-in on Environments, here are a few gotchas I&#8217;ve encountered:<\/p>\n\n\n\n<ul class=\"wp-block-list\">\n<li><strong>Publishing takes time<\/strong> &#8211; Depending on the number of libraries, publishing can take several minutes. Plan for this during development sprints.<\/li>\n\n\n\n<li><strong>Environments can be shared across workspaces<\/strong> &#8211; While Environments are created within a workspace, they can be shared and used by other workspaces. This opens up interesting strategies around whether you create one Environment per workspace or maintain a single generic one for your entire tenant &#8211; something I&#8217;ll cover in a dedicated post.<\/li>\n\n\n\n<li><strong>Session restart required after updates<\/strong> &#8211; If you publish changes to an Environment while a Spark session is running, the active session won&#8217;t pick them up. Users need to stop and restart their session to get the latest configuration.<\/li>\n\n\n\n<li><strong>Library version conflicts<\/strong> &#8211; Be careful when installing custom libraries that might conflict with built-in ones. If a built-in library has a specific version and you try to install a different version, it can lead to unexpected behavior.<\/li>\n\n\n\n<li><strong>Not all Spark properties are documented<\/strong> &#8211; As mentioned, the dropdown doesn&#8217;t list every available property. You may need to check Spark documentation for advanced configurations.<\/li>\n<\/ul>\n\n\n\n<h1 class=\"wp-block-heading\">Wrapping Up<\/h1>\n\n\n\n<p>Fabric Environments give you a clean, centralized way to manage your Spark workloads. Instead of scattering configuration across individual notebooks, you define everything once &#8211; libraries, compute settings, Spark properties, and shared resources &#8211; and it&#8217;s available wherever you need it.<\/p>\n\n\n\n<p><strong>Key Takeaways:<\/strong><\/p>\n\n\n\n<ul class=\"wp-block-list\">\n<li>Use <strong>Libraries<\/strong> to avoid repetitive <code>pip install<\/code> commands across notebooks<\/li>\n\n\n\n<li>Leverage <strong>Spark Compute<\/strong> settings to right-size your resources and enable the Native Execution Engine for heavy workloads<\/li>\n\n\n\n<li>Manage your Environments as code through YML files and Git integration<\/li>\n\n\n\n<li>Set a <strong>default Environment<\/strong> at the workspace level to keep things consistent across your team<\/li>\n<\/ul>\n\n\n\n<p>This is just the beginning of the Environments topic. I&#8217;m working on two follow-up posts:<\/p>\n\n\n\n<ol class=\"wp-block-list\">\n<li><strong>How to Create Your Own Custom Python Library<\/strong> &#8211; I&#8217;ll walk you through building your own <code>.whl<\/code> package and uploading it to Fabric.<\/li>\n\n\n\n<li><strong>Environment Strategies for Your Fabric Tenant<\/strong> &#8211; Should you create one Environment per workspace, or maintain a single generic one across your entire tenant? I&#8217;ll share the scenarios and my recommendations.<\/li>\n<\/ol>\n\n\n\n<p>Got questions about configuring Environments in your setup? Drop a comment &#8211; I&#8217;d love to hear how you&#8217;re using them!<\/p>\n\n\n\n<p>Happy configuring!<\/p>\n","protected":false},"excerpt":{"rendered":"<p>If you&#8217;re working with Microsoft Fabric and running complex workloads &#8211; multiple notebooks executing at the same time, or needing Python libraries that aren&#8217;t built-in &#8211; you&#8217;ve probably asked yourself: &#8220;How do I manage this properly?&#8221; The answer is Fabric Environments. In this post, I&#8217;ll walk you through what they are, how to configure them,&#8230;<\/p>\n","protected":false},"author":1,"featured_media":375,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"_monsterinsights_skip_tracking":false,"_monsterinsights_sitenote_active":false,"_monsterinsights_sitenote_note":"","_monsterinsights_sitenote_category":0,"_kadence_starter_templates_imported_post":false,"_kad_post_transparent":"","_kad_post_title":"","_kad_post_layout":"","_kad_post_sidebar_id":"","_kad_post_content_style":"","_kad_post_vertical_padding":"","_kad_post_feature":"","_kad_post_feature_position":"","_kad_post_header":false,"_kad_post_footer":false,"_kad_post_classname":"","jetpack_post_was_ever_published":false,"_jetpack_newsletter_access":"","_jetpack_dont_email_post_to_subs":false,"_jetpack_newsletter_tier_id":0,"_jetpack_memberships_contains_paywalled_content":false,"_jetpack_memberships_contains_paid_content":false,"footnotes":""},"categories":[9],"tags":[11,10],"class_list":["post-373","post","type-post","status-publish","format-standard","has-post-thumbnail","hentry","category-microsoft-fabric","tag-administration","tag-microsoftfabric"],"jetpack_featured_media_url":"https:\/\/dataguide.tech\/wp-content\/uploads\/2026\/02\/Gemini_Generated_Image_qfn4qmqfn4qmqfn4.png","jetpack_sharing_enabled":true,"_links":{"self":[{"href":"https:\/\/dataguide.tech\/index.php\/wp-json\/wp\/v2\/posts\/373","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/dataguide.tech\/index.php\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/dataguide.tech\/index.php\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/dataguide.tech\/index.php\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/dataguide.tech\/index.php\/wp-json\/wp\/v2\/comments?post=373"}],"version-history":[{"count":4,"href":"https:\/\/dataguide.tech\/index.php\/wp-json\/wp\/v2\/posts\/373\/revisions"}],"predecessor-version":[{"id":387,"href":"https:\/\/dataguide.tech\/index.php\/wp-json\/wp\/v2\/posts\/373\/revisions\/387"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/dataguide.tech\/index.php\/wp-json\/wp\/v2\/media\/375"}],"wp:attachment":[{"href":"https:\/\/dataguide.tech\/index.php\/wp-json\/wp\/v2\/media?parent=373"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/dataguide.tech\/index.php\/wp-json\/wp\/v2\/categories?post=373"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/dataguide.tech\/index.php\/wp-json\/wp\/v2\/tags?post=373"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}