CRM Crate

Optimize components with Preferred Solution in Power Platform

In this blogpost, we will learn to optimize and improve component management with Preferred Solution in Power Platform. Before we begin, ensure you subscribe to CRM Crate to remain informed about the latest developments in the Power Platform field.

Optimize components with Preferred Solution in Power Platform

In Microsoft’s Power Platform, solutions are essential for organizing, deploying, and maintaining your customizations and configurations in environments like Power Apps and Power Automate. Solutions come in two types: managed and unmanaged. Understanding the difference between them is crucial for effectively managing your applications and ensuring smooth deployment processes.

Managed solutions are packaged versions of your customizations that are intended for distribution and deployment in production environments. They are essentially locked, meaning that the components within them can’t be directly modified once they are imported into an environment. Here are some key points about managed solutions:

  1. Immutable Components: When you import a managed solution, you can’t directly edit its components. This helps maintain the integrity and consistency of the solution, ensuring that the deployed version is exactly as the developer intended.
  2. Version Control: Managed solutions are version-controlled, making it easy to track and manage updates. When a new version is released, it can be upgraded in a target environment, allowing seamless updates.
  3. Dependency Management: They handle dependencies well. If a solution relies on components from another solution, the dependencies are managed to ensure that all required components are present.
  4. Ideal for Production: Because of their controlled nature, managed solutions are best suited for production environments where stability and integrity are crucial.
  5. Uninstall Capabilities: Managed solutions can be uninstalled, which will remove all the components that were part of the solution from the environment.

Unmanaged solutions are more like working projects. They are used during the development phase and allow full control over all components. Here’s what you need to know about unmanaged solutions:

  1. Editable Components: In an unmanaged solution, you can add, modify, or delete components freely. This makes it ideal for development and testing environments where changes are frequently made.
  2. Development Flexibility: Since components can be edited directly, it’s easier to iterate and refine your customizations without restrictions.
  3. No Direct Version Control: Unlike managed solutions, unmanaged solutions don’t have built-in version control. It’s up to the developer to manage versions manually.
  4. Can Be Converted: Once development is complete, an unmanaged solution can be exported and then imported as a managed solution for deployment to production environments.
  5. Persistent Components: If you delete an unmanaged solution, the components remain in the environment. This is useful if you want to retain certain customizations or if you are transitioning to another solution.

Understanding the preferred solution

Typically, if you’re not working within an unmanaged solution context, all your solution components end up in this place called the Dataverse or Common Data Services Default Solution. The issue is, there’s no way to keep things separate between different developers, and you can’t take this default solution and move it to another setup. That’s why experts usually don’t recommend using this model.

Preferred solutions let you choose which solution supports the changes each developer makes throughout Power Apps. This allows makers to see and change the solution they’re working with. Once you’ve set your preferred solution, any new components you create will be automatically placed in that solution, giving you control over what’s in it. This means you can export your preferred solution and import it into other Microsoft Dataverse environments.

It’s worth mentioning that if you haven’t set a preferred solution, the system defaults to using the Dataverse or Common Data Services Default Solution. If that’s not accessible, it switches to the Default Solution. You can switch this to your preferred choice by following the steps outlined in this article.

Configuring the preferred solution

Follow the below steps for setting up your preferred solution.

  1. Begin by signing into Power Apps.
  2. Navigate to Solutions in the left sidebar.
    a. Select the unmanaged solution that you want to make your preferred solution.
  3. Select Set preferred solution on the command bar.

After you’ve chosen your preferred solution, take note of the indicator that shows it’s the one you’ve selected. You can find this indicator in the Solutions section or by hovering over the Environment switcher (Manage) as shown below.

Optimize components with Preferred Solution in Power Platform
Optimize components with Preferred Solution in Power Platform

Demonstration of the preferred solution

Consider an example where we have created a new table “Prashant Solution” outside of any solution. Now since we have configured the “CRM Crate Solution” as the preferred solution, so this newly created table is automatically added in the preferred solution as shown below.

Optimize components with Preferred Solution in Power Platform
Optimize components with Preferred Solution in Power Platform
Optimize components with Preferred Solution in Power Platform

What are the disadvantages of Preferred Solutions?

  1. It’s not possible to manage or view the preferred solution within the classic solution explorer.
  2. Any components made in the classic solution explorer won’t be included in the preferred solution.
  3. The preferred solution isn’t compatible with cards, dataflows, AI Builder, chatbots, connections, gateways, custom connectors, certain limited aspects of Power Automate flows, and canvas apps generated from images or Figma designs.
  4. If a component is already part of an unmanaged solution, it will be added to the preferred solution regardless.

5 1 vote
Article Rating
Notify of
Inline Feedbacks
View all comments
error: CRM Crate Security Engine - Disabled Right Click & Selection!


Well Done,
Welcome to CRM Crate

Stay tuned with us and get all latest updates and learning in Microsoft CRM and related techonologes.